MPQC  3.0.0-alpha
ref.h
1 //
2 // ref.h
3 //
4 // Copyright (C) 2005 Edward Valeev
5 //
6 // Author: Edward Valeev <evaleev@vt.edu>
7 // Maintainer: EV
8 //
9 // This file is part of the SC Toolkit.
10 //
11 // The SC Toolkit is free software; you can redistribute it and/or modify
12 // it under the terms of the GNU Library General Public License as published by
13 // the Free Software Foundation; either version 2, or (at your option)
14 // any later version.
15 //
16 // The SC Toolkit is distributed in the hope that it will be useful,
17 // but WITHOUT ANY WARRANTY; without even the implied warranty of
18 // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
19 // GNU Library General Public License for more details.
20 //
21 // You should have received a copy of the GNU Library General Public License
22 // along with the SC Toolkit; see the file COPYING.LIB. If not, write to
23 // the Free Software Foundation, 675 Mass Ave, Cambridge, MA 02139, USA.
24 //
25 // The U.S. Government is granted a limited license as per AL 91-7.
26 //
27 
28 #ifndef _chemistry_qc_nbody_ref_h
29 #define _chemistry_qc_nbody_ref_h
30 
31 #include <chemistry/qc/wfn/wfn.h>
32 #include <chemistry/qc/scf/scf.h>
33 #include <chemistry/qc/lcao/wfnworld.h>
34 #include <chemistry/qc/wfn/orbitalspace.h>
35 #include <chemistry/qc/wfn/spin.h>
36 
37 namespace sc {
38 
39  class Wavefunction;
40 
43 
48  class PopulatedOrbitalSpace : virtual public SavableState {
49  public:
65  SpinCase1 spin, const Ref<GaussianBasisSet>& bs,
66  const Ref<Integral>& integral,
67  const RefSCMatrix& coefs,
68  const std::vector<double>& occs,
69  const std::vector<ParticleHoleOrbitalAttributes>& active,
70  const RefDiagSCMatrix& energies,
71  bool eorder_increasing = true,
72  Ref<OrbitalSpace> vbs = 0,
73  Ref<FockBuildRuntime> fbrun = 0
74  );
77  void save_data_state(StateOut& so);
78 
80  static double zero_occupancy() {
81  return 1e-8; // \approx sqrt(DBL_EPSILON)
82  }
83 
87  const Ref<OrbitalSpaceRegistry>& orbital_registry() const { return oreg_; }
88 
93 
94 
96  const Ref<OrbitalSpace>& orbs_sb() const { return orbs_sb_; }
98  const Ref<OrbitalSpace>& orbs() const { return orbs_; }
100  const Ref<OrbitalSpace>& occ_sb() const { return occ_sb_; }
102  const Ref<OrbitalSpace>& occ() const { return occ_; }
104  const Ref<OrbitalSpace>& occ_act_sb() const { return occ_act_sb_; }
106  const Ref<OrbitalSpace>& occ_act() const { return occ_act_; }
108  const Ref<OrbitalSpace>& occ_frz_sb() const { return occ_frz_sb_; }
110  const Ref<OrbitalSpace>& occ_frz() const { return occ_frz_; }
112  const Ref<OrbitalSpace>& uocc_sb() const { return uocc_sb_; }
114  const Ref<OrbitalSpace>& uocc() const { return uocc_; }
116  const Ref<OrbitalSpace>& uocc_act_sb() const { return uocc_act_sb_; }
118  const Ref<OrbitalSpace>& uocc_act() const { return uocc_act_; }
119 
121 
122  private:
124  Ref<OrbitalSpace> orbs_sb_;
125  Ref<OrbitalSpace> orbs_;
126  Ref<OrbitalSpace> occ_sb_;
127  Ref<OrbitalSpace> occ_act_sb_;
128  Ref<OrbitalSpace> occ_frz_sb_;
129  Ref<OrbitalSpace> occ_;
130  Ref<OrbitalSpace> occ_act_;
131  Ref<OrbitalSpace> occ_frz_;
132  Ref<OrbitalSpace> uocc_sb_;
133  Ref<OrbitalSpace> uocc_act_sb_;
134  Ref<OrbitalSpace> uocc_;
135  Ref<OrbitalSpace> uocc_act_;
136 
138  void purge();
139  };
140 
159  class RefWavefunction : virtual public SavableState {
160  protected:
161 
165  bool use_world_dfinfo() const { return use_world_dfinfo_; }
166 
199  RefWavefunction(const Ref<KeyVal>& kv);
200 
207  const Ref<GaussianBasisSet>& basis,
208  const Ref<Integral>& integral,
209  bool use_world_df = false);
210 
211  public:
212  ~RefWavefunction();
213  void save_data_state(StateOut&);
214 
217  virtual void obsolete();
220  virtual void purge();
221 
222  const Ref<WavefunctionWorld>& world() const { return world_; }
223  const Ref<GaussianBasisSet>& basis() const { return basis_; }
224  const Ref<Integral>& integral() const { return integral_; }
226  virtual const Ref<GaussianBasisSet>& uocc_basis() const { return basis(); }
229  const Ref<OrbitalSpace>& valence_orbs() const;
230 
232  virtual double energy() =0;
234  void set_desired_value_accuracy(double);
236  virtual double actual_value_accuracy () const =0;
238  virtual double desired_value_accuracy() const =0;
240  virtual bool desired_value_accuracy_set_to_default() const;
242  virtual int nelectron() const =0;
244  virtual double magnetic_moment() const =0;
246  bool spin_polarized() const {
247  return magnetic_moment() != 0.0;
248  }
250  virtual int dk() const =0;
252  virtual Ref<GaussianBasisSet> momentum_basis() const =0;
258  const Ref<GaussianBasisSet> &p_basis) =0;
260  virtual RefSymmSCMatrix ordm(SpinCase1 spin) const =0;
262  virtual RefSymmSCMatrix ordm_orbs_sb(SpinCase1 spin) const;
264  virtual RefSymmSCMatrix ordm_occ_sb(SpinCase1 spin) const;
265 
267  virtual bool sdref() const =0;
269  virtual Ref<DensityFittingInfo> dfinfo() const =0;
270 
272  const Ref<OrbitalSpace>& oso_space() const;
274  const Ref<OrbitalSpace>& orbs_sb(SpinCase1 spin = AnySpinCase1) const;
276  const Ref<OrbitalSpace>& orbs(SpinCase1 spin = AnySpinCase1) const;
278  const Ref<OrbitalSpace>& occ_sb(SpinCase1 spin = AnySpinCase1) const;
280  const Ref<OrbitalSpace>& occ_act_sb(SpinCase1 spin = AnySpinCase1) const;
282  const Ref<OrbitalSpace>& occ_frz_sb(SpinCase1 spin = AnySpinCase1) const;
284  const Ref<OrbitalSpace>& occ(SpinCase1 spin = AnySpinCase1) const;
286  const Ref<OrbitalSpace>& occ_act(SpinCase1 spin = AnySpinCase1) const;
288  const Ref<OrbitalSpace>& occ_frz(SpinCase1 spin = AnySpinCase1) const;
290  const Ref<OrbitalSpace>& uocc_sb(SpinCase1 spin = AnySpinCase1) const;
292  const Ref<OrbitalSpace>& uocc_act_sb(SpinCase1 spin = AnySpinCase1) const;
294  const Ref<OrbitalSpace>& uocc(SpinCase1 spin = AnySpinCase1) const;
296  const Ref<OrbitalSpace>& uocc_act(SpinCase1 spin = AnySpinCase1) const;
297 
298  virtual void print(std::ostream& os = ExEnv::out0()) const =0;
299 
300  protected:
301 
302  mutable Ref<PopulatedOrbitalSpace> spinspaces_[NSpinCases1];
303 
306 
308  void init() const;
310  virtual void reset();
312  virtual void init_spaces() = 0;
313 
314  private:
315  Ref<WavefunctionWorld> world_; // who owns this?
316  Ref<GaussianBasisSet> basis_;
317  Ref<Integral> integral_;
318  bool use_world_dfinfo_;
319  Ref<OrbitalSpace> valence_orbs_;
321 
323  virtual void _set_desired_value_accuracy(double eps) =0;
324 
325  };
326 
329  public:
330 
367  SD_RefWavefunction(const Ref<KeyVal>& kv);
368 
384  const Ref<OneBodyWavefunction>& obwfn,
385  bool spin_restricted = true,
386  unsigned int nfzc = 0,
387  unsigned int nfzv = 0,
388  Ref<OrbitalSpace> vir_space = 0,
389  std::string occ_orbs = std::string("canonical"));
392  void save_data_state(StateOut&);
393 
394  void print(std::ostream& os = ExEnv::out0()) const;
395 
396  void purge();
397 
398  bool sdref() const { return true; }
399  const Ref<OneBodyWavefunction>& obwfn() const { return obwfn_; }
400  const Ref<OrbitalSpace>& vir_space() const { return vir_space_; }
402  if (vir_space_) return vir_space_->basis();
403  else return this->basis();
404  }
405 
406  double energy() { return obwfn()->energy(); }
407  double actual_value_accuracy () const { return obwfn()->actual_value_accuracy(); }
408  double desired_value_accuracy() const { return obwfn()->desired_value_accuracy(); }
409  bool desired_value_accuracy_set_to_default() const { return obwfn()->desired_value_accuracy_set_to_default(); }
410  int nelectron() const { return obwfn()->nelectron(); }
411  double magnetic_moment() const { return obwfn()->magnetic_moment(); }
412  bool spin_restricted() const { return spin_restricted_; }
413  int dk() const { return obwfn()->dk(); }
414  Ref<GaussianBasisSet> momentum_basis() const { return obwfn()->momentum_basis(); }
416  const Ref<GaussianBasisSet> &p_basis);
417  unsigned int nfzc() const { return nfzc_; }
418  unsigned int nfzv() const { return nfzv_; }
419  RefSymmSCMatrix ordm(SpinCase1 spin) const;
420  Ref<DensityFittingInfo> dfinfo() const;
421  const std::string& occ_orbitals() const { return occ_orbitals_; }
422  private:
423  Ref<OneBodyWavefunction> obwfn_;
424  Ref<OrbitalSpace> vir_space_;
425  bool spin_restricted_;
426  std::string occ_orbitals_;
427  unsigned int nfzc_;
428  unsigned int nfzv_;
429  void init_spaces();
430  void init_spaces_restricted();
431  void init_spaces_unrestricted();
432  void _set_desired_value_accuracy(double eps) { obwfn_->set_desired_value_accuracy(eps); }
433  };
434 
438  public:
454  const Ref<GaussianBasisSet>& basis,
455  const Ref<Integral>& integral,
456  const RefSCMatrix& orbs,
457  const std::vector<unsigned int>& orbsymm,
458  const RefSymmSCMatrix& alpha_1rdm,
459  const RefSymmSCMatrix& beta_1rdm,
460  unsigned int nocc,
461  unsigned int nfzc = 0,
462  unsigned int nfzv = 0,
463  bool omit_uocc = false);
483  const Ref<GaussianBasisSet>& basis,
484  const Ref<Integral>& integral,
485  const RefSCMatrix& orbs,
486  const std::vector<unsigned int>& orbsymm,
487  const RefSymmSCMatrix& alpha_1rdm,
488  const RefSymmSCMatrix& beta_1rdm,
489  std::vector<unsigned int> occpi,
490  std::vector<unsigned int> fzcpi,
491  std::vector<unsigned int> fzvpi,
492  std::vector<unsigned int> holepi = std::vector<unsigned int>(),
493  std::vector<unsigned int> partpi = std::vector<unsigned int>(),
494  bool omit_uocc = false);
496  virtual ~Extern_RefWavefunction();
497  void save_data_state(StateOut&);
498  RefSymmSCMatrix ordm(SpinCase1 spin) const { return rdm_[spin]; }
499 
500  void print(std::ostream& os = ExEnv::out0()) const;
501 
502  void obsolete();
503 
504  bool sdref() const;
505  double energy() { return 0.0; }
506  double actual_value_accuracy () const { return DBL_EPSILON; }
507  double desired_value_accuracy() const { return DBL_EPSILON; }
508  int nelectron() const { return nelectron_; }
509  bool spin_polarized() const { return rdm_[Alpha] != rdm_[Beta]; }
510  double magnetic_moment() const;
511  bool spin_restricted() const { return true; }
513  int dk() const { return 0; }
514  Ref<GaussianBasisSet> momentum_basis() const { return 0; }
516  const Ref<GaussianBasisSet> &p_basis);
517  unsigned int nfzc() const { return nfzc_; }
518  unsigned int nfzv() const { return nfzv_; }
519  bool omit_uocc() const { return omit_uocc_; }
520  bool ordm_idempotent() const { return ordm_idempotent_; }
521  private:
522  RefSymmSCMatrix rdm_[NSpinCases1];
523  unsigned int nfzc_;
524  unsigned int nfzv_;
525  unsigned int nelectron_;
526  unsigned int magmom_;
527  bool omit_uocc_;
528  mutable bool ordm_idempotent_;
529 
530  void init(const RefSCMatrix& orbs,
531  const std::vector<unsigned int>& orbsym,
532  std::vector<unsigned int> occpi,
533  std::vector<unsigned int> fzcpi,
534  std::vector<unsigned int> fzvpi,
535  std::vector<unsigned int> holepi,
536  std::vector<unsigned int> partpi);
537 
538  void init_spaces() { throw sc::ProgrammingError("For Extern_RefWavefunction, spaces must be init-ed in constructor");}
539  //void init_spaces(unsigned int nocc, const RefSCMatrix& orbs,
540  // const std::vector<unsigned int>& orbsym);
541  void init_spaces(const RefSCMatrix& orbs,
542  const std::vector<unsigned int>& orbsym,
543  std::vector<unsigned int> occpi,
544  std::vector<unsigned int> fzcpi,
545  std::vector<unsigned int> fzvpi,
546  std::vector<unsigned int> holepi,
547  std::vector<unsigned int> partpi);
548  void _set_desired_value_accuracy(double eps) {
549  // do nothing
550  }
551 
552  Ref<DensityFittingInfo> dfinfo() const;
553  };
554 
557  static Ref<RefWavefunction>
558  make(const Ref<WavefunctionWorld>& world,
559  const Ref<Wavefunction>& ref,
560  bool spin_restricted = true,
561  unsigned int nfzc = 0,
562  unsigned int nfzv = 0,
563  Ref<OrbitalSpace> vir_space = 0);
564  };
565 
569  const Ref<OrbitalSpace>& A,
570  SpinCase1 spin);
571 
573  void add_ao_space(const Ref<GaussianBasisSet>& bs,
574  const Ref<Integral>& ints,
575  const Ref<AOSpaceRegistry>& aoreg,
576  const Ref<OrbitalSpaceRegistry> oreg);
578  void remove_ao_space(const Ref<GaussianBasisSet>& bs,
579  const Ref<AOSpaceRegistry>& aoreg,
580  const Ref<OrbitalSpaceRegistry> oreg);
581 
583  // end of addtogroup ChemistryElectronicStructureOneBody
584 
585 };
586 
587 #endif
588 
sc::SD_RefWavefunction::nelectron
int nelectron() const
Definition: ref.h:410
sc::PopulatedOrbitalSpace::orbs_sb
const Ref< OrbitalSpace > & orbs_sb() const
Definition: ref.h:96
sc::Extern_RefWavefunction::Extern_RefWavefunction
Extern_RefWavefunction(const Ref< WavefunctionWorld > &world, const Ref< GaussianBasisSet > &basis, const Ref< Integral > &integral, const RefSCMatrix &orbs, const std::vector< unsigned int > &orbsymm, const RefSymmSCMatrix &alpha_1rdm, const RefSymmSCMatrix &beta_1rdm, unsigned int nocc, unsigned int nfzc=0, unsigned int nfzv=0, bool omit_uocc=false)
Constructs Extern_RefWavefunction using the MO-basis 1-RDMs + MO coefficients (same for alpha and bet...
sc::SD_RefWavefunction::print
void print(std::ostream &os=ExEnv::out0()) const
Print the object.
sc::RefWavefunction::sdref
virtual bool sdref() const =0
is this a single-determinantal reference?
sc::SD_RefWavefunction::energy
double energy()
Definition: ref.h:406
sc::PopulatedOrbitalSpace::uocc_act
const Ref< OrbitalSpace > & uocc_act() const
Definition: ref.h:118
sc::Extern_RefWavefunction::momentum_basis
Ref< GaussianBasisSet > momentum_basis() const
Definition: ref.h:514
sc::SD_RefWavefunction::actual_value_accuracy
double actual_value_accuracy() const
Return the accuracy with which the value has been computed.
Definition: ref.h:407
sc::PopulatedOrbitalSpace::occ
const Ref< OrbitalSpace > & occ() const
Definition: ref.h:102
sc::Extern_RefWavefunction::actual_value_accuracy
double actual_value_accuracy() const
Return the accuracy with which the value has been computed.
Definition: ref.h:506
sc::RefWavefunction::uocc_sb
const Ref< OrbitalSpace > & uocc_sb(SpinCase1 spin=AnySpinCase1) const
Return the space of symmetry-blocked unoccupied (virtual) MOs of the given spin.
sc::RefWavefunction::occ_sb
const Ref< OrbitalSpace > & occ_sb(SpinCase1 spin=AnySpinCase1) const
Return the space of symmery-blocked occupied MOs of the given spin.
sc::RefWavefunction::uocc_basis
virtual const Ref< GaussianBasisSet > & uocc_basis() const
returns the basis supporting unoccupied orbitals. The defauls is same as returned by basis().
Definition: ref.h:226
sc::RefSymmSCMatrix
The RefSymmSCMatrix class is a smart pointer to an SCSymmSCMatrix specialization.
Definition: matrix.h:265
sc::RefWavefunction::set_desired_value_accuracy
void set_desired_value_accuracy(double)
Set the accuracy to which the value is to be computed.
sc::Extern_RefWavefunction::obsolete
void obsolete()
obsoletes this object
sc::SD_RefWavefunction::ordm
RefSymmSCMatrix ordm(SpinCase1 spin) const
return the AO basis density
sc::RefWavefunction::obsolete
virtual void obsolete()
obsoletes this object
sc::RefSCMatrix
The RefSCMatrix class is a smart pointer to an SCMatrix specialization.
Definition: matrix.h:135
sc::Ref
A template class that maintains references counts.
Definition: ref.h:361
sc::Extern_RefWavefunction
RefWavefunction specialization that is not an adaptor to a Wavefunction object.
Definition: ref.h:437
sc::RefWavefunction::magnetic_moment
virtual double magnetic_moment() const =0
sc::RefWavefunction::actual_value_accuracy
virtual double actual_value_accuracy() const =0
Return the accuracy with which the value has been computed.
sc::compute_canonvir_space
Ref< OrbitalSpace > compute_canonvir_space(const Ref< FockBuildRuntime > &fb_rtime, const Ref< OrbitalSpace > &A, SpinCase1 spin)
canonicalize A
sc::RefWavefunction::reset
virtual void reset()
calling this will cause the object to be re-initialized next time it is used
sc::Extern_RefWavefunction::energy
double energy()
Definition: ref.h:505
sc::RefWavefunction::desired_value_accuracy
virtual double desired_value_accuracy() const =0
sc::PopulatedOrbitalSpace::uocc_act_sb
const Ref< OrbitalSpace > & uocc_act_sb() const
Definition: ref.h:116
sc::SD_RefWavefunction::momentum_basis
Ref< GaussianBasisSet > momentum_basis() const
Definition: ref.h:414
sc::RefWavefunction::orbs_sb
const Ref< OrbitalSpace > & orbs_sb(SpinCase1 spin=AnySpinCase1) const
Return the space of symmetry-blocked MOs of the given spin.
sc::PopulatedOrbitalSpace::save_data_state
void save_data_state(StateOut &so)
Save the base classes (with save_data_state) and the members in the same order that the StateIn CTOR ...
sc::PopulatedOrbitalSpace::orbital_registry
const Ref< OrbitalSpaceRegistry > & orbital_registry() const
Definition: ref.h:87
sc::SD_RefWavefunction::desired_value_accuracy
double desired_value_accuracy() const
Definition: ref.h:408
sc::SD_RefWavefunction::dk
int dk() const
Definition: ref.h:413
sc::Extern_RefWavefunction::print
void print(std::ostream &os=ExEnv::out0()) const
Print the object.
sc::PopulatedOrbitalSpace::zero_occupancy
static double zero_occupancy()
an orbital is occupied if its occupancy is greater than this
Definition: ref.h:80
sc::RefWavefunction::dfinfo
virtual Ref< DensityFittingInfo > dfinfo() const =0
which DensityFittingRuntime used to compute this reference wave function
sc::Extern_RefWavefunction::magnetic_moment
double magnetic_moment() const
sc::RefDiagSCMatrix
The RefDiagSCMatrix class is a smart pointer to an DiagSCMatrix specialization.
Definition: matrix.h:389
sc::Extern_RefWavefunction::dk
int dk() const
reimplements RefWavefunction::dk(). Currently only nonrelativistic references are supported.
Definition: ref.h:513
sc::RefWavefunction::dk
virtual int dk() const =0
sc::SD_RefWavefunction::SD_RefWavefunction
SD_RefWavefunction(const Ref< KeyVal > &kv)
A KeyVal constructor is used to generate a SD_RefWavefunction object from a KeyVal object.
sc::RefWavefunction::ordm
virtual RefSymmSCMatrix ordm(SpinCase1 spin) const =0
return the AO basis density
sc::RefWavefunction::occ
const Ref< OrbitalSpace > & occ(SpinCase1 spin=AnySpinCase1) const
Return the space of occupied MOs of the given spin.
sc::PopulatedOrbitalSpace::occ_act
const Ref< OrbitalSpace > & occ_act() const
Definition: ref.h:106
sc::RefWavefunction::valence_orbs
const Ref< OrbitalSpace > & valence_orbs() const
This OrbitalSpace defines valence orbitals.
sc::PopulatedOrbitalSpace::occ_sb
const Ref< OrbitalSpace > & occ_sb() const
Definition: ref.h:100
sc::StateIn
Definition: statein.h:79
sc::RefWavefunction::occ_frz
const Ref< OrbitalSpace > & occ_frz(SpinCase1 spin=AnySpinCase1) const
Return the space of frozen occupied MOs of the given spin.
sc::RefWavefunction::force_average_AB_rdm1_
bool force_average_AB_rdm1_
For spin-free algorithms, if this is true, we would set both alpha/beta 1-rdm to the average of them;...
Definition: ref.h:305
sc::SD_RefWavefunction::purge
void purge()
purges the data from this object
sc::Extern_RefWavefunction::ordm
RefSymmSCMatrix ordm(SpinCase1 spin) const
return the AO basis density
Definition: ref.h:498
sc::SD_RefWavefunction::dfinfo
Ref< DensityFittingInfo > dfinfo() const
which DensityFittingRuntime used to compute this reference wave function
sc::Extern_RefWavefunction::save_data_state
void save_data_state(StateOut &)
Save the base classes (with save_data_state) and the members in the same order that the StateIn CTOR ...
sc::add_ao_space
void add_ao_space(const Ref< GaussianBasisSet > &bs, const Ref< Integral > &ints, const Ref< AOSpaceRegistry > &aoreg, const Ref< OrbitalSpaceRegistry > oreg)
construct and add an AO space to aoreg and oreg
sc::RefWavefunction::init_spaces
virtual void init_spaces()=0
initialize OrbitalSpace objects
sc::Extern_RefWavefunction::nelectron
int nelectron() const
Definition: ref.h:508
sc::PopulatedOrbitalSpace::uocc
const Ref< OrbitalSpace > & uocc() const
Definition: ref.h:114
sc::Extern_RefWavefunction::core_hamiltonian_for_basis
RefSymmSCMatrix core_hamiltonian_for_basis(const Ref< GaussianBasisSet > &basis, const Ref< GaussianBasisSet > &p_basis)
Returns the SO core Hamiltonian in the given basis and momentum basis.
sc::SD_RefWavefunction::uocc_basis
const Ref< GaussianBasisSet > & uocc_basis() const
returns the basis supporting unoccupied orbitals. The defauls is same as returned by basis().
Definition: ref.h:401
sc::RefWavefunction::energy
virtual double energy()=0
sc::RefWavefunction::save_data_state
void save_data_state(StateOut &)
Save the base classes (with save_data_state) and the members in the same order that the StateIn CTOR ...
sc::RefWavefunction::ordm_orbs_sb
virtual RefSymmSCMatrix ordm_orbs_sb(SpinCase1 spin) const
return the density in the orbs_sb() space
sc::PopulatedOrbitalSpace::occ_frz
const Ref< OrbitalSpace > & occ_frz() const
Definition: ref.h:110
sc::RefWavefunction::uocc_act
const Ref< OrbitalSpace > & uocc_act(SpinCase1 spin=AnySpinCase1) const
Return the space of active unoccupied (virtual) MOs of the given spin.
sc::RefWavefunction::occ_act
const Ref< OrbitalSpace > & occ_act(SpinCase1 spin=AnySpinCase1) const
Return the space of active occupied MOs of the given spin.
sc::RefWavefunction::print
virtual void print(std::ostream &os=ExEnv::out0()) const =0
Print the object.
sc::RefWavefunction::RefWavefunction
RefWavefunction(const Ref< KeyVal > &kv)
A KeyVal constructor is used to generate a RefWavefunction object from a KeyVal object.
sc::PopulatedOrbitalSpace::PopulatedOrbitalSpace
PopulatedOrbitalSpace(const Ref< OrbitalSpaceRegistry > &oreg, SpinCase1 spin, const Ref< GaussianBasisSet > &bs, const Ref< Integral > &integral, const RefSCMatrix &coefs, const std::vector< double > &occs, const std::vector< ParticleHoleOrbitalAttributes > &active, const RefDiagSCMatrix &energies, bool eorder_increasing=true, Ref< OrbitalSpace > vbs=0, Ref< FockBuildRuntime > fbrun=0)
sc::RefWavefunction::momentum_basis
virtual Ref< GaussianBasisSet > momentum_basis() const =0
sc::SD_RefWavefunction::core_hamiltonian_for_basis
RefSymmSCMatrix core_hamiltonian_for_basis(const Ref< GaussianBasisSet > &basis, const Ref< GaussianBasisSet > &p_basis)
Returns the SO core Hamiltonian in the given basis and momentum basis.
sc::RefWavefunction::occ_act_sb
const Ref< OrbitalSpace > & occ_act_sb(SpinCase1 spin=AnySpinCase1) const
Return the space of symmery-blocked active occupied MOs of the given spin.
sc::StateOut
Definition: stateout.h:71
sc::SD_RefWavefunction
RefWavefunction specialization for a single-determinant wave function.
Definition: ref.h:328
sc::Extern_RefWavefunction::desired_value_accuracy
double desired_value_accuracy() const
Definition: ref.h:507
sc::RefWavefunction::oso_space
const Ref< OrbitalSpace > & oso_space() const
Returns the space of symmetry-blocked orthogonal SOs (spans the entire space of the basis)
sc::RefWavefunction::desired_value_accuracy_set_to_default
virtual bool desired_value_accuracy_set_to_default() const
sc::PopulatedOrbitalSpace::orbs
const Ref< OrbitalSpace > & orbs() const
Definition: ref.h:98
sc::RefWavefunctionFactory
This factory produces the RefWavefunction that corresponds to the type of ref object.
Definition: ref.h:556
sc::Extern_RefWavefunction::sdref
bool sdref() const
is this a single-determinantal reference?
sc::ProgrammingError
This is thrown when a situations arises that should be impossible.
Definition: scexception.h:92
sc::RefWavefunction::ordm_occ_sb
virtual RefSymmSCMatrix ordm_occ_sb(SpinCase1 spin) const
return the density in the occ_sb() space
sc::RefWavefunction::uocc_act_sb
const Ref< OrbitalSpace > & uocc_act_sb(SpinCase1 spin=AnySpinCase1) const
Return the space of symmetry-blocked active unoccupied (virtual) MOs of the given spin.
sc::SD_RefWavefunction::save_data_state
void save_data_state(StateOut &)
Save the base classes (with save_data_state) and the members in the same order that the StateIn CTOR ...
sc::RefWavefunction
RefWavefunction represents the reference wave function (or, more generally, a state) used as a starti...
Definition: ref.h:159
sc::ExEnv::out0
static std::ostream & out0()
Return an ostream that writes from node 0.
sc::SD_RefWavefunction::sdref
bool sdref() const
is this a single-determinantal reference?
Definition: ref.h:398
sc::RefWavefunction::core_hamiltonian_for_basis
virtual RefSymmSCMatrix core_hamiltonian_for_basis(const Ref< GaussianBasisSet > &basis, const Ref< GaussianBasisSet > &p_basis)=0
Returns the SO core Hamiltonian in the given basis and momentum basis.
sc::RefWavefunction::use_world_dfinfo
bool use_world_dfinfo() const
if true, override density fitting settings of RefWavefunction objects with those of WavefunctionWorld...
Definition: ref.h:165
sc::SavableState
Base class for objects that can save/restore state.
Definition: state.h:45
sc::PopulatedOrbitalSpace::occ_frz_sb
const Ref< OrbitalSpace > & occ_frz_sb() const
Definition: ref.h:108
sc::RefWavefunction::init
void init() const
initializes the object
sc::RefWavefunction::orbs
const Ref< OrbitalSpace > & orbs(SpinCase1 spin=AnySpinCase1) const
Return the space of energy-sorted MOs of the given spin.
sc::PopulatedOrbitalSpace
PopulatedOrbitalSpace is an OrbitalSpace populated with a density.
Definition: ref.h:48
sc::RefWavefunction::nelectron
virtual int nelectron() const =0
sc::RefWavefunction::spin_polarized
bool spin_polarized() const
Definition: ref.h:246
sc::remove_ao_space
void remove_ao_space(const Ref< GaussianBasisSet > &bs, const Ref< AOSpaceRegistry > &aoreg, const Ref< OrbitalSpaceRegistry > oreg)
undo the effect of add_ao_space()
sc::PopulatedOrbitalSpace::uocc_sb
const Ref< OrbitalSpace > & uocc_sb() const
Definition: ref.h:112
sc::SD_RefWavefunction::magnetic_moment
double magnetic_moment() const
Definition: ref.h:411
sc
Contains all MPQC code up to version 3.
Definition: mpqcin.h:14
sc::RefWavefunction::purge
virtual void purge()
purges the data from this object
sc::RefWavefunction::uocc
const Ref< OrbitalSpace > & uocc(SpinCase1 spin=AnySpinCase1) const
Return the space of unoccupied (virtual) MOs of the given spin.
sc::PopulatedOrbitalSpace::occ_act_sb
const Ref< OrbitalSpace > & occ_act_sb() const
Definition: ref.h:104
sc::RefWavefunction::occ_frz_sb
const Ref< OrbitalSpace > & occ_frz_sb(SpinCase1 spin=AnySpinCase1) const
Return the space of symmery-blocked frozen occupied MOs of the given spin.
sc::SD_RefWavefunction::desired_value_accuracy_set_to_default
bool desired_value_accuracy_set_to_default() const
Definition: ref.h:409

Generated at Sun Jan 26 2020 23:23:59 for MPQC 3.0.0-alpha using the documentation package Doxygen 1.8.16.