MADNESS  0.10.1
global_functions.h
Go to the documentation of this file.
1 #ifndef SRC_APPS_molresponse_GLOBAL_FUNCTIONS_H_
2 #define SRC_APPS_molresponse_GLOBAL_FUNCTIONS_H_
3 
4 #include <memory>
5 #include <string>
6 #include <vector>
7 
8 #include "response_parameters.h"
9 
10 
11 
12 
13 
14 struct CalcParams {
18 };
19 void print_molecule(World &world, const GroundStateCalculation &g_params);
20 class plotCoords {
21 public:
23 
25  lo[0] = 0.0;
26  lo[1] = 0.0;
27  lo[2] = 0.0;
28  hi[0] = 0.0;
29  hi[1] = 0.0;
30  hi[2] = 0.0;
31  }
32  plotCoords(size_t direction, double Lp) {
33  lo[0] = 0.0;
34  lo[1] = 0.0;
35  lo[2] = 0.0;
36 
37  hi[0] = 0.0;
38  hi[1] = 0.0;
39  hi[2] = 0.0;
40 
41  lo[direction] = -Lp;
42  hi[direction] = Lp;
43  }
44 };
45 plotCoords SetPlotCoord(size_t i, double Lp);
46 
47 CalcParams initialize_calc_params(World &world, const std::string &input_file);
48 // kinetic energy operator on response vector
50 
51 auto make_k (const vecfuncT &ket, const vecfuncT &bra);
52 auto ground_exchange(const vecfuncT &phi0, const X_space &x, bool compute_y) -> X_space;
53 auto ground_exchange_multiworld(const vecfuncT &phi0, const X_space &x, const bool& compute_y) -> X_space;
54 auto response_exchange(const vecfuncT &phi0, const X_space &x, bool compute_y) -> X_space;
55 vecfuncT K(vecfuncT &ket, vecfuncT &bra, vecfuncT &vf);
56 auto molresponseExchange(World &world, const vecfuncT &ket_i, const vecfuncT &bra_i,
57  const vecfuncT &fp, const int &n, const int &num_states,
58  const int &num_orbitals) -> X_space;
59 auto response_exchange_multiworld(const vecfuncT &phi0, const X_space &chi, const bool &compute_y)
60  -> X_space;
61 vecfuncT newK(const vecfuncT &ket, const vecfuncT &bra, const vecfuncT &vf);
62 // compute exchange |i><i|J|p>
63 static double rsquared(const coord_3d &r) { return r[0] * r[0] + r[1] * r[1] + r[2] * r[2]; }
64 /// Mask function to switch from 0 to 1 smoothly at boundary
65 #endif// SRC_APPS_molresponse_GLOBAL_FUNCTIONS_H_
Definition: ground_parameters.h:25
Definition: molecule.h:124
A parallel world class.
Definition: world.h:132
Definition: global_functions.h:20
plotCoords(size_t direction, double Lp)
Definition: global_functions.h:32
plotCoords()
Definition: global_functions.h:24
coord_3d hi
Definition: global_functions.h:22
coord_3d lo
Definition: global_functions.h:22
double(* f)(const coord_3d &)
Definition: derivatives.cc:54
auto molresponseExchange(World &world, const vecfuncT &ket_i, const vecfuncT &bra_i, const vecfuncT &fp, const int &n, const int &num_states, const int &num_orbitals) -> X_space
Definition: global_functions.cc:248
vecfuncT newK(const vecfuncT &ket, const vecfuncT &bra, const vecfuncT &vf)
Definition: global_functions.cc:236
vecfuncT K(vecfuncT &ket, vecfuncT &bra, vecfuncT &vf)
void print_molecule(World &world, const GroundStateCalculation &g_params)
auto response_exchange_multiworld(const vecfuncT &phi0, const X_space &chi, const bool &compute_y) -> X_space
Definition: global_functions.cc:338
plotCoords SetPlotCoord(size_t i, double Lp)
auto make_k(const vecfuncT &ket, const vecfuncT &bra)
Definition: global_functions.cc:319
auto ground_exchange(const vecfuncT &phi0, const X_space &x, bool compute_y) -> X_space
Definition: global_functions.cc:64
auto response_exchange(const vecfuncT &phi0, const X_space &x, bool compute_y) -> X_space
Definition: global_functions.cc:130
auto ground_exchange_multiworld(const vecfuncT &phi0, const X_space &x, const bool &compute_y) -> X_space
Definition: global_functions.cc:390
CalcParams initialize_calc_params(World &world, const std::string &input_file)
Definition: global_functions.cc:18
response_space T(World &world, response_space &f)
Definition: global_functions.cc:34
static double rsquared(const coord_3d &r)
Definition: global_functions.h:63
vector< functionT > vecfuncT
Definition: mcpfit.cc:51
Definition: global_functions.h:14
GroundStateCalculation ground_calculation
Definition: global_functions.h:15
Molecule molecule
Definition: global_functions.h:16
ResponseParameters response_parameters
Definition: global_functions.h:17
Definition: response_parameters.h:24
Definition: x_space.h:32
Definition: response_functions.h:25