33 #ifndef MADNESS_MOLECULE_H
34 #define MADNESS_MOLECULE_H
59 explicit Atom(
double x,
double y,
double z,
double q,
unsigned int atomic_number)
60 : x(x), y(y), z(z), q(q), atomic_number(atomic_number) {}
63 : x(a.x), y(a.y), z(a.z), q(a.q), atomic_number(a.atomic_number) {}
67 : x(0), y(0), z(0), q(0), atomic_number(0) {}
74 template <
typename Archive>
85 std::vector<Atom> atoms;
86 std::vector<double> rcut;
89 madness::Tensor<double> field;
91 void swapaxes(
int ix,
int iy);
93 template <
typename opT>
94 bool test_for_op(
double xaxis,
double yaxis,
double zaxis, opT
op)
const;
96 bool test_for_c2(
double xaxis,
double yaxis,
double zaxis)
const;
98 bool test_for_sigma(
double xaxis,
double yaxis,
double zaxis)
const;
100 bool test_for_inverse()
const;
106 Molecule() : atoms(), rcut(), eprec(1e-4), core_pot(), field(3
L) {};
135 double core_eval(
int atom,
unsigned int core,
int m,
double x,
double y,
double z)
const;
137 double core_derivative(
int atom,
int axis,
unsigned int core,
int m,
double x,
double y,
double z)
const;
143 void add_atom(
double x,
double y,
double z,
double q,
int atn);
207 template <
typename Archive>
209 ar & atoms & rcut & eprec & core_pot;
double inter_atomic_distance(unsigned int i, unsigned int j) const
Definition: DFcode/molecule.cc:242
double z
Definition: DFcode/molecule.h:56
void set_eprec(double value)
updates rcuts with given eprec
Definition: DFcode/molecule.cc:208
std::ostream & operator<<(std::ostream &s, const Atom &atom)
Definition: DFcode/molecule.cc:64
double molecular_core_potential(double x, double y, double z) const
Definition: DFcode/molecule.cc:639
Header to declare stuff which has not yet found a home.
unsigned int n_core_orb_all() const
Definition: DFcode/molecule.cc:605
double core_derivative(int atom, int axis, unsigned int core, int m, double x, double y, double z) const
Definition: DFcode/molecule.cc:626
std::string guess_file() const
Definition: DFcode/corepotential.h:175
bool is_potential_defined(unsigned int atn) const
Definition: DFcode/molecule.h:139
const double L
Definition: 3dharmonic.cc:123
::std::string string
Definition: gtest-port.h:872
double nuclear_attraction_potential(double x, double y, double z) const
Definition: DFcode/molecule.cc:550
double x
Definition: DFcode/molecule.h:56
double get_core_bc(unsigned int atn, unsigned int c) const
Definition: DFcode/molecule.h:131
Definition: DFcode/corepotential.h:146
void add_atom(double x, double y, double z, double q, int atn)
Definition: DFcode/molecule.cc:161
Atom(double x, double y, double z, double q, unsigned int atomic_number)
Definition: DFcode/molecule.h:59
int natom() const
Definition: DFcode/molecule.h:145
double total_nuclear_charge() const
Definition: DFcode/molecule.cc:542
void set_eprec(double value)
double smallest_length_scale() const
Definition: DFcode/molecule.cc:300
Definition: DFcode/molecule.h:82
std::vector< madness::Vector< double, 3 > > get_all_coords_vec() const
Definition: DFcode/molecule.cc:187
unsigned int n_core_orb(unsigned int atn) const
Definition: DFcode/molecule.h:120
void identify_point_group()
Definition: DFcode/molecule.cc:402
double core_potential_derivative(int atom, int axis, double x, double y, double z) const
Definition: DFcode/molecule.cc:654
Atom()
Default construct makes a zero charge ghost atom at origin.
Definition: DFcode/molecule.h:66
Defines and implements most of Tensor.
void read_core_file(const std::string &filename)
Definition: DFcode/molecule.cc:669
void set_rcut(double value)
Definition: DFcode/molecule.cc:216
double q
Coordinates and charge in atomic units.
Definition: DFcode/molecule.h:56
Vector< T, 1 > vec(T x)
Your friendly neighborhood factory function.
Definition: array.h:456
double nuclear_dipole(int axis) const
Definition: DFcode/molecule.cc:263
FLOAT a(int j, FLOAT z)
Definition: y1.cc:86
Atom(const Atom &a)
Definition: DFcode/molecule.h:62
double get_eprec() const
Definition: DFcode/molecule.h:169
void print() const
Definition: DFcode/molecule.cc:227
std::string guess_file() const
Definition: DFcode/molecule.h:116
void set_core_rcut(double value)
Definition: DFcode/molecule.h:165
void set_all_coords(const madness::Tensor< double > &newcoords)
Definition: DFcode/molecule.cc:198
Molecule()
Makes a molecule with zero atoms.
Definition: DFcode/molecule.h:106
Abstract Atom class.
Definition: DFcode/molecule.h:54
void set_rcut(double value)
double bounding_cube() const
Returns the half width of the bounding cube.
Definition: DFcode/molecule.cc:532
void read_file(const std::string &filename)
Definition: DFcode/molecule.cc:92
const double m
Definition: gfit.cc:199
unsigned int get_core_l(unsigned int atn, unsigned int core) const
Definition: DFcode/corepotential.h:185
double core_eval(int atom, unsigned int core, int m, double x, double y, double z) const
Definition: DFcode/molecule.cc:617
bool is_potential_defined_atom(int i) const
Definition: DFcode/molecule.h:141
double get_core_bc(unsigned int atn, unsigned int core) const
Definition: DFcode/corepotential.h:189
double y
Definition: DFcode/molecule.h:56
const Atom & get_atom(unsigned int i) const
Definition: DFcode/molecule.cc:222
void orient()
Centers and orients the molecule in a standard manner.
Definition: DFcode/molecule.cc:473
unsigned int n_core_orb_base(const unsigned int atn) const
Definition: DFcode/corepotential.h:171
Tensor< double > op(const Tensor< double > &x)
Definition: kain.cc:508
unsigned int get_core_l(unsigned int atn, unsigned int c) const
Definition: DFcode/molecule.h:127
double nuclear_attraction_potential_derivative(int atom, int axis, double x, double y, double z) const
Definition: DFcode/molecule.cc:571
bool is_defined(const unsigned int atn) const
Definition: DFcode/corepotential.h:163
void serialize(Archive &ar)
Definition: DFcode/molecule.h:208
void set_atom_coords(unsigned int i, double x, double y, double z)
Definition: DFcode/molecule.cc:168
double nuclear_repulsion_energy() const
Definition: DFcode/molecule.cc:249
void center()
Moves the center of nuclear charge to the origin.
Definition: DFcode/molecule.cc:310
const double c
Definition: gfit.cc:200
unsigned int atomic_number
Atomic number.
Definition: DFcode/molecule.h:57
madness::Vector< double, 3 > get_coords() const
Definition: DFcode/molecule.h:70
void serialize(Archive &ar)
Definition: DFcode/molecule.h:75
double nuclear_repulsion_derivative(int i, int j) const
Definition: DFcode/molecule.cc:281
double nuclear_charge_density(double x, double y, double z) const
Definition: DFcode/molecule.cc:591
madness::Tensor< double > get_all_coords() const
Definition: DFcode/molecule.cc:176
void set_core_eprec(double value)
Definition: DFcode/molecule.h:161