chombo-discharge
Loading...
Searching...
No Matches
Physics::ItoKMC::ItoKMCBackgroundSpecies Class Reference

Encapsulation of a background species for usage with ItoKMCJSON. More...

#include <CD_ItoKMCBackgroundSpecies.H>

Public Types

using MolarFraction = std::function<Real(const RealVect a_pos)>
 Alias for position-dependent molar fraction.

Public Member Functions

 ItoKMCBackgroundSpecies () noexcept
 Default constructor. Must subsequently call the define function.
 ItoKMCBackgroundSpecies (const std::string &a_name, const MolarFraction &a_molarFraction) noexcept
 Full constructor. Calls the define function.
virtual ~ItoKMCBackgroundSpecies () noexcept
 Destructor.
void define (const std::string &a_name, const MolarFraction &a_molarFraction) noexcept
 Define function. Puts object in usable state.
Real molarFraction (const RealVect &a_pos) const noexcept
 Get molar fraction at a physical position.
std::string getName () const noexcept
 Get the species name.

Protected Attributes

bool m_isDefined
 Make sure model has initial data.
std::string m_name
 Neutral species name.
MolarFraction m_molarFraction
 Initial data function.

Detailed Description

Encapsulation of a background species for usage with ItoKMCJSON.

Constructor & Destructor Documentation

◆ ItoKMCBackgroundSpecies()

ItoKMCBackgroundSpecies::ItoKMCBackgroundSpecies ( const std::string & a_name,
const MolarFraction & a_molarFraction )
noexcept

Full constructor. Calls the define function.

Parameters
[in]a_nameSpecies name
[in]a_molarFractionMolar fraction

Member Function Documentation

◆ define()

void ItoKMCBackgroundSpecies::define ( const std::string & a_name,
const MolarFraction & a_molarFraction )
noexcept

Define function. Puts object in usable state.

Parameters
[in]a_nameSpecies name
[in]a_molarFractionMolar fraction

◆ getName()

std::string ItoKMCBackgroundSpecies::getName ( ) const
noexcept

Get the species name.

Returns
m_name

◆ molarFraction()

Real ItoKMCBackgroundSpecies::molarFraction ( const RealVect & a_pos) const
noexcept

Get molar fraction at a physical position.

Parameters
[in]a_posPhysical position.
Returns
Molar fraction of this background species at a_pos.

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