MPQC  2.3.1
gaussshell.h
1 //
2 // gaussshell.h
3 //
4 // Copyright (C) 1996 Limit Point Systems, Inc.
5 //
6 // Author: Curtis Janssen <cljanss@limitpt.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_basis_gaussshell_h
29 #define _chemistry_qc_basis_gaussshell_h
30 
31 #ifdef __GNUC__
32 #pragma interface
33 #endif
34 
35 #include <iostream>
36 #include <util/state/state.h>
37 #include <math/scmat/vector3.h>
38 #include <util/keyval/keyval.h>
39 
40 namespace sc {
41 
42 class CartesianIter;
43 class SphericalTransformIter;
44 class Integral;
45 
48 {
49  public:
50  enum PrimitiveType { Normalized, Unnormalized };
51  enum GaussianType { Cartesian, Pure };
52  private:
53  int nprim;
54  int ncon;
55  int* l;
56  int* puream;
57  double* exp;
58  double** coef; // contraction coefficients for unnormalized primitives
59 
60  // computed data:
61  int nfunc;
62  int min_am_;
63  int max_am_;
64  int ncart_;
65  int has_pure_;
66  void init_computed_data();
67 
68  double shell_normalization(int);
69  void convert_coef();
70  void normalize_shell();
71  PrimitiveType keyval_init(const Ref<KeyVal>&,int,int);
72  static const char* amtypes;
73  static const char* AMTYPES;
74 
75  int test_monobound(double &r, double &bound) const;
76  public:
98  int ncn,
99  int nprm,
100  double* e,
101  int* am,
102  int* pure,
103  double** c,
104  PrimitiveType pt = GaussianShell::Normalized,
105  bool do_normalize_shell = true);
111  int ncn,
112  int nprm,
113  double* e,
114  int* am,
115  GaussianType pure,
116  double** c,
117  PrimitiveType pt = GaussianShell::Normalized);
119  GaussianShell(const Ref<KeyVal>&);
125  GaussianShell(const Ref<KeyVal>&,int pure);
126  ~GaussianShell();
127  void save_data_state(StateOut&);
129  int nprimitive() const { return nprim; }
131  int ncontraction() const { return ncon; }
133  int nfunction() const { return nfunc; }
135  int max_angular_momentum() const { return max_am_; }
137  int min_angular_momentum() const { return min_am_; }
139  int max_cartesian() const;
141  int am(int con) const { return l[con]; }
143  int max_am() const { return max_am_; }
145  int min_am() const { return min_am_; }
147  char amchar(int con) const { return amtypes[l[con]]; }
149  int nfunction(int con) const;
151  int ncartesian() const { return ncart_; }
154  int ncartesian_with_aminc(int aminc) const;
156  int ncartesian(int con) const { return ((l[con]+2)*(l[con]+1))>>1; }
158  int is_cartesian(int con) const { return !puream[con]; }
160  int is_pure(int con) const { return puream[con]; }
162  int has_pure() const { return has_pure_; }
164  double coefficient_unnorm(int con,int prim) const {return coef[con][prim];}
166  double coefficient_norm(int con,int prim) const;
168  double exponent(int iprim) const { return exp[iprim]; }
169 
173  const SCVector3& r, double* basis_values);
177  const SCVector3& R,
178  double* g_values,
179  double* basis_values=0) const;
183  const SCVector3& R,
184  double* h_values, double* g_values=0,
185  double* basis_values=0) const;
186 
190  double relative_overlap(const Ref<Integral>&,
191  int con, int func1, int func2) const;
196  double relative_overlap(int con,
197  int a1, int b1, int c1,
198  int a2, int b2, int c2) const;
199 
201  int equiv(const GaussianShell *s);
202 
205  double extent(double threshold) const;
206 
210  double monobound(double r) const;
211 
212  void print(std::ostream& =ExEnv::out0()) const;
213 };
214 
215 }
216 
217 #endif
218 
219 // Local Variables:
220 // mode: c++
221 // c-file-style: "CLJ"
222 // End:

Generated at Fri Aug 3 2012 03:28:48 for MPQC 2.3.1 using the documentation package Doxygen 1.8.1.1.