MADNESS  0.10.1
Public Member Functions | Static Public Member Functions | Private Attributes | Friends | List of all members
madness::MolecularOrbitals< T, NDIM > Class Template Reference

#include <MolecularOrbitals.h>

Inheritance diagram for madness::MolecularOrbitals< T, NDIM >:
Inheritance graph
[legend]
Collaboration diagram for madness::MolecularOrbitals< T, NDIM >:
Collaboration graph
[legend]

Public Member Functions

 MolecularOrbitals ()=default
 
 MolecularOrbitals (const MolecularOrbitals< T, NDIM > &other)=default
 
 MolecularOrbitals (const std::vector< Function< T, NDIM > > &mo)
 
 MolecularOrbitals (const std::vector< Function< T, NDIM > > &mo, const Tensor< double > &eps)
 
 MolecularOrbitals (const std::vector< Function< T, NDIM > > &mo, const Tensor< double > &eps, const std::vector< std::string > &irrep, const Tensor< double > &occ, const std::vector< int > &set)
 
std::vector< Vector< typename Tensor< T >::scalar_type, 3 > > compute_center (const Function< typename Tensor< T >::scalar_type, NDIM > metric2=Function< typename Tensor< T >::scalar_type, NDIM >()) const
 
Tensor< double > get_eps () const
 
std::vector< std::string > get_irreps () const
 
std::vector< int > get_localize_sets () const
 
std::vector< Function< T, NDIM > > get_mos () const
 
Tensor< double > get_occ () const
 
MolecularOrbitals get_subset (const int iset) const
 
void invalidate_all ()
 
void invalidate_eps ()
 
void invalidate_irreps ()
 
void invalidate_localize_sets ()
 
void invalidate_mos ()
 
void invalidate_occ ()
 
void load_mos (archive::ParallelInputArchive<> &ar, const Molecule &molecule, const std::size_t nmo_from_input)
 legacy code More...
 
void post_process_mos (World &world, const double thresh, const int k)
 
void pretty_print (std::string message, std::vector< std::string > flags=std::vector< std::string >()) const
 
void print_cubefiles (const std::string name, const std::vector< std::string > cubefile_header) const
 
void print_frozen_orbitals (const long freeze) const
 
void project_ao (World &world, const Tensor< T > &Saomo, const std::vector< Function< double, 3 > > &aos)
 
MolecularOrbitalsrecompute_irreps (const std::string pointgroup, const Function< typename Tensor< T >::scalar_type, NDIM > &metric)
 
MolecularOrbitalsrecompute_localize_sets (const double bandwidth=1.5)
 group orbitals into sets of similar orbital energies for localization More...
 
void save_mos (archive::ParallelOutputArchive<> &ar, const Molecule &molecule) const
 legacy code More...
 
template<typename Archive >
void serialize (Archive &ar)
 
MolecularOrbitalsset_all_orbitals_occupied ()
 
MolecularOrbitalsset_mos (const std::vector< Function< T, NDIM > > &mo_new)
 setters will always invalidate all other member variables More...
 
std::size_t size () const
 
MolecularOrbitalsupdate_localize_set (const std::vector< int > &set)
 updates will keep other member variables More...
 
MolecularOrbitalsupdate_mos (const std::vector< Function< T, NDIM > > &mo_new)
 updates will keep other member variables More...
 
MolecularOrbitalsupdate_mos_and_eps (const std::vector< Function< T, NDIM > > &mo_new, const Tensor< double > &eps_new)
 updates will keep other member variables More...
 
MolecularOrbitalsupdate_occ (const Tensor< double > &occ_new)
 
void write_to (std::vector< Function< T, NDIM > > &mo_out, Tensor< double > &eps_out, std::vector< std::string > &irrep_out, Tensor< double > &occ_out, std::vector< int > &set_out) const
 

Static Public Member Functions

static std::vector< Sliceconvert_set_to_slice (const std::vector< int > &localized_set)
 
static std::pair< MolecularOrbitals< T, NDIM >, MolecularOrbitals< T, NDIM > > read_restartaodata (World &world, const Molecule &molecule, const bool have_beta)
 uses AO-projection as a restart guess More...
 
static std::pair< MolecularOrbitals< T, NDIM >, MolecularOrbitals< T, NDIM > > read_restartdata (World &world, const std::string filename, const Molecule &molecule, const std::size_t nmo_alpha, const std::size_t nmo_beta)
 reads amo and bmo from the restartdata file More...
 
static void save_restartaodata (World &world, const Molecule &molecule, const MolecularOrbitals< T, NDIM > &amo, const MolecularOrbitals< T, NDIM > &bmo, const AtomicBasisSet &aobasis)
 save MOs in the AO projection for geometry restart More...
 
static void save_restartdata (World &world, const std::string filename, const Molecule &molecule, const MolecularOrbitals< T, NDIM > &amo, const MolecularOrbitals< T, NDIM > &bmo)
 reads amo and bmo from the restartdata file More...
 

Private Attributes

Tensor< double > eps
 
std::vector< std::string > irreps
 
std::vector< int > localize_sets
 
std::vector< Function< T, NDIM > > mo
 
Tensor< double > occ
 

Friends

bool similar (const MolecularOrbitals &mo1, const MolecularOrbitals &mo2, const double thresh=1.e-6)
 

Constructor & Destructor Documentation

◆ MolecularOrbitals() [1/5]

template<typename T , std::size_t NDIM>
madness::MolecularOrbitals< T, NDIM >::MolecularOrbitals ( const MolecularOrbitals< T, NDIM > &  other)
default

◆ MolecularOrbitals() [2/5]

template<typename T , std::size_t NDIM>
madness::MolecularOrbitals< T, NDIM >::MolecularOrbitals ( )
default

◆ MolecularOrbitals() [3/5]

template<typename T , std::size_t NDIM>
madness::MolecularOrbitals< T, NDIM >::MolecularOrbitals ( const std::vector< Function< T, NDIM > > &  mo)
inline

◆ MolecularOrbitals() [4/5]

template<typename T , std::size_t NDIM>
madness::MolecularOrbitals< T, NDIM >::MolecularOrbitals ( const std::vector< Function< T, NDIM > > &  mo,
const Tensor< double > &  eps 
)
inline

◆ MolecularOrbitals() [5/5]

template<typename T , std::size_t NDIM>
madness::MolecularOrbitals< T, NDIM >::MolecularOrbitals ( const std::vector< Function< T, NDIM > > &  mo,
const Tensor< double > &  eps,
const std::vector< std::string > &  irrep,
const Tensor< double > &  occ,
const std::vector< int > &  set 
)
inline

Member Function Documentation

◆ compute_center()

template<typename T , std::size_t NDIM>
std::vector< Vector< typename Tensor< T >::scalar_type, 3 > > madness::MolecularOrbitals< T, NDIM >::compute_center ( const Function< typename Tensor< T >::scalar_type, NDIM metric2 = Function<typename Tensor<T>::scalar_type,NDIM>()) const

◆ convert_set_to_slice()

template<typename T , std::size_t NDIM>
static std::vector<Slice> madness::MolecularOrbitals< T, NDIM >::convert_set_to_slice ( const std::vector< int > &  localized_set)
inlinestatic

◆ get_eps()

template<typename T , std::size_t NDIM>
Tensor<double> madness::MolecularOrbitals< T, NDIM >::get_eps ( ) const
inline

◆ get_irreps()

template<typename T , std::size_t NDIM>
std::vector<std::string> madness::MolecularOrbitals< T, NDIM >::get_irreps ( ) const
inline

◆ get_localize_sets()

template<typename T , std::size_t NDIM>
std::vector<int> madness::MolecularOrbitals< T, NDIM >::get_localize_sets ( ) const
inline

◆ get_mos()

template<typename T , std::size_t NDIM>
std::vector<Function<T,NDIM> > madness::MolecularOrbitals< T, NDIM >::get_mos ( ) const
inline

◆ get_occ()

template<typename T , std::size_t NDIM>
Tensor<double> madness::MolecularOrbitals< T, NDIM >::get_occ ( ) const
inline

◆ get_subset()

template<typename T , std::size_t NDIM>
MolecularOrbitals madness::MolecularOrbitals< T, NDIM >::get_subset ( const int  iset) const
inline

