DFT-FE 1.1.0-pre
Density Functional Theory With Finite-Elements
Loading...
Searching...
No Matches
GaussianBasis.h
Go to the documentation of this file.
1// ---------------------------------------------------------------------
2//
3// Copyright (c) 2017-2025 The Regents of the University of Michigan and DFT-FE
4// authors.
5//
6// This file is part of the DFT-FE code.
7//
8// The DFT-FE code is free software; you can use it, redistribute
9// it, and/or modify it under the terms of the GNU Lesser General
10// Public License as published by the Free Software Foundation; either
11// version 2.1 of the License, or (at your option) any later version.
12// The full text of the license can be found in the file LICENSE at
13// the top level of the DFT-FE distribution.
14//
15// ---------------------------------------------------------------------
16//
17// @author Bikash Kanungo
18//
19
20#ifndef DFTFE_GAUSSIANBASIS_H
21#define DFTFE_GAUSSIANBASIS_H
22
23#include <vector>
24#include <unordered_map>
25#include <string>
26#include <utility>
27#include <string>
28
29#include "AtomicBasis.h"
30
31namespace dftfe
32{
34 {
35 int nC; // number of primitive Gaussians that are contracted
36 int l; // azimuthal (angular) quantum number
37 int m; // magnetic quantum number
38 std::vector<double> alpha; // exponent of each of the primtive Gaussians
39 std::vector<double> c; // coefficient of each of the primtive Gaussians
40 std::vector<double> norm; // normalization constant for the radial part of
41 // each of the primitive Gaussians
42 };
43
45 {
46 const std::string * symbol; // atom symbol
47 const double * center; // atom center coordinates
48 const ContractedGaussian *cg; // pointer to the ContractedGaussian
49 };
50
52 {
53 public:
54 GaussianBasis(const double rTol = 1e-10,
55 const double angleTol = 1e-10); // Constructor
56 ~GaussianBasis(); // Destructor
57
58 void
60 const std::vector<std::pair<std::string, std::vector<double>>>
61 & atomCoords,
62 const std::unordered_map<std::string, std::string> &atomBasisFileNames);
63
64 int
65 getNumBasis() const;
66
67 std::vector<double>
68 getBasisValue(const unsigned int basisId,
69 const std::vector<double> &x) const;
70
71 std::vector<double>
72 getBasisGradient(const unsigned int basisId,
73 const std::vector<double> &x) const;
74
75 std::vector<double>
76 getBasisLaplacian(const unsigned int basisId,
77 const std::vector<double> &x) const;
78
79 private:
80 std::unordered_map<std::string, std::vector<ContractedGaussian *>>
82 std::vector<GaussianBasisInfo> d_gaussianBasisInfo;
83 std::vector<std::pair<std::string, std::vector<double>>>
85 double d_rTol;
86 double d_angleTol;
87 };
88} // namespace dftfe
89#endif // DFTFE_GAUSSIANBASIS_H
Definition AtomicBasis.h:31
std::vector< double > getBasisLaplacian(const unsigned int basisId, const std::vector< double > &x) const
std::vector< std::pair< std::string, std::vector< double > > > d_atomSymbolsAndCoords
Definition GaussianBasis.h:84
double d_angleTol
Definition GaussianBasis.h:86
std::vector< GaussianBasisInfo > d_gaussianBasisInfo
Definition GaussianBasis.h:82
int getNumBasis() const
std::vector< double > getBasisValue(const unsigned int basisId, const std::vector< double > &x) const
void constructBasisSet(const std::vector< std::pair< std::string, std::vector< double > > > &atomCoords, const std::unordered_map< std::string, std::string > &atomBasisFileNames)
std::vector< double > getBasisGradient(const unsigned int basisId, const std::vector< double > &x) const
double d_rTol
Definition GaussianBasis.h:85
std::unordered_map< std::string, std::vector< ContractedGaussian * > > d_atomToContractedGaussiansPtr
Definition GaussianBasis.h:81
GaussianBasis(const double rTol=1e-10, const double angleTol=1e-10)
Definition pseudoPotentialToDftfeConverter.cc:34
@ e
Definition ExcSSDFunctionalBaseClass.h:52
Definition GaussianBasis.h:34
std::vector< double > alpha
Definition GaussianBasis.h:38
std::vector< double > c
Definition GaussianBasis.h:39
int nC
Definition GaussianBasis.h:35
int l
Definition GaussianBasis.h:36
std::vector< double > norm
Definition GaussianBasis.h:40
int m
Definition GaussianBasis.h:37
Definition GaussianBasis.h:45
const std::string * symbol
Definition GaussianBasis.h:46
const double * center
Definition GaussianBasis.h:47
const ContractedGaussian * cg
Definition GaussianBasis.h:48