Version: SMASH-1.5
potentials.h
Go to the documentation of this file.
1 /*
2  *
3  * Copyright (c) 2014-2018
4  * SMASH Team
5  *
6  * GNU General Public License (GPLv3 or later)
7  *
8  */
9 
10 #ifndef SRC_INCLUDE_POTENTIALS_H_
11 #define SRC_INCLUDE_POTENTIALS_H_
12 
13 #include <utility>
14 #include <vector>
15 
16 #include "configuration.h"
17 #include "density.h"
18 #include "forwarddeclarations.h"
19 #include "particledata.h"
20 #include "threevector.h"
21 
22 namespace smash {
23 
31 class Potentials {
32  public:
44  Potentials(Configuration conf, const DensityParameters &parameters);
46  ~Potentials();
47 
56  double skyrme_pot(const double baryon_density) const;
57 
66  double symmetry_pot(const double baryon_isospin_density) const;
67 
85  double potential(const ThreeVector &r, const ParticleList &plist,
86  const ParticleType &acts_on) const;
87 
104  std::pair<double, int> force_scale(const ParticleType &data) const;
105 
122  std::pair<ThreeVector, ThreeVector> skyrme_force(
123  const double density, const ThreeVector grad_rho, const ThreeVector dj_dt,
124  const ThreeVector rot_j) const;
125 
141  std::pair<ThreeVector, ThreeVector> symmetry_force(
142  const ThreeVector grad_rho, const ThreeVector dj_dt,
143  const ThreeVector rot_j) const;
144 
160  std::tuple<ThreeVector, ThreeVector, ThreeVector, ThreeVector> all_forces(
161  const ThreeVector &r, const ParticleList &plist) const;
162 
164  bool use_skyrme() const { return use_skyrme_; }
166  bool use_symmetry() const { return use_symmetry_; }
167 
168  private:
175 
178 
181 
186  double skyrme_a_;
187 
192  double skyrme_b_;
193 
198  double skyrme_tau_;
199 
201  double symmetry_s_;
202 };
203 
204 } // namespace smash
205 
206 #endif // SRC_INCLUDE_POTENTIALS_H_
A class to pre-calculate and store parameters relevant for density calculation.
Definition: density.h:103
The ThreeVector class represents a physical three-vector with the components .
Definition: threevector.h:30
double skyrme_a_
Parameter of skyrme potentials: the coefficient in front of in GeV.
Definition: potentials.h:186
bool use_symmetry_
Symmetry potential on/off.
Definition: potentials.h:180
~Potentials()
Standard destructor.
Definition: potentials.cc:94
double symmetry_s_
coefficent in front of the symmetry term.
Definition: potentials.h:201
Potentials(Configuration conf, const DensityParameters &parameters)
Potentials constructor.
bool use_skyrme() const
Definition: potentials.h:164
Interface to the SMASH configuration files.
std::pair< double, int > force_scale(const ParticleType &data) const
Evaluates the scaling factor of the forces acting on the particles.
Definition: potentials.cc:135
std::pair< ThreeVector, ThreeVector > symmetry_force(const ThreeVector grad_rho, const ThreeVector dj_dt, const ThreeVector rot_j) const
Evaluates the electrical and magnetic components of the symmetry force.
Definition: potentials.cc:167
double skyrme_pot(const double baryon_density) const
Evaluates skyrme potential given a baryon density.
Definition: potentials.cc:96
Particle type contains the static properties of a particle species.
Definition: particletype.h:87
const DensityParameters param_
Struct that contains the gaussian smearing width , the distance cutoff and the testparticle number n...
Definition: potentials.h:174
bool use_skyrme_
Skyrme potential on/off.
Definition: potentials.h:177
double potential(const ThreeVector &r, const ParticleList &plist, const ParticleType &acts_on) const
Evaluates potential at point r.
Definition: potentials.cc:111
std::tuple< ThreeVector, ThreeVector, ThreeVector, ThreeVector > all_forces(const ThreeVector &r, const ParticleList &plist) const
Evaluates the electrical and magnetic components of the forces at point r.
Definition: potentials.cc:181
double skyrme_b_
Parameters of skyrme potentials: the coefficient in front of in GeV.
Definition: potentials.h:192
bool use_symmetry() const
Definition: potentials.h:166
double skyrme_tau_
Parameters of skyrme potentials: the power index.
Definition: potentials.h:198
A class that stores parameters of potentials, calculates potentials and their gradients.
Definition: potentials.h:31
double symmetry_pot(const double baryon_isospin_density) const
Evaluates symmetry potential given baryon isospin density.
Definition: potentials.cc:107
std::pair< ThreeVector, ThreeVector > skyrme_force(const double density, const ThreeVector grad_rho, const ThreeVector dj_dt, const ThreeVector rot_j) const
Evaluates the electrical and magnetic components of the skyrme force.
Definition: potentials.cc:151
Definition: action.h:24