1
#ifndef _psi_src_lib_libmints_sobasis_h_
2
#define _psi_src_lib_libmints_sobasis_h_
5
\file libmints/sobasis.h
13
class SOTransformComponent
16
/// Coefficient of the AO
18
/// AO function number
20
/// SO function number
22
/// SO function's irrep
24
/// SO function in irrep
28
SOTransformComponent();
30
/// Returns the coefficient of the AO
31
double coef() const { return coef_; }
32
/// Returns the AO function number
33
int aofunc() const { return aofunc_; }
34
/// Returns the SO function number
35
int sofunc() const { return sofunc_; }
36
/// Returns the SO function's irrep
37
int irrep() const { return irrep_; }
38
/// Return the SO function number in its irrep
39
int sofuncirrep() const { return sofuncirrep_; }
41
void init(int aofunc, int sofunc, int sofuncirrep, int irrep, double coef);
44
class SOTransformShell
47
/// The number of the AO shell from which these functions come.
49
/// Array of SOTransformComponent objects describing the transform
50
std::vector<SOTransformComponent> funcs_;
55
void add_function(int irrep, double coef, int aofunc, int sofunc, int sofuncirrep);
57
void aoshell(int i) { aoshell_ = i; }
58
int aoshell() const { return aoshell_; }
59
int nfunc() const { return funcs_.size(); }
60
SOTransformComponent* func(int i) { return &(funcs_[i]); }
66
SOTransformShell *trans_;
70
SOTransformIter(SOTransformShell* trans) { trans_ = trans; i_ = 0; }
72
void first() { i_ = 0; }
74
bool is_done() { return i_ < trans_->nfunc() ? true : false; }
76
/// Returns the coefficient of component i
77
double coef() const { return trans_->func(i_)->coef(); }
78
/// Returns the AO function number of component i
79
int aofunc() const { return trans_->func(i_)->aofunc(); }
80
/// Returns the SO function number of component i
81
int sofunc() const { return trans_->func(i_)->sofunc(); }
82
/// Returns the SO function's irrep of component i
83
int irrep() const { return trans_->func(i_)->irrep(); }
84
/// Returns the SO function number in its irrep for component i
85
int sofuncirrep() const { return trans_->func(i_)->sofuncirrep(); }
91
/// The SOTransformShell object for each AO
92
std::vector<SOTransformShell> aoshell_;
98
void init(int nshells);
100
/// Add another term to the transform.
101
void add_transform(int aoshell, int irrep, int sofuncirrep, double coef, int aofunc, int sofunc);
103
/// Returns the number of ao shells
104
int naoshell() const { return aoshell_.size(); }
106
/// Return the i'th ao shell
107
SOTransformShell* aoshell(int i) { return &(aoshell_[i]); }