Scine::Sparrow  5.0.0
Library for fast and agile quantum chemical calculations with semiempirical methods.
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Pages
oneCenterTwoElectronIntegrals.h
Go to the documentation of this file.
1 
8 #ifndef SPARROW_ONECENTERTWOELECTRONINTEGRALS_H
9 #define SPARROW_ONECENTERTWOELECTRONINTEGRALS_H
10 
14 #include <Eigen/Core>
15 #include <exception>
16 #include <vector>
17 
18 namespace Scine {
19 namespace Sparrow {
20 
21 namespace nddo {
22 
23 class NoElementSetException : public std::exception {};
24 class NoExponentsSetException : public std::exception {};
26 enum class BasisFunctions;
27 
33  public:
34  using orb_index_t = int;
35 
36  void setElement(Utils::ElementType e, BasisFunctions basisFunctions = BasisFunctions::spd);
37  void calculateIntegrals();
38  int getNumberIntegrals() const;
39 
40  void set(orb_index_t a, orb_index_t b, orb_index_t c, orb_index_t d, double value);
41  double get(orb_index_t a, orb_index_t b, orb_index_t c, orb_index_t d) const;
42  double get(int index) const;
43  const Eigen::MatrixXd getIntegralMatrix();
44 
45  void setSlaterCondonParameters(const SlaterCondonParameters* slaterCondonParameters);
46 
47  private:
48  void initialize(BasisFunctions basisFunctions);
49  void setExchangePIntegral();
50  void calculateIntegralsFromExponents();
51  bool needsIntegralsFromSlaterCondonParameters();
52 
53  Utils::ElementType element_;
54  int nIntegrals_;
55  std::vector<double> integrals_;
56  std::vector<bool> alreadyGiven_;
57  const SlaterCondonParameters* scPar_{nullptr};
59  bool elementHasBeenSet_{false};
60 };
61 
62 } // namespace nddo
63 
64 } // namespace Sparrow
65 } // namespace Scine
66 #endif // SPARROW_ONECENTERTWOELECTRONINTEGRALS_H
Definition: SlaterCondonParameters.h:43
Definition: OneCenterTwoElectronCalculator.h:29
Definition: oneCenterTwoElectronIntegrals.h:32
Definition: oneCenterTwoElectronIntegrals.h:24
Definition: oneCenterTwoElectronIntegrals.h:23