Skip to content

adam_flume_dissipation_object ​

ADAM, FLUME dissipative coefficients: viscosity, heat conduction, Ohmic resistivity (issue #65, M4).

The coefficients are read from [physics], each either as a coefficient or as the dimensionless number it stands for (issue #49, N4, section 4.5); giving two keys of a term is fatal, giving none leaves the term off (ideal):

termcoefficient (code units)numbercoefficient from the number
viscosityviscosity (dynamic, mu)reynoldsmu = 1 / Re
heat conductionconductivity (k)prandtlk = mu cp / Pr
Ohmic resistivity (MHD)resistivity (magnetic diffusivity eta)magnetic_reynolds, lundquist1 / Rm, 1 / S

In code units the references are 1, so a number is the reciprocal coefficient. The [reference] layer converts the dimensional coefficients (mu: length x velocity x density; k the same divided by the gas constant; eta: length x velocity) and leaves the numbers as they are; lundquist needs its Alfvenic preset (the velocity unit is then the Alfven speed and S is Rm). The heat flux is -k grad T with T = p / (rho R).

viscosity_law = power-law makes the viscosity depend on the temperature, mu (T / reference_temperature) ** viscosity_exponent; with prandtl the conductivity follows it, k = mu(T) cp / Pr.

The viscous and heat-conduction kernels landed in issue #65 P2 (Euler), the MHD ones land in P3: until then a non-zero coefficient with an MHD model is refused at initialisation by the common object, so no coefficient is ever ignored silently.

Source: src/app/flume/common/adam_flume_dissipation_object.F90

Dependencies

Contents ​

Variables ​

NameTypeAttributesDescription
INI_SECTION_NAMEcharacter(len=7)parameterINI section of the coefficients.
VISCOSITY_LAW_CONSTANTcharacter(len=8)parameter[physics].(viscosity_law): constant mu.
VISCOSITY_LAW_POWERcharacter(len=9)parameter[physics].(viscosity_law): mu (T / T_ref)^omega.

Derived Types ​

flume_dissipation_object ​

FLUME dissipative coefficients, code units.

Components ​

NameTypeAttributesDescription
mureal(kind=R8P)Dynamic viscosity (at the reference temperature).
kreal(kind=R8P)Thermal conductivity (with Prandtl: at mu).
etareal(kind=R8P)Magnetic diffusivity (Ohmic resistivity).
prandtlreal(kind=R8P)Prandtl number, 0 when k is given directly.
viscosity_lawcharacter(len=:)allocatableViscosity law: constant or power-law.
viscosity_exponentreal(kind=R8P)Power-law exponent omega.
reference_temperaturereal(kind=R8P)Power-law reference temperature.
has_viscositylogicalmu > 0.
has_conductionlogicalk > 0.
has_resistivitylogicaleta > 0.
is_activelogicalAny term on.

Type-Bound Procedures ​

NameAttributesDescription
descriptionpass(self)Return pretty-printed object description.
lawspass(self)Return the temperature laws of the kernels.
load_from_filepass(self)Load the coefficients from file.

Subroutines ​

laws ​

Return the temperature laws as the kernels take them, mu = mu0 (T / tref)^omega_mu, k = k0 (T / tref)^omega_k: the constant law is tref = 1 with zero exponents; under the power law the conductivity follows the viscosity only when it comes from the Prandtl number.

Attributes: pure

fortran
subroutine laws(self, tref, omega_mu, omega_k)

Arguments

NameTypeIntentAttributesDescription
selfclass(flume_dissipation_object)inDissipation.
trefreal(kind=R8P)outReference temperature.
omega_mureal(kind=R8P)outExponents.
omega_kreal(kind=R8P)outExponents.

Call graph

load_from_file ​

Load the coefficients: a coefficient or its number per term (two keys of a term are fatal, none is the ideal 0).

fortran
subroutine load_from_file(self, file_parameters, model, cp)

Arguments

NameTypeIntentAttributesDescription
selfclass(flume_dissipation_object)inoutDissipation.
file_parameterstype(file_ini)inSimulation parameters ini file handler.
modelinteger(kind=I4P)inPhysical model id.
cpreal(kind=R8P)inSpecific heat at constant pressure, code units.

Call graph

Functions ​

description ​

Return a pretty-formatted object description.

Returns: character(len=:)

fortran
function description(self) result(desc)

Arguments

NameTypeIntentAttributesDescription
selfclass(flume_dissipation_object)inDissipation.

Call graph