Appearance
adam_flume_mhd_object
ADAM, FLUME MHD class definition: the
[mhd]section.
Loaded only when [physics].(physical_model) = mhd-ideal (issue #41, section 6.2). divergence_control selects the model variant, hence the state width: glm (mixed GLM cleaning, nv = 9) or none (nv = 8). The GLM keys are required with glm only: glm_ch is the constant, uniform cleaning speed; the damping is c_h^2 / c_p^2 = glm_alpha c_h / L, L = glm_damping_length, a positive length or min-cell (the minimum cell spacing of the realm over the active directions, Mignone & Tzeferacos 2010; set by set_glm_damping once the grid exists, issue #41, section 3.5); glm_ch_check decides what happens when the fastest wave outruns c_h (warning or error). divb_tol arms the div(B) monitor (0 disables it) and divb_error makes an exceeded tolerance fatal. rho_floor and p_floor are the positivity floors (0 disables them).
Source: src/app/flume/common/adam_flume_mhd_object.F90
Dependencies
Contents
Variables
| Name | Type | Attributes | Description |
|---|---|---|---|
INI_SECTION_NAME | character(len=3) | parameter | INI (config) file section name containing MHD configs. |
Derived Types
flume_mhd_object
FLUME MHD class definition.
Components
| Name | Type | Attributes | Description |
|---|---|---|---|
divergence_control | character(len=:) | allocatable | Divergence control: glm or none. |
has_glm | logical | GLM cleaning active (host-side flag only). | |
glm_ch | real(kind=R8P) | GLM cleaning speed (constant, uniform). | |
glm_alpha | real(kind=R8P) | GLM damping parameter. | |
glm_damping_length | real(kind=R8P) | GLM damping length (min-cell: set by set_glm_damping). | |
glm_damping_min_cell | logical | The damping length is the minimum cell spacing. | |
glm_damping | real(kind=R8P) | Damping rate c_h^2 / c_p^2 (set by set_glm_damping). | |
glm_ch_check | character(len=:) | allocatable | Action when the fastest wave outruns c_h. |
divb_tol | real(kind=R8P) | div(B) monitor tolerance (0: disabled). | |
divb_error | logical | Stop when the div(B) tolerance is exceeded. | |
rho_floor | real(kind=R8P) | Density floor (0: disabled). | |
p_floor | real(kind=R8P) | Pressure floor (0: disabled). |
Type-Bound Procedures
| Name | Attributes | Description |
|---|---|---|
description | pass(self) | Return pretty-printed object description. |
initialize | pass(self) | Initialize MHD configs. |
load_from_file | pass(self) | Load config from file. |
set_glm_damping | pass(self) | Set the damping length (min-cell) and the damping rate. |
Subroutines
initialize
Initialize MHD configs.
fortran
subroutine initialize(self, file_parameters)Arguments
| Name | Type | Intent | Attributes | Description |
|---|---|---|---|---|
self | class(flume_mhd_object) | inout | MHD configs. | |
file_parameters | type(file_ini) | in | Simulation parameters ini file handler. |
Call graph
load_from_file
Load config from file; every key in use is required and an unknown or out-of-range value is fatal.
fortran
subroutine load_from_file(self, file_parameters)Arguments
| Name | Type | Intent | Attributes | Description |
|---|---|---|---|---|
self | class(flume_mhd_object) | inout | MHD configs. | |
file_parameters | type(file_ini) | in | Simulation parameters ini file handler. |
Call graph
set_glm_damping
Set the damping length (with min-cell, the minimum cell spacing of the realm) and the damping rate c_h^2 / c_p^2 = glm_alpha c_h / L (issue #41, section 3.5); a no-op without GLM.
fortran
subroutine set_glm_damping(self, min_cell)Arguments
| Name | Type | Intent | Attributes | Description |
|---|---|---|---|---|
self | class(flume_mhd_object) | inout | MHD configs. | |
min_cell | real(kind=R8P) | in | Minimum cell spacing of the realm (active directions). |
Call graph
Functions
description
Return a pretty-formatted object description.
Returns: character(len=:)
fortran
function description(self) result(desc)Arguments
| Name | Type | Intent | Attributes | Description |
|---|---|---|---|---|
self | class(flume_mhd_object) | in | MHD configs. |
Call graph