ThermalSpecies< NormalForceSpecies > Class Template Reference

#include <ThermalSpecies.h>

+ Inheritance diagram for ThermalSpecies< NormalForceSpecies >:

Public Types

typedef ThermalInteraction< typename NormalForceSpecies::InteractionType > InteractionType
 The correct Interaction type for this FrictionForceSpecies. More...
 

Public Member Functions

 ThermalSpecies ()
 The default constructor. More...
 
 ThermalSpecies (const ThermalSpecies &s)
 The default copy constructor. More...
 
virtual ~ThermalSpecies ()
 The default destructor. More...
 
void write (std::ostream &os) const
 Writes the species properties to an output stream. More...
 
void read (std::istream &is)
 Reads the species properties from an input stream. More...
 
std::string getBaseName () const
 Used in Species::getName to obtain a unique name for each Species. More...
 
void actionsAfterTimeStep (BaseParticle *particle) const override
 Computes the heat transfer rate (. More...
 
Mdouble getHeatCapacity () const
 Allows heatCapacity_ to be accessed. More...
 
void setHeatCapacity (Mdouble heatCapacity)
 Allows heatCapacity_ to be changed. More...
 
Mdouble getThermalConductivity () const
 Allows heatCapacity_ to be accessed. More...
 
void setThermalConductivity (Mdouble thermalConductivity)
 Allows heatCapacity_ to be changed. More...
 
Mdouble getAmbientTemperature () const
 
void setAmbientTemperature (Mdouble ambientTemperature)
 
Vec3D getAmbientVelocity () const
 Allows ambientVelocity_ to be accessed. More...
 
void setAmbientVelocity (Vec3D ambientVelocity)
 Allows ambientVelocity_ to be changed. More...
 
Mdouble getAmbientThermalConductivity () const
 Allows ambientThermalConductivity_ to be accessed. More...
 
void setAmbientThermalConductivity (Mdouble ambientThermalConductivity)
 Allows ambientThermalConductivity_ to be changed. More...
 
Mdouble getAmbientDynamicViscosity () const
 Allows ambientDynamicViscosity_ to be accessed. More...
 
void setAmbientDynamicViscosity (Mdouble ambientDynamicViscosity)
 Allows ambientDynamicViscosity_ to be changed. More...
 
Mdouble getAmbientHeatCapacity () const
 Allows ambientHeatCapacity_ to be accessed. More...
 
void setAmbientHeatCapacity (Mdouble ambientHeatCapacity)
 Allows ambientHeatCapacity_ to be changed. More...
 
Mdouble getAmbientDensity () const
 Allows ambientDensity_ to be accessed. More...
 
void setAmbientDensity (Mdouble ambientDensity)
 Allows ambientDensity_ to be changed. More...
 

Private Attributes

Mdouble heatCapacity_
 The specific heat capacity of the particle/wall. More...
 
Mdouble thermalConductivity_
 The thermal conductivity of the particle/wall. More...
 
Mdouble ambientTemperature_
 The ambient temperature (K). More...
 
Vec3D ambientVelocity_
 The velocity of the ambient fluid (m/s). More...
 
double ambientThermalConductivity_
 The thermal conductivity of the ambient fluid (W/m/K). More...
 
double ambientDynamicViscosity_
 The dynamic viscosity of the ambient fluid (kg/m/s=Pa.s). More...
 
double ambientHeatCapacity_
 The specific heat capacity of the ambient fluid (J/kg/K). More...
 
double ambientDensity_
 The density of the ambient fluid (kg/m^3). More...
 

Member Typedef Documentation

◆ InteractionType

template<class NormalForceSpecies >
typedef ThermalInteraction<typename NormalForceSpecies::InteractionType> ThermalSpecies< NormalForceSpecies >::InteractionType

The correct Interaction type for this FrictionForceSpecies.

Constructor & Destructor Documentation

◆ ThermalSpecies() [1/2]

template<class NormalForceSpecies >
ThermalSpecies< NormalForceSpecies >::ThermalSpecies

The default constructor.

166 {
167  heatCapacity_ = 0.0;
168  thermalConductivity_ = 0.0;
170  ambientVelocity_ = {0,0,0};
173  ambientHeatCapacity_ = 0.0;
174  ambientDensity_ = 0.0;
175 }
Defines a contact force parallel to the contact normal.
double ambientDynamicViscosity_
The dynamic viscosity of the ambient fluid (kg/m/s=Pa.s).
Definition: ThermalSpecies.h:150
Mdouble heatCapacity_
The specific heat capacity of the particle/wall.
Definition: ThermalSpecies.h:123
double ambientThermalConductivity_
The thermal conductivity of the ambient fluid (W/m/K).
Definition: ThermalSpecies.h:145
Mdouble thermalConductivity_
The thermal conductivity of the particle/wall.
Definition: ThermalSpecies.h:128
double ambientHeatCapacity_
The specific heat capacity of the ambient fluid (J/kg/K).
Definition: ThermalSpecies.h:155
Vec3D ambientVelocity_
The velocity of the ambient fluid (m/s).
Definition: ThermalSpecies.h:140
double ambientDensity_
The density of the ambient fluid (kg/m^3).
Definition: ThermalSpecies.h:160
Mdouble ambientTemperature_
The ambient temperature (K).
Definition: ThermalSpecies.h:133

References ThermalSpecies< NormalForceSpecies >::ambientDensity_, ThermalSpecies< NormalForceSpecies >::ambientDynamicViscosity_, ThermalSpecies< NormalForceSpecies >::ambientHeatCapacity_, ThermalSpecies< NormalForceSpecies >::ambientTemperature_, ThermalSpecies< NormalForceSpecies >::ambientThermalConductivity_, ThermalSpecies< NormalForceSpecies >::ambientVelocity_, ThermalSpecies< NormalForceSpecies >::heatCapacity_, and ThermalSpecies< NormalForceSpecies >::thermalConductivity_.

◆ ThermalSpecies() [2/2]

◆ ~ThermalSpecies()

template<class NormalForceSpecies >
ThermalSpecies< NormalForceSpecies >::~ThermalSpecies
virtual

The default destructor.

193 {}

Member Function Documentation

◆ actionsAfterTimeStep()

template<class NormalForceSpecies >
void ThermalSpecies< NormalForceSpecies >::actionsAfterTimeStep ( BaseParticle particle) const
override

Computes the heat transfer rate (.

Q) to to convective heat transfer with the ambience

◆ getAmbientDensity()

template<class NormalForceSpecies >
Mdouble ThermalSpecies< NormalForceSpecies >::getAmbientDensity ( ) const
inline

Allows ambientDensity_ to be accessed.

108  {
109  return ambientDensity_;
110  }

References ThermalSpecies< NormalForceSpecies >::ambientDensity_.

◆ getAmbientDynamicViscosity()

template<class NormalForceSpecies >
Mdouble ThermalSpecies< NormalForceSpecies >::getAmbientDynamicViscosity ( ) const
inline

Allows ambientDynamicViscosity_ to be accessed.

86  {
88  }

References ThermalSpecies< NormalForceSpecies >::ambientDynamicViscosity_.

◆ getAmbientHeatCapacity()

template<class NormalForceSpecies >
Mdouble ThermalSpecies< NormalForceSpecies >::getAmbientHeatCapacity ( ) const
inline

Allows ambientHeatCapacity_ to be accessed.

97  {
98  return ambientHeatCapacity_;
99  }

References ThermalSpecies< NormalForceSpecies >::ambientHeatCapacity_.

◆ getAmbientTemperature()

template<class NormalForceSpecies >
Mdouble ThermalSpecies< NormalForceSpecies >::getAmbientTemperature ( ) const
inline

◆ getAmbientThermalConductivity()

template<class NormalForceSpecies >
Mdouble ThermalSpecies< NormalForceSpecies >::getAmbientThermalConductivity ( ) const
inline

Allows ambientThermalConductivity_ to be accessed.

75  {
77  }

References ThermalSpecies< NormalForceSpecies >::ambientThermalConductivity_.

◆ getAmbientVelocity()

template<class NormalForceSpecies >
Vec3D ThermalSpecies< NormalForceSpecies >::getAmbientVelocity ( ) const
inline

Allows ambientVelocity_ to be accessed.

65  {
66  return ambientVelocity_;
67  }

References ThermalSpecies< NormalForceSpecies >::ambientVelocity_.

◆ getBaseName()

template<class NormalForceSpecies >
std::string ThermalSpecies< NormalForceSpecies >::getBaseName

Used in Species::getName to obtain a unique name for each Species.

226 {
227  return "Thermal" + NormalForceSpecies::getBaseName();
228 }

◆ getHeatCapacity()

◆ getThermalConductivity()

template<class NormalForceSpecies >
Mdouble ThermalSpecies< NormalForceSpecies >::getThermalConductivity

◆ read()

template<class NormalForceSpecies >
void ThermalSpecies< NormalForceSpecies >::read ( std::istream &  is)

Reads the species properties from an input stream.

211 {
212  std::string dummy;
214  is >> dummy >> heatCapacity_;
215  is >> dummy >> thermalConductivity_;
216  helpers::readOptionalVariable<Mdouble>(is, "ambientTemperature", ambientTemperature_);
217  helpers::readOptionalVariable<Vec3D>(is, "ambientVelocity", ambientVelocity_);
218  helpers::readOptionalVariable<Mdouble>(is, "ambientThermalConductivity", ambientThermalConductivity_);
219  helpers::readOptionalVariable<Mdouble>(is, "ambientDynamicViscosity", ambientDynamicViscosity_);
220  helpers::readOptionalVariable<Mdouble>(is, "ambientHeatCapacity", ambientHeatCapacity_);
221  helpers::readOptionalVariable<Mdouble>(is, "ambientDensity", ambientDensity_);
222 }
static EIGEN_DEVICE_FUNC EIGEN_STRONG_INLINE std::enable_if_t< PacketLoad, PacketType > read(const TensorMapper &tensorMapper, const StorageIndex &NCIndex, const StorageIndex &CIndex, const StorageIndex &ld)
read, a template function used for loading the data from global memory. This function is used to guar...
Definition: TensorContractionSycl.h:162
std::string string(const unsigned &i)
Definition: oomph_definitions.cc:286

References Eigen::TensorSycl::internal::read(), and oomph::Global_string_for_annotation::string().

Referenced by HeatFluidCoupledSpecies< NormalForceSpecies >::read().

◆ setAmbientDensity()

template<class NormalForceSpecies >
void ThermalSpecies< NormalForceSpecies >::setAmbientDensity ( Mdouble  ambientDensity)
inline

Allows ambientDensity_ to be changed.

113  {
114  logger.assert_always(ambientDensity>0,"ambientDensity has to be positive");
115  ambientDensity_ = ambientDensity;
116  }
Logger< MERCURYDPM_LOGLEVEL > logger("MercuryKernel")
Definition of different loggers with certain modules. A user can define its own custom logger here.

References ThermalSpecies< NormalForceSpecies >::ambientDensity_, and logger.

◆ setAmbientDynamicViscosity()

template<class NormalForceSpecies >
void ThermalSpecies< NormalForceSpecies >::setAmbientDynamicViscosity ( Mdouble  ambientDynamicViscosity)
inline

Allows ambientDynamicViscosity_ to be changed.

91  {
92  logger.assert_always(ambientDynamicViscosity>0,"ambientDynamicViscosity has to be positive");
93  ambientDynamicViscosity_ = ambientDynamicViscosity;
94  }

References ThermalSpecies< NormalForceSpecies >::ambientDynamicViscosity_, and logger.

◆ setAmbientHeatCapacity()

template<class NormalForceSpecies >
void ThermalSpecies< NormalForceSpecies >::setAmbientHeatCapacity ( Mdouble  ambientHeatCapacity)
inline

Allows ambientHeatCapacity_ to be changed.

102  {
103  logger.assert_always(ambientHeatCapacity>0,"ambientHeatCapacity has to be positive");
104  ambientHeatCapacity_ = ambientHeatCapacity;
105  }

References ThermalSpecies< NormalForceSpecies >::ambientHeatCapacity_, and logger.

◆ setAmbientTemperature()

template<class NormalForceSpecies >
void ThermalSpecies< NormalForceSpecies >::setAmbientTemperature ( Mdouble  ambientTemperature)
inline
59  {
60  logger.assert_always(ambientTemperature >= 0,"ambientTemperature cannot be negative");
61  ambientTemperature_ = ambientTemperature;
62  }

References ThermalSpecies< NormalForceSpecies >::ambientTemperature_, and logger.

Referenced by HeatFluidCoupledSpecies< NormalForceSpecies >::read().

◆ setAmbientThermalConductivity()

template<class NormalForceSpecies >
void ThermalSpecies< NormalForceSpecies >::setAmbientThermalConductivity ( Mdouble  ambientThermalConductivity)
inline

Allows ambientThermalConductivity_ to be changed.

80  {
81  logger.assert_always(ambientThermalConductivity>0,"ambientThermalConductivity has to be positive");
82  ambientThermalConductivity_ = ambientThermalConductivity;
83  }

References ThermalSpecies< NormalForceSpecies >::ambientThermalConductivity_, and logger.

◆ setAmbientVelocity()

template<class NormalForceSpecies >
void ThermalSpecies< NormalForceSpecies >::setAmbientVelocity ( Vec3D  ambientVelocity)
inline

Allows ambientVelocity_ to be changed.

70  {
71  ambientVelocity_ = ambientVelocity;
72  }

References ThermalSpecies< NormalForceSpecies >::ambientVelocity_.

◆ setHeatCapacity()

template<class NormalForceSpecies >
void ThermalSpecies< NormalForceSpecies >::setHeatCapacity ( Mdouble  heatCapacity)

Allows heatCapacity_ to be changed.

239 {
240  logger.assert_always(heatCapacity > 0,
241  "[ThermalSpecies<>::setHeatCapacity(%)] value has to be positive",
242  heatCapacity);
243  heatCapacity_ = heatCapacity;
244 }

References logger.

◆ setThermalConductivity()

template<class NormalForceSpecies >
void ThermalSpecies< NormalForceSpecies >::setThermalConductivity ( Mdouble  thermalConductivity)

Allows heatCapacity_ to be changed.

254 {
255  logger.assert_always(thermalConductivity >= 0,
256  "[ThermalSpecies<>::setThermalConductivity(%)] value has to be positive",
257  thermalConductivity);
258  thermalConductivity_ = thermalConductivity;
259 }

References logger.

◆ write()

template<class NormalForceSpecies >
void ThermalSpecies< NormalForceSpecies >::write ( std::ostream &  os) const

Writes the species properties to an output stream.

197 {
199  os << " heatCapacity " << heatCapacity_;
200  os << " thermalConductivity " << thermalConductivity_;
201  os << " ambientTemperature " << ambientTemperature_;
202  os << " ambientVelocity " << ambientVelocity_;
203  os << " ambientThermalConductivity " << ambientThermalConductivity_;
204  os << " ambientDynamicViscosity " << ambientDynamicViscosity_;
205  os << " ambientHeatCapacity " << ambientHeatCapacity_;
206  os << " ambientDensity " << ambientDensity_;
207 }
static EIGEN_DEVICE_FUNC EIGEN_STRONG_INLINE std::enable_if_t< dt !=data_source::global_mem, void > write(PacketType &packet_data, DataScalar ptr)
write, a template function used for storing the data to local memory. This function is used to guaran...
Definition: TensorContractionSycl.h:221

References Eigen::TensorSycl::internal::write().

Referenced by HeatFluidCoupledSpecies< NormalForceSpecies >::write().

Member Data Documentation

◆ ambientDensity_

◆ ambientDynamicViscosity_

template<class NormalForceSpecies >
double ThermalSpecies< NormalForceSpecies >::ambientDynamicViscosity_
private

◆ ambientHeatCapacity_

template<class NormalForceSpecies >
double ThermalSpecies< NormalForceSpecies >::ambientHeatCapacity_
private

◆ ambientTemperature_

◆ ambientThermalConductivity_

template<class NormalForceSpecies >
double ThermalSpecies< NormalForceSpecies >::ambientThermalConductivity_
private

◆ ambientVelocity_

◆ heatCapacity_

template<class NormalForceSpecies >
Mdouble ThermalSpecies< NormalForceSpecies >::heatCapacity_
private

The specific heat capacity of the particle/wall.

Referenced by ThermalSpecies< NormalForceSpecies >::ThermalSpecies().

◆ thermalConductivity_

template<class NormalForceSpecies >
Mdouble ThermalSpecies< NormalForceSpecies >::thermalConductivity_
private

The thermal conductivity of the particle/wall.

Referenced by ThermalSpecies< NormalForceSpecies >::ThermalSpecies().


The documentation for this class was generated from the following files: