Go to the source code of this file.
|
subroutine | readstate (stateyear, latstart, latend, lonstart, lonend, nspc) |
| ReadState.
|
|
◆ readstate()
subroutine readstate |
( |
integer, intent(out) | stateyear, |
|
|
integer, intent(in) | latstart, |
|
|
integer, intent(in) | latend, |
|
|
integer, intent(in) | lonstart, |
|
|
integer, intent(in) | lonend, |
|
|
integer, intent(in) | nspc ) |
ReadState.
- Initializes all state variables to zero
- Opens state file
- Reads in line by line in a buffer
- parses this buffer first into species name, lat, lon, year
- checks whether lat and lon are within the simulation domain
- checks whether the species name is one of the species to be simulated
- if checks ok, parses the entire line, taking into account the number of height classes of this species
- stores the read in values in the right location-species-height_class in cell
- USE: FileListModule, FileHandlingModule, LoggerModuleAll_par
- IN:
- Parameters
-
latStart,latEnd,lonStart,lonEnd | : dimensions of simulation domain in relative coordinates, i.e. cell indices |
nspc | : number of species |
- from ALL_par:
- maxhc :INTEGER: max. number of height classes (0-maxhc)
- maxlat, maxlon : INTEGER: number of rows/cols of simulation domain
- spec(maxspc) :TYPE(SpecProperties) :: species properties; here a.o. all species parameters are put to spec
- OUT:
- Parameters
-
stateyear | :INTEGER : year of state output
|
- via All_par:
- stateGrid :TYPE(CurrStateInCell), dimension(:, :), allocatable : current state in each cell (the entire grid)
- CALLS support routines:
- LogError, LogInfo, LogWarning in LoggerModule
- CALLED FROM:
Definition at line 31 of file ReadState.f90.