Appearance
adam_rk_object
ADAM, RK class definition.
Source: src/lib/common/adam_rk_object.F90
Dependencies
Contents
- rk_object
- assign_stage
- compute_stage
- compute_stage_ls
- initialize
- initialize_stages
- load_from_file
- update_q
- description
Variables
| Name | Type | Attributes | Description |
|---|---|---|---|
RK_1 | character(len=13) | parameter | Parameter of time scheme, Runge-Kutta 1. |
RK_2 | character(len=13) | parameter | Parameter of time scheme, Runge-Kutta 2. |
RK_3 | character(len=13) | parameter | Parameter of time scheme, Runge-Kutta 3. |
RK_SSP_22 | character(len=18) | parameter | Parameter of time scheme, Runge-Kutta SSP 22. |
RK_SSP_33 | character(len=18) | parameter | Parameter of time scheme, Runge-Kutta SSP 33. |
RK_SSP_54 | character(len=18) | parameter | Parameter of time scheme, Runge-Kutta SSP 54. |
RK_YOSHIDA | character(len=19) | parameter | Parameter of time scheme, Runge-Kutta Yoshida, symplectic 4. |
INI_SECTION_NAME | character(len=11) | parameter | INI (config) file section name containing configs. |
Derived Types
rk_object
RK class definition.
Components
| Name | Type | Attributes | Description |
|---|---|---|---|
mpih | type(mpih_object) | MPI handler. | |
scheme | character(len=:) | allocatable | RK scheme. |
nrk | integer(kind=I4P) | Runge-Kutta stages number. | |
ark | real(kind=R8P) | allocatable | Runge-Kutta low storage alpha coefficients. |
brk | real(kind=R8P) | allocatable | Runge-Kutta low storage beta coefficients. |
crk | real(kind=R8P) | allocatable | Runge-Kutta low storage beta coefficients. |
alph | real(kind=R8P) | allocatable | Runge-Kutta SSP alpha coefficients. |
beta | real(kind=R8P) | allocatable | Runge-Kutta SSP beta coefficients. |
gamm | real(kind=R8P) | allocatable | Runge-Kutta SSP gamma coefficients. |
ssa | real(kind=R8P) | allocatable | Runge-Kutta sympletic-splitting part A coefficients. |
ssb | real(kind=R8P) | allocatable | Runge-Kutta sympletic-splitting part B coefficients. |
q_rk | real(kind=R8P) | allocatable | Field cell centered variables, RK stages. |
field | type(field_object) | pointer | The field. |
grid | type(grid_object) | pointer | The grid. |
ngc | integer(kind=I4P) | pointer | Number of ghost cells. |
ni | integer(kind=I4P) | pointer | Number of cells in i direction. |
nj | integer(kind=I4P) | pointer | Number of cells in j direction. |
nk | integer(kind=I4P) | pointer | Number of cells in k direction. |
nb | integer(kind=I4P) | pointer | Total blocks number for MPI. |
blocks_number | integer(kind=I4P) | pointer | Actual blocks number. |
ns | integer(kind=I4P) | pointer | Number of fluids specie. |
nv | integer(kind=I4P) | pointer | Number of conservative variables. |
Type-Bound Procedures
| Name | Attributes | Description |
|---|---|---|
assign_stage | pass(self) | Assign q to RK stage. |
compute_stage | pass(self) | Compute RK stage. |
compute_stage_ls | pass(self) | Compute RK stage, low storage scheme. |
description | pass(self) | Return pretty-printed object description. |
initialize | pass(self) | Initialize class. |
initialize_stages | pass(self) | Initialize RK stages. |
load_from_file | pass(self) | Load config from file. |
update_q | pass(self) | Update RK q. |
Subroutines
assign_stage
Assign q to RK stage.
fortran
subroutine assign_stage(self, s, q, phi)Arguments
| Name | Type | Intent | Attributes | Description |
|---|---|---|---|---|
self | class(rk_object) | inout | RK object. | |
s | integer(kind=I4P) | in | Current stage number. | |
q | real(kind=R8P) | in | Conservative variables. | |
phi | real(kind=R8P) | in | optional | IB distance. |
Call graph
compute_stage
Compute RK stage.
fortran
subroutine compute_stage(self, s, dt, phi)Arguments
| Name | Type | Intent | Attributes | Description |
|---|---|---|---|---|
self | class(rk_object) | inout | RK object. | |
s | integer(kind=I4P) | in | Current stage number. | |
dt | real(kind=R8P) | in | Current time step. | |
phi | real(kind=R8P) | in | optional | IB distance. |
Call graph
compute_stage_ls
Compute RK stage, low storage scheme. The first (only) stage is assumed to be the previous time step q solution.
fortran
subroutine compute_stage_ls(self, s, dt, phi, dq, q)Arguments
| Name | Type | Intent | Attributes | Description |
|---|---|---|---|---|
self | class(rk_object) | in | RK object. | |
s | integer(kind=I4P) | in | Current RK stage. | |
dt | real(kind=R8P) | in | Current time step. | |
phi | real(kind=R8P) | in | optional | IB distance. |
dq | real(kind=R8P) | in | Conservative variables residuals. | |
q | real(kind=R8P) | inout | Conservative variables stage. |
Call graph
initialize
Initialize class.
fortran
subroutine initialize(self, file_parameters, scheme, grid, field)Arguments
| Name | Type | Intent | Attributes | Description |
|---|---|---|---|---|
self | class(rk_object) | inout | RK object. | |
file_parameters | type(file_ini) | in | optional | Simulation parameters ini file handler. |
scheme | character(len=*) | in | optional | Runge-Kutta scheme. |
grid | type(grid_object) | in | target | The grid. |
field | type(field_object) | in | target | The field. |
Call graph
initialize_stages
Initialize RK stages.
fortran
subroutine initialize_stages(self, q)Arguments
| Name | Type | Intent | Attributes | Description |
|---|---|---|---|---|
self | class(rk_object) | inout | RK object. | |
q | real(kind=R8P) | in | Conservative variables. |
Call graph
load_from_file
Load config from file.
fortran
subroutine load_from_file(self, file_parameters, go_on_fail)Arguments
| Name | Type | Intent | Attributes | Description |
|---|---|---|---|---|
self | class(rk_object) | inout | RK object. | |
file_parameters | type(file_ini) | in | Simulation parameters ini file handler. | |
go_on_fail | logical | in | optional | Go on if load fails. |
Call graph
update_q
Update RK q.
fortran
subroutine update_q(self, dt, phi, q, dq)Arguments
| Name | Type | Intent | Attributes | Description |
|---|---|---|---|---|
self | class(rk_object) | in | RK object. | |
dt | real(kind=R8P) | in | Current time step. | |
phi | real(kind=R8P) | in | optional | IB distance. |
q | real(kind=R8P) | inout | Conservative variables. | |
dq | real(kind=R8P) | inout | optional | Conservative variables residuals. |
Call graph
Functions
description
Return a pretty-formatted object description.
Attributes: pure
Returns: character(len=:)
fortran
function description(self) result(desc)Arguments
| Name | Type | Intent | Attributes | Description |
|---|---|---|---|---|
self | class(rk_object) | in | RK object. |
Call graph