Thermal-FIST  1.3
Package for hadron resonance gas model applications
ThermalModelVDWCanonicalStrangeness.h
Go to the documentation of this file.
1 /*
2  * Thermal-FIST package
3  *
4  * Copyright (c) 2018-2019 Volodymyr Vovchenko
5  *
6  * GNU General Public License (GPLv3 or later)
7  */
8 #ifndef THERMALMODELVDWCANONICALSTRANGENESS_H
9 #define THERMALMODELVDWCANONICALSTRANGENESS_H
10 
11 #include <map>
12 #include <iostream>
13 
15 #include "HRGVDW/ThermalModelVDW.h"
16 
17 namespace thermalfist {
18 
37  {
38  public:
46 
52 
54  void FillVirialEV(const std::vector< std::vector<double> > & bij = std::vector< std::vector<double> >(0));
55 
56  // Override functions begin
57 
58  void FillVirial(const std::vector<double> & ri = std::vector<double>(0));
59 
60  void FillAttraction(const std::vector< std::vector<double> > & aij = std::vector< std::vector<double> >(0));
61 
62  void SetVirial(int i, int j, double b) { if (i >= 0 && i < static_cast<int>(m_Virial.size()) && j >= 0 && j < static_cast<int>(m_Virial[i].size())) m_Virial[i][j] = b; }
63 
64  void SetAttraction(int i, int j, double a) { if (i >= 0 && i < static_cast<int>(m_Attr.size()) && j >= 0 && j < static_cast<int>(m_Attr[i].size())) m_Attr[i][j] = a; }
65 
66  double VirialCoefficient(int i, int j) const;
67 
68  double AttractionCoefficient(int i, int j) const;
69 
70  virtual void ReadInteractionParameters(const std::string &filename);
71 
72  virtual void WriteInteractionParameters(const std::string &filename);
73 
74  virtual void CalculateDensitiesGCE();
75 
76  virtual void CalculateEnergyDensitiesGCE();
77 
78  virtual void CalculatePressuresGCE();
79 
80  virtual void CalculatePrimordialDensities();
81 
82  virtual double CalculateEnergyDensity();
83 
84  virtual double CalculateEntropyDensity();
85 
86  virtual double CalculatePressure();
87 
88  virtual bool IsConservedChargeCanonical(ConservedCharge::Name charge) const;
89 
90  // Override functions end
91 
92  protected:
96  void PrepareModelVDW();
97 
99  void ClearModelVDW();
100 
111  virtual void CalculateSums(const std::vector<double> & Vcs);
112 
114  virtual double MuShift(int id) const;
115 
117  std::vector< std::vector<double> > m_Virial;
118  std::vector< std::vector<double> > m_Attr;
119  double m_PNS;
120  std::vector<double> m_MuStar;
121  std::vector<double> m_Suppression;
122  };
123 
124 } // namespace thermalfist
125 
126 #endif // THERMALMODELEVCANONICALSTRANGENESS_H
double VirialCoefficient(int i, int j) const
Excluded volume coefficient .
virtual void CalculateSums(const std::vector< double > &Vcs)
Calculates the necessary strangeness-canonical partition functions.
virtual void CalculatePressuresGCE()
Calculates the grand-canonical pressures.
double AttractionCoefficient(int i, int j) const
QvdW mean field attraction coefficient .
Class implementing the ideal HRG model with exact conservation of strangeness (strangeness-canonical ...
void FillAttraction(const std::vector< std::vector< double > > &aij=std::vector< std::vector< double > >(0))
Class containing the particle list.
Structure containing all thermal parameters of the model.
virtual double MuShift(int id) const
The shift in the chemical potential of particle species i due to the QvdW interactions.
virtual void CalculatePrimordialDensities()
Calculates the primordial densities of all species.
Class implementing the quantum van der Waals HRG model.
virtual bool IsConservedChargeCanonical(ConservedCharge::Name charge) const
Whether the given conserved charge is treated canonically.
virtual void WriteInteractionParameters(const std::string &filename)
Write the QvdW interaction parameters to a file.
Class implementing the quantum van der Waals model in the strangeness-canonical ensemble.
virtual ~ThermalModelVDWCanonicalStrangeness(void)
Destroy the ThermalModelEVCanonicalStrangeness object.
virtual void CalculateEnergyDensitiesGCE()
Calculates the grand-canonical energy densities.
void SetVirial(int i, int j, double b)
Set the excluded volume coefficient .
Name
Set of all conserved charges considered.
virtual double CalculatePressure()
Implementation of the equation of state functions.
ThermalModelVDWCanonicalStrangeness(ThermalParticleSystem *TPS, const ThermalModelParameters &params=ThermalModelParameters())
Construct a new Thermal ModelEVCanonicalStrangeness object.
void FillVirial(const std::vector< double > &ri=std::vector< double >(0))
Fills the excluded volume coefficients based on the provided radii parameters for all species...
void SetAttraction(int i, int j, double a)
Set the vdW mean field attraction coefficient .
virtual void ReadInteractionParameters(const std::string &filename)
Reads the QvdW interaction parameters from a file.
virtual void CalculateDensitiesGCE()
Calculates the particle densities in a grand-canonical ensemble.
The main namespace where all classes and functions of the Thermal-FIST library reside.
ThermalParticleSystem * TPS()
void FillVirialEV(const std::vector< std::vector< double > > &bij=std::vector< std::vector< double > >(0))
Same as FillVirial() but uses the matrix of excluded-volume coefficients as input instead of radii...