Main Page   Class Hierarchy   Compound List   File List   Compound Members   Related Pages  

hsosscf.h

00001 //
00002 // hsosscf.h --- definition of the high-spin open shell SCF class
00003 //
00004 // Copyright (C) 1996 Limit Point Systems, Inc.
00005 //
00006 // Author: Edward Seidl <seidl@janed.com>
00007 // Maintainer: LPS
00008 //
00009 // This file is part of the SC Toolkit.
00010 //
00011 // The SC Toolkit is free software; you can redistribute it and/or modify
00012 // it under the terms of the GNU Library General Public License as published by
00013 // the Free Software Foundation; either version 2, or (at your option)
00014 // any later version.
00015 //
00016 // The SC Toolkit is distributed in the hope that it will be useful,
00017 // but WITHOUT ANY WARRANTY; without even the implied warranty of
00018 // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
00019 // GNU Library General Public License for more details.
00020 //
00021 // You should have received a copy of the GNU Library General Public License
00022 // along with the SC Toolkit; see the file COPYING.LIB.  If not, write to
00023 // the Free Software Foundation, 675 Mass Ave, Cambridge, MA 02139, USA.
00024 //
00025 // The U.S. Government is granted a limited license as per AL 91-7.
00026 //
00027 
00028 #ifndef _chemistry_qc_scf_hsosscf_h
00029 #define _chemistry_qc_scf_hsosscf_h
00030 
00031 #ifdef __GNUC__
00032 #pragma interface
00033 #endif
00034 
00035 #include <chemistry/qc/scf/scf.h>
00036 
00037 // //////////////////////////////////////////////////////////////////////////
00038 
00041 class HSOSSCF: public SCF {
00042   protected:
00043     Ref<PointGroup> most_recent_pg_;
00044     int user_occupations_;
00045     int tndocc_;
00046     int tnsocc_;
00047     int nirrep_;
00048     int *initial_ndocc_;
00049     int *initial_nsocc_;
00050     int *ndocc_;
00051     int *nsocc_;
00052 
00053     ResultRefSymmSCMatrix cl_fock_;
00054     ResultRefSymmSCMatrix op_fock_;
00055 
00056   public:
00057     HSOSSCF(StateIn&);
00100     HSOSSCF(const Ref<KeyVal>&);
00101     ~HSOSSCF();
00102 
00103     void save_data_state(StateOut&);
00104 
00105     void print(std::ostream&o=ExEnv::out()) const;
00106 
00107     double occupation(int irrep, int vectornum);
00108     double alpha_occupation(int irrep, int vectornum);
00109     double beta_occupation(int irrep, int vectornum);
00110 
00111     int n_fock_matrices() const;
00112     RefSymmSCMatrix fock(int);
00113     RefSymmSCMatrix effective_fock();
00114 
00115     void symmetry_changed();
00116     
00117     // returns 1
00118     int spin_polarized();
00119     RefSymmSCMatrix density();
00120     RefSymmSCMatrix alpha_density();
00121     RefSymmSCMatrix beta_density();
00122 
00123   protected:
00124     // these are temporary data, so they should not be checkpointed
00125     RefSymmSCMatrix cl_dens_;
00126     RefSymmSCMatrix cl_dens_diff_;
00127     RefSymmSCMatrix cl_gmat_;
00128     RefSymmSCMatrix op_dens_;
00129     RefSymmSCMatrix op_dens_diff_;
00130     RefSymmSCMatrix op_gmat_;
00131 
00132     RefSymmSCMatrix cl_hcore_;
00133 
00134     void set_occupations(const RefDiagSCMatrix& evals);
00135 
00136     // scf things
00137     void init_vector();
00138     void done_vector();
00139     void reset_density();
00140     double new_density();
00141     double scf_energy();
00142 
00143     Ref<SCExtrapData> extrap_data();
00144     
00145     // gradient things
00146     void init_gradient();
00147     void done_gradient();
00148 
00149     RefSymmSCMatrix lagrangian();
00150     RefSymmSCMatrix gradient_density();
00151 
00152     // hessian things
00153     void init_hessian();
00154     void done_hessian();
00155 
00156     // The Hartree-Fock derivatives
00157     void two_body_deriv_hf(double*grad,double exchange_fraction);
00158 };
00159 
00160 #endif
00161 
00162 // Local Variables:
00163 // mode: c++
00164 // c-file-style: "ETS"
00165 // End:

Generated at Thu Oct 4 18:08:44 2001 for MPQC 2.0.0 using the documentation package Doxygen 1.2.5.