◆ invalidate_all()

template<typename T , std::size_t NDIM>
void madness::MolecularOrbitals< T, NDIM >::invalidate_all ( )
inline

◆ invalidate_eps()

template<typename T , std::size_t NDIM>
void madness::MolecularOrbitals< T, NDIM >::invalidate_eps ( )
inline

◆ invalidate_irreps()

template<typename T , std::size_t NDIM>
void madness::MolecularOrbitals< T, NDIM >::invalidate_irreps ( )
inline

◆ invalidate_localize_sets()

template<typename T , std::size_t NDIM>
void madness::MolecularOrbitals< T, NDIM >::invalidate_localize_sets ( )
inline

◆ invalidate_mos()

template<typename T , std::size_t NDIM>
void madness::MolecularOrbitals< T, NDIM >::invalidate_mos ( )
inline

◆ invalidate_occ()

template<typename T , std::size_t NDIM>
void madness::MolecularOrbitals< T, NDIM >::invalidate_occ ( )
inline

◆ load_mos()

template<typename T , std::size_t NDIM>
void madness::MolecularOrbitals< T, NDIM >::load_mos ( archive::ParallelInputArchive<> &  ar,
const Molecule molecule,
const std::size_t  nmo_from_input 
)
inline

◆ post_process_mos()

template<typename T , std::size_t NDIM>
void madness::MolecularOrbitals< T, NDIM >::post_process_mos ( World world,
const double  thresh,
const int  k 
)

◆ pretty_print()

template<typename T , std::size_t NDIM>
void madness::MolecularOrbitals< T, NDIM >::pretty_print ( std::string  message,
std::vector< std::string >  flags = std::vector<std::string>() 
) const
inline

◆ print_cubefiles()

template<typename T , std::size_t NDIM>
void madness::MolecularOrbitals< T, NDIM >::print_cubefiles ( const std::string  name,
const std::vector< std::string >  cubefile_header 
) const
Parameters
[in]cubefile_headerheader of the cube file, from molecule::cubefile_header()

References madness::cubefile_header(), madness::filename, and madness::name().

◆ print_frozen_orbitals()

template<typename T , std::size_t NDIM>
void madness::MolecularOrbitals< T, NDIM >::print_frozen_orbitals ( const long  freeze) const
inline

◆ project_ao()

template<typename T , std::size_t NDIM>
void madness::MolecularOrbitals< T, NDIM >::project_ao ( World world,
const Tensor< T > &  Saomo,
const std::vector< Function< double, 3 > > &  aos 
)

◆ read_restartaodata()

template<typename T , std::size_t NDIM>
std::pair< MolecularOrbitals< T, NDIM >, MolecularOrbitals< T, NDIM > > madness::MolecularOrbitals< T, NDIM >::read_restartaodata ( World world,
const Molecule molecule,
const bool  have_beta 
)
static

◆ read_restartdata()

template<typename T , std::size_t NDIM>
static std::pair<MolecularOrbitals<T,NDIM>, MolecularOrbitals<T,NDIM> > madness::MolecularOrbitals< T, NDIM >::read_restartdata ( World world,
const std::string  filename,
const Molecule molecule,
const std::size_t  nmo_alpha,
const std::size_t  nmo_beta 
)
inlinestatic

◆ recompute_irreps()

template<typename T , std::size_t NDIM>
MolecularOrbitals< T, NDIM > & madness::MolecularOrbitals< T, NDIM >::recompute_irreps ( const std::string  pointgroup,
const Function< typename Tensor< T >::scalar_type, NDIM > &  metric 
)

◆ recompute_localize_sets()

template<typename T , std::size_t NDIM>
MolecularOrbitals& madness::MolecularOrbitals< T, NDIM >::recompute_localize_sets ( const double  bandwidth = 1.5)
inline

◆ save_mos()

template<typename T , std::size_t NDIM>
void madness::MolecularOrbitals< T, NDIM >::save_mos ( archive::ParallelOutputArchive<> &  ar,
const Molecule molecule 
) const
inline

◆ save_restartaodata()

template<typename T , std::size_t NDIM>
void madness::MolecularOrbitals< T, NDIM >::save_restartaodata ( World world,
const Molecule molecule,
const MolecularOrbitals< T, NDIM > &  amo,
const MolecularOrbitals< T, NDIM > &  bmo,
const AtomicBasisSet aobasis 
)
static

◆ save_restartdata()

template<typename T , std::size_t NDIM>
static void madness::MolecularOrbitals< T, NDIM >::save_restartdata ( World world,
const std::string  filename,
const Molecule molecule,
const MolecularOrbitals< T, NDIM > &  amo,
const MolecularOrbitals< T, NDIM > &  bmo 
)
inlinestatic

reads amo and bmo from the restartdata file

Returns
amo and bmo

References madness::filename, k1, L, molecule, madness::MolecularOrbitals< T, NDIM >::save_mos(), madness::info::version(), and xc.

◆ serialize()

template<typename T , std::size_t NDIM>
template<typename Archive >
void madness::MolecularOrbitals< T, NDIM >::serialize ( Archive &  ar)
inline

◆ set_all_orbitals_occupied()

template<typename T , std::size_t NDIM>
MolecularOrbitals& madness::MolecularOrbitals< T, NDIM >::set_all_orbitals_occupied ( )
inline

◆ set_mos()

template<typename T , std::size_t NDIM>
MolecularOrbitals& madness::MolecularOrbitals< T, NDIM >::set_mos ( const std::vector< Function< T, NDIM > > &  mo_new)
inline

◆ size()

template<typename T , std::size_t NDIM>
std::size_t madness::MolecularOrbitals< T, NDIM >::size ( ) const
inline

◆ update_localize_set()

template<typename T , std::size_t NDIM>
MolecularOrbitals& madness::MolecularOrbitals< T, NDIM >::update_localize_set ( const std::vector< int > &  set)
inline

◆ update_mos()

template<typename T , std::size_t NDIM>
MolecularOrbitals& madness::MolecularOrbitals< T, NDIM >::update_mos ( const std::vector< Function< T, NDIM > > &  mo_new)
inline

updates will keep other member variables

References madness::MolecularOrbitals< T, NDIM >::mo.

Referenced by madness::Localizer::localize().

◆ update_mos_and_eps()

template<typename T , std::size_t NDIM>
MolecularOrbitals& madness::MolecularOrbitals< T, NDIM >::update_mos_and_eps ( const std::vector< Function< T, NDIM > > &  mo_new,
const Tensor< double > &  eps_new 
)
inline

◆ update_occ()

template<typename T , std::size_t NDIM>
MolecularOrbitals& madness::MolecularOrbitals< T, NDIM >::update_occ ( const Tensor< double > &  occ_new)
inline

◆ write_to()

template<typename T , std::size_t NDIM>
void madness::MolecularOrbitals< T, NDIM >::write_to ( std::vector< Function< T, NDIM > > &  mo_out,
Tensor< double > &  eps_out,
std::vector< std::string > &  irrep_out,
Tensor< double > &  occ_out,
std::vector< int > &  set_out 
) const

Friends And Related Function Documentation

◆ similar

template<typename T , std::size_t NDIM>
bool similar ( const MolecularOrbitals< T, NDIM > &  mo1,
const MolecularOrbitals< T, NDIM > &  mo2,
const double  thresh = 1.e-6 
)
friend

Member Data Documentation

◆ eps

template<typename T , std::size_t NDIM>
Tensor<double> madness::MolecularOrbitals< T, NDIM >::eps
private

◆ irreps

template<typename T , std::size_t NDIM>
std::vector<std::string> madness::MolecularOrbitals< T, NDIM >::irreps
private

◆ localize_sets

template<typename T , std::size_t NDIM>
std::vector<int> madness::MolecularOrbitals< T, NDIM >::localize_sets
private

◆ mo

template<typename T , std::size_t NDIM>
std::vector<Function<T,NDIM> > madness::MolecularOrbitals< T, NDIM >::mo
private

◆ occ

template<typename T , std::size_t NDIM>
Tensor<double> madness::MolecularOrbitals< T, NDIM >::occ
private

The documentation for this class was generated from the following files: