Module with variables and routines to keep track of time.
There are both working and quad precision copies of the time variable that gets updated synchronously when the routines provided here are used.
Type | Visibility | Attributes | Name | Initial | |||
---|---|---|---|---|---|---|---|
real(kind=wp), | private | :: | time | Working precision copy of the time, t. |
|||
real(kind=wp), | private | :: | time_save | Working precision backup copy of the time. |
|||
real(kind=wp), | private | :: | dtime | Δt. |
|||
real(kind=qp), | private | :: | qtime | Quad precision copy of the time, t. |
|||
real(kind=qp), | private | :: | qtime_save | Quad precision backup copy of the time. |
|||
logical, | public | :: | short_timesteps_active | = | .false. | Variable to keep track of whether small Δt is used for quick but smooth turn on of the effective source. |
Function to get the current working precision time, t.
Returns t.
Function to get the current Δt
Returns Δt.
Function to get the current quad precision time, t.
Returns t.
Routine to initialize the time variables.
Type | Intent | Optional | Attributes | Name | ||
---|---|---|---|---|---|---|
real(kind=wp), | intent(in) | :: | t0 | The initial time, t0. |
Routine to make a backup copy of the time.
Routine to restore and increment a backup copy of the time.
Type | Intent | Optional | Attributes | Name | ||
---|---|---|---|---|---|---|
real(kind=wp), | intent(in) | :: | dt | The Δt to use for the increment. |
Routine that sets Δt.
Type | Intent | Optional | Attributes | Name | ||
---|---|---|---|---|---|---|
real(kind=wp), | intent(in) | :: | dt | The value to use for Δt. |
Routine to increment t by Δt.
Type | Intent | Optional | Attributes | Name | ||
---|---|---|---|---|---|---|
real(kind=wp), | intent(in) | :: | dt | The value to use for Δt. |