MPQC 2.3.1

- Main Page
- Related Pages
- Classes
- Files

- File List

psiwfn.h
1
2 #ifdef __GNUC__
3 #pragma interface
4 #endif
5
6 #ifndef _chemistry_qc_psi_psiwfn_h
7 #define _chemistry_qc_psi_psiwfn_h
8
9 #include <chemistry/qc/wfn/wfn.h>
10 #include <chemistry/qc/psi/psiexenv.h>
11
12 namespace sc {
13
15
20 class PsiWavefunction: public Wavefunction {
21
22 Ref<PsiExEnv> exenv_;
23
24 int* read_occ(const Ref<KeyVal> &keyval, const char *name, int nirrep);
25
26 protected:
27 int nirrep_;
28 int *docc_;
29 int *socc_;
30 int *frozen_docc_;
31 int *frozen_uocc_;
32 int multp_;
33 int charge_;
34 char *memory_;
36 virtual void write_input(int conv) =0;
37
38 public:
53 PsiWavefunction(const Ref<KeyVal>&);
54 PsiWavefunction(StateIn&);
55 ~PsiWavefunction();
56
57 void save_data_state(StateOut&);
58
61 virtual void write_basic_input(int conv);
62 void compute();
63 void print(std::ostream&o=ExEnv::out0()) const;
64 RefSymmSCMatrix density();
65 int nelectron();
66
68 Ref<PsiExEnv> get_psi_exenv() const { return exenv_; };
70 Ref<PsiInput> get_psi_input() const { return exenv_->get_psi_input(); };
71 };
72
75
76 class PsiSCF: public PsiWavefunction {
77 public:
78 PsiSCF(const Ref<KeyVal>&);
79 PsiSCF(StateIn&);
80 ~PsiSCF();
81 void save_data_state(StateOut&);
82
83 enum RefType {rhf, hsoshf, uhf};
85 virtual PsiSCF::RefType reftype() const =0;
86 };
87
90
91 class PsiCLHF: public PsiSCF {
92 protected:
93 void write_input(int conv);
94 public:
95 PsiCLHF(const Ref<KeyVal>&);
96 PsiCLHF(StateIn&);
97 ~PsiCLHF();
98
99 void write_basic_input(int conv);
100 int spin_polarized() { return 0;};
101 int gradient_implemented() const { return 1;};
102 PsiSCF::RefType reftype() const { return rhf;};
103 };
104
107
108 class PsiHSOSHF: public PsiSCF {
109 protected:
110 void write_input(int conv);
111 public:
112 PsiHSOSHF(const Ref<KeyVal>&);
113 PsiHSOSHF(StateIn&);
114 ~PsiHSOSHF();
115
116 void write_basic_input(int conv);
117 int spin_polarized() { return 0;};
118 int gradient_implemented() const { return 1;};
119 PsiSCF::RefType reftype() const { return hsoshf;};
120 };
121
124
125 class PsiUHF: public PsiSCF {
126 protected:
127 void write_input(int conv);
128 public:
129 PsiUHF(const Ref<KeyVal>&);
130 PsiUHF(StateIn&);
131 ~PsiUHF();
132
133 void write_basic_input(int conv);
134 int spin_polarized() { return 1;};
135 int gradient_implemented() const { return 1;};
136 PsiSCF::RefType reftype() const { return uhf;};
137 };
138
141
142 class PsiCCSD: public PsiWavefunction {
143 Ref<PsiSCF> reference_;
144 protected:
145 void write_input(int conv);
146 public:
147 PsiCCSD(const Ref<KeyVal>&);
148 PsiCCSD(StateIn&);
149 ~PsiCCSD();
150 void save_data_state(StateOut&);
151 int spin_polarized() { return reference_->spin_polarized();};
152 int gradient_implemented() const;
153 };
154
157
158 class PsiCCSD_T: public PsiWavefunction {
159 Ref<PsiSCF> reference_;
160 protected:
161 void write_input(int conv);
162 public:
163 PsiCCSD_T(const Ref<KeyVal>&);
164 PsiCCSD_T(StateIn&);
165 ~PsiCCSD_T();
166
167 void save_data_state(StateOut&);
168 int spin_polarized() { return reference_->spin_polarized();};
169 int gradient_implemented() const;
170 };
171
172 }
173
174 #endif