|
2.0.0b10
catchment modelling framework
|
A list of meteorological stations. More...
A list of meteorological stations.
Can find the nearest station for a position and calculate the temperature lapse
Public Member Functions | |
| MeteoStationList () | |
| Create empty list. | |
| MeteoStationList (const MeteoStationList ©) | |
| Copy c'tor. | |
| MeteoStation::ptr | add_station (std::string name, cmf::geometry::point position, double latitude=51.0, double longitude=8.0, double tz=1.0, cmf::math::Time startTime=cmf::math::Time(1, 1, 2001), cmf::math::Time timestep=cmf::math::day) |
| Creates a meteorological station at a certain position and adds it to the list. | |
| double | calculate_Temp_lapse (cmf::math::Time begin, cmf::math::Time step, cmf::math::Time end) |
| Calculates the temperature lapse from all stations in the list and sets the T_lapse attribute of each station. | |
| MeteoStation::ptr | operator[] (const std::string &Name) const |
| gets a station by name | |
| MeteoStation::ptr | operator[] (ptrdiff_t index) const |
| Gets the station at index. | |
| MeteoStationReference | reference_to_nearest (const cmf::geometry::point &position, double z_weight=0) const |
| Creates a MeteoStationReference from the nearest station to position at position. | |
| ptrdiff_t | remove_station (ptrdiff_t index) |
| Removes a station and returns the number of remaining references to the removed station. If the station is deleted, 0 is returned. | |
| size_t | size () const |
| Returns the number of stations. | |
| MeteoStation::ptr add_station | ( | std::string | name, |
| cmf::geometry::point | position, | ||
| double | latitude = 51.0, | ||
| double | longitude = 8.0, | ||
| double | tz = 1.0, | ||
| cmf::math::Time | startTime = cmf::math::Time(1, 1, 2001), | ||
| cmf::math::Time | timestep = cmf::math::day ) |
Creates a meteorological station at a certain position and adds it to the list.
| name | Name of the station |
| position | The location of the station in map coordinates |
| latitude | Latitude of the study area (for solar radiation) |
| longitude | Longitude of the study area (for solar time) |
| tz | Time zone of the study area (e.g Germany +1,U.S. Pacific time -8 |
| startTime | Date of the beginning of the climatic data (may be changed for each time series later) |
| timestep | Frequency of climatic data (may be changed for each time series later) |
| double calculate_Temp_lapse | ( | cmf::math::Time | begin, |
| cmf::math::Time | step, | ||
| cmf::math::Time | end ) |
Calculates the temperature lapse from all stations in the list and sets the T_lapse attribute of each station.
Returns the average lapse over the whole period.
| MeteoStationReference reference_to_nearest | ( | const cmf::geometry::point & | position, |
| double | z_weight = 0 ) const |
Creates a MeteoStationReference from the nearest station to position at position.
The distance is calculated as \( d=\sqrt{(x_{s} - x_{l})^2 + (y_{s} - y_{l})^2} + \lambda_z\|z_{s} - z_{l}\| \) Where \(s\) is the station and \(l\) is the locatable
| position | The position (any locatable, like e.g. Cell possible) to look for the station. The reference should be owned by the locatable |
| z_weight | The weight of the height difference \(\lambda_z\) |