Superdrop Attributes¶
Header file: <libs/superdrops/superdrop_attrs.hpp>
[source]
-
struct SoluteProperties¶
Struct representing the properties of solute in a super-droplet.
Public Functions
-
inline double rho_sol() const¶
Get the density of solute (dimensionless).
- Returns:
Solute density.
-
inline double mr_sol() const¶
Get the molecular mass of solute (dimensionless).
- Returns:
The molecular mass of solute.
-
inline double ionic() const¶
Get the degree ionic dissociation (van’t Hoff factor) (dimensionless).
- Returns:
The degree ionic dissociation.
-
inline double rho_sol() const¶
-
struct SuperdropAttrs¶
Struct representing the attributes of a super-droplet.
Public Functions
-
SuperdropAttrs() = default¶
Default constructor requirement for use of SuperdropAttrs in Kokkos View.
-
~SuperdropAttrs() = default¶
Default destructor requirement for use of SuperdropAttrs in Kokkos View.
-
inline SuperdropAttrs(const SoluteProperties solute, const uint64_t xi, const double radius, const double msol)¶
Constructor with parameters.
- Parameters:
solute – The solute properties.
xi – The multiplicity of superdroplet.
radius – The radius of superdroplet.
msol – The mass of solute dissolved.
-
inline bool is_solute() const¶
Check if solute is present.
- Returns:
True
-
inline auto get_solute() const¶
Get the solute properties.
- Returns:
The solute properties.
-
inline auto get_rho_sol() const¶
Get the density of solute.
- Returns:
The solute density.
-
inline auto get_mr_sol() const¶
Get the molecular mass of the solute.
- Returns:
The molecular mass of the solute.
-
inline auto get_ionic() const¶
Get the degree ionic dissociation (van’t Hoff factor).
- Returns:
The ionic dissociation (van’t Hoff factor).
-
inline void set_xi(const uint64_t i_xi)¶
Set the multiplicity of superdroplet.
Set the multiplicity ‘xi’ of the superdroplet with assert that new xi >= 1.
- Parameters:
i_xi – The multiplicity to set.
-
inline void set_radius(const double i_radius)¶
Set the radius of the super-droplet.
This function sets the value of the super-droplet’s radius to the specified value with assert that new radius >= dry radius within 10^(-6) micron tolerance.
Note: See also change_radius which limits super-droplet radius to its dry radius.
- Parameters:
i_radius – The value to set for radius.
-
inline void set_msol(const double i_msol)¶
Sets the value of the super-droplet’s mass of solute.
This function sets the value of the super-droplet’s solute mass to the specified value.
- Parameters:
i_msol – The value to set for msol.
-
double mass() const¶
Get the total droplet mass.
Calculates and returns total droplet mass = water + dry areosol.
- Returns:
The total droplet mass.
-
inline double dryradius() const¶
Get the dry radius of droplet.
Calculate radius as if droplet is dry, ie. radius if droplet was only made of its solute mass
- Returns:
The dry radius of droplet.
-
inline double rcubed() const¶
Get the cubed radius of droplet.
- Returns:
The cubed radius of droplet.
-
inline double vol() const¶
Get the spherical volume of droplet.
Volume as if droplet is sphere given its radius.
- Returns:
The spherical volume of droplet.
-
double change_radius(const double newr)¶
Change the radius of droplet.
Update droplet radius to larger out of new radius ‘newr’ or dry radius and return the resultant change in radius = new radius - old radius. Prevents drops shrinking further once they are size of dry radius.
- Parameters:
newr – The new radius to set.
- Returns:
The change in radius.
Public Members
-
SoluteProperties solute¶
instance of SoluteProperties for pointer-like reference to superdrop’s solute properties.
-
uint64_t xi¶
Multiplicity of superdrop.
-
double radius¶
Radius of superdrop.
-
double msol¶
Mass of solute dissolved in superdrop.
-
SuperdropAttrs() = default¶