DimensionalizeAction

Overview

The DimensionalizeAction action is responsible for fetching the characteristic scales from the user and applying them to dimensionalize any field passed from NekRS into MOOSE (AuxVariables, Postprocessors, UserObjects, etc.). To use, add a [Dimensionalize] block inside the [Problem] block.

Cardinal assumes that the NekRS inputs were nondimensionalized with the following:

uiuiuref u_i^\dagger\equiv\frac{u_i}{u_{ref}}(1)

PPρ0uref2 P^\dagger\equiv\frac{P}{\rho_0u_{ref}^2}(2)

TTTrefΔT T^\dagger\equiv\frac{T-T_{ref}}{\Delta T}(3)

xixiLref x_i^\dagger\equiv\frac{x_i}{L_{ref}}(4)

ttLref/uref t^\dagger\equiv\frac{t}{L_{ref}/u_{ref}}(5)

where \dagger superscripts indicate nondimensional quantities. U is used to specify urefu_{ref}, T is used to specify TrefT_{ref}, dT is used to specify ΔT\Delta T, L is used to specify LrefL_{ref}, rho is used to specify ρ0\rho_0, and Cp is used to specify Cp,0C_{p,0} (which does not appear above, but is necessary for scaling a volumetric heat source). Finally, the mesh mirror must be in the same units as used in the coupled MOOSE application, so the scaling parameter on NekRSMesh must be set to dimensionalize the nondimensional .re2 mesh. In other words, scaling must be set to LrefL_{ref}.

For passive scalars, NekRS allows each to be dimensionalized in a manner similar to temperature,

si=sisi,refΔsis_{i}^\dagger=\frac{s_i-s_{i,ref}}{\Delta s_i}

s01, s02, and s03 are used to indicate the si,refs_{i,ref} for scalars 1, 2, and 3, respectively. ds01, ds02, and ds03 are used to indicate the Δsi\Delta s_i for scalars 1, 2, and 3, respectively.

warningwarning

These characteristic scales are used by Cardinal to scale the NekRS solution into the units that the coupled MOOSE application expects. You still need to properly non-dimensionalize the NekRS input files. That is, you cannot simply specify the non-dimensional scales in this class and expect a dimsensional NekRS input specification to be converted to non-dimensional form.

For example, suppose your NekRS input is in non-dimensional form. Applying a NekVolumeAverage postprocessor to temperature would be used to evaluate a volume average of temperature.

[Postprocessors]
  [avg_T]
    type = NekVolumeAverage
    field = temperature
  []
[]

If the NekRS inputs are properly non-dimensionalized and the correct scales are provided to this class, then temperature is non-dimensionalized according to Eq. (3) and volume is non-dimensionalized according to Eq. (4), or

V=VLref3 V^\dagger=\frac{V}{L_{ref}^3}(6)

The NekVolumeAverage postprocessor is then computed directly on the NekRS solution (in non-dimensional form) to give

pnd=TdVdV p_{nd}=\frac{\int T^\dagger dV^\dagger}{\int dV^\dagger}(7)

where pndp_{nd} is the value of the postprocessor in non-dimensional form. Before returning the value of the postprocessor, Eq. (7) is dimensionalized by applying the scales in Eq. (3) and Eq. (6) to give the

p=TdVdV+TrefΔT p=\frac{\int T^\dagger dV^\dagger}{\int dV^\dagger}+\frac{T_{ref}}{\Delta T}(8)

where pp is the value of the postprocessor in dimensional form (which is what is actually returned by the postprocessor).

Example Input File Syntax

An example where the NekRS input files are set up in non-dimensional form,

[Problem]
  type = NekRSProblem
  casename = 'msfr'
  output = 'temperature'

  synchronization_interval = parent_app

  [Dimensionalize]
    L = 1.0
    U = '${fparse Re * mu / rho}'
    T = '${fparse 625.0 + 273.15}'
    dT = 100.0
    rho = ${rho}
    Cp = 1524.86 # J/kg/K
  []

  normalization_abs_tol = 1e6
  normalization_rel_tol = 1e-3
[]
(tutorials/msfr/nek.i)

Input Parameters

  • Cp1Reference isobaric specific heat

    Default:1

    C++ Type:double

    Unit:(no unit assumed)

    Controllable:No

    Description:Reference isobaric specific heat

  • L1Reference length

    Default:1

    C++ Type:double

    Unit:(no unit assumed)

    Controllable:No

    Description:Reference length

  • T0Reference temperature

    Default:0

    C++ Type:double

    Unit:(no unit assumed)

    Controllable:No

    Description:Reference temperature

  • U1Reference velocity

    Default:1

    C++ Type:double

    Unit:(no unit assumed)

    Controllable:No

    Description:Reference velocity

  • active__all__ If specified only the blocks named will be visited and made active

    Default:__all__

    C++ Type:std::vector<std::string>

    Unit:(no unit assumed)

    Controllable:No

    Description:If specified only the blocks named will be visited and made active

  • dT1Reference temperature difference

    Default:1

    C++ Type:double

    Unit:(no unit assumed)

    Controllable:No

    Description:Reference temperature difference

  • ds011Reference scalar 1 difference

    Default:1

    C++ Type:double

    Unit:(no unit assumed)

    Controllable:No

    Description:Reference scalar 1 difference

  • ds022Reference scalar 2 difference

    Default:2

    C++ Type:double

    Unit:(no unit assumed)

    Controllable:No

    Description:Reference scalar 2 difference

  • ds033Reference scalar 3 difference

    Default:3

    C++ Type:double

    Unit:(no unit assumed)

    Controllable:No

    Description:Reference scalar 3 difference

  • inactiveIf specified blocks matching these identifiers will be skipped.

    C++ Type:std::vector<std::string>

    Unit:(no unit assumed)

    Controllable:No

    Description:If specified blocks matching these identifiers will be skipped.

  • rho1Reference density

    Default:1

    C++ Type:double

    Unit:(no unit assumed)

    Controllable:No

    Description:Reference density

  • s010Reference scalar 1

    Default:0

    C++ Type:double

    Unit:(no unit assumed)

    Controllable:No

    Description:Reference scalar 1

  • s020Reference scalar 2

    Default:0

    C++ Type:double

    Unit:(no unit assumed)

    Controllable:No

    Description:Reference scalar 2

  • s030Reference scalar 3

    Default:0

    C++ Type:double

    Unit:(no unit assumed)

    Controllable:No

    Description:Reference scalar 3

Optional Parameters

  • control_tagsAdds user-defined labels for accessing object parameters via control logic.

    C++ Type:std::vector<std::string>

    Unit:(no unit assumed)

    Controllable:No

    Description:Adds user-defined labels for accessing object parameters via control logic.

Advanced Parameters