Module for handling timing in CABLE.
| Type | Visibility | Attributes | Name | Initial | |||
|---|---|---|---|---|---|---|---|
| integer, | public, | parameter | :: | seconds_per_hour | = | 3600 | |
| integer, | public, | parameter | :: | hours_per_day | = | 24 | |
| integer, | public, | parameter | :: | seconds_per_day | = | 86400 | |
| integer, | public, | parameter | :: | months_in_year | = | 12 | |
| integer, | private, | parameter, dimension(months_in_year) | :: | last_day | = | [31, 59, 90, 120, 151, 181, 212, 243, 273, 304, 334, 365] |
Cumulative day of year at the end of each month for a non-leap year. |
| integer, | private, | parameter, dimension(months_in_year) | :: | last_day_leap | = | [31, 60, 91, 121, 152, 182, 213, 244, 274, 305, 335, 366] |
Cumulative day of year at the end of each month for a leap year. |
| integer, | private, | parameter | :: | START_YEAR_UNDEFINED | = | -1 | |
| integer, | private | :: | start_year | = | START_YEAR_UNDEFINED |
Start year of the simulation. |
Determines whether the current time step matches the specified frequency.
| Type | Intent | Optional | Attributes | Name | ||
|---|---|---|---|---|---|---|
| real, | intent(in) | :: | dels |
Model time step in seconds |
||
| integer, | intent(in) | :: | ktau |
Current time step index |
||
| character(len=*), | intent(in) | :: | frequency |
Frequency string: 'all', 'user', 'daily', 'monthly' |
Utility function to determine whether one frequency is greater than another following the ordering "all" > "user" > "daily" > "monthly".
| Type | Intent | Optional | Attributes | Name | ||
|---|---|---|---|---|---|---|
| character(len=*), | intent(in) | :: | freq_a |
The first frequency to compare, one of "all", "user", "daily", or "monthly". |
||
| character(len=*), | intent(in) | :: | freq_b |
The second frequency to compare, one of "all", "user", "daily", or "monthly". |
||
| real, | intent(in) | :: | dels |
Model time step in seconds, used for comparing against "user" frequencies. |
Set the start year of the simulation. This is used for calculating monthly timing.
| Type | Intent | Optional | Attributes | Name | ||
|---|---|---|---|---|---|---|
| integer, | intent(in) | :: | year |