MPQC 2.3.1

- Main Page
- Related Pages
- Classes
- Files

- File List

hsosscf.h
1 //
2 // hsosscf.h --- definition of the high-spin open shell SCF class
3 //
4 // Copyright (C) 1996 Limit Point Systems, Inc.
5 //
6 // Author: Edward Seidl <seidl@janed.com>
7 // Maintainer: LPS
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_scf_hsosscf_h
29 #define _chemistry_qc_scf_hsosscf_h
30
31 #ifdef __GNUC__
32 #pragma interface
33 #endif
34
35 #include <chemistry/qc/scf/scf.h>
36
37 namespace sc {
38
39 // //////////////////////////////////////////////////////////////////////////
40
43 class HSOSSCF: public SCF {
44 protected:
45 Ref<PointGroup> most_recent_pg_;
46 int user_occupations_;
47 int tndocc_;
48 int tnsocc_;
49 int nirrep_;
50 int *initial_ndocc_;
51 int *initial_nsocc_;
52 int *ndocc_;
53 int *nsocc_;
54
55 ResultRefSymmSCMatrix cl_fock_;
56 ResultRefSymmSCMatrix op_fock_;
57
58 public:
59 HSOSSCF(StateIn&);
103 HSOSSCF(const Ref<KeyVal>&);
104 ~HSOSSCF();
105
106 void save_data_state(StateOut&);
107
108 void print(std::ostream&o=ExEnv::out0()) const;
109
110 double occupation(int irrep, int vectornum);
111 double alpha_occupation(int irrep, int vectornum);
112 double beta_occupation(int irrep, int vectornum);
113
114 int n_fock_matrices() const;
119 RefSymmSCMatrix fock(int i);
121 RefSymmSCMatrix effective_fock();
122
123 void symmetry_changed();
124
125 // returns 1
126 int spin_polarized();
127 RefSymmSCMatrix density();
128 RefSymmSCMatrix alpha_density();
129 RefSymmSCMatrix beta_density();
130
131 protected:
132 // these are temporary data, so they should not be checkpointed
133 RefSymmSCMatrix cl_dens_;
134 RefSymmSCMatrix cl_dens_diff_;
135 RefSymmSCMatrix cl_gmat_;
136 RefSymmSCMatrix op_dens_;
137 RefSymmSCMatrix op_dens_diff_;
138 RefSymmSCMatrix op_gmat_;
139
140 RefSymmSCMatrix cl_hcore_;
141
142 void set_occupations(const RefDiagSCMatrix& evals);
143
144 // scf things
145 void init_vector();
146 void done_vector();
147 void reset_density();
148 double new_density();
149 double scf_energy();
150
151 Ref<SCExtrapData> extrap_data();
152
153 // gradient things
154 void init_gradient();
155 void done_gradient();
156
157 RefSymmSCMatrix lagrangian();
158 RefSymmSCMatrix gradient_density();
159
160 // hessian things
161 void init_hessian();
162 void done_hessian();
163
164 // The Hartree-Fock derivatives
165 void two_body_deriv_hf(double*grad,double exchange_fraction);
166 };
167
168 }
169
170 #endif
171
172 // Local Variables:
173 // mode: c++
174 // c-file-style: "ETS"
175 // End: