iLand
establishment.h
Go to the documentation of this file.
1/********************************************************************************************
2** iLand - an individual based forest landscape and disturbance model
3** http://iland-model.org
4** Copyright (C) 2009- Werner Rammer, Rupert Seidl
5**
6** This program is free software: you can redistribute it and/or modify
7** it under the terms of the GNU General Public License as published by
8** the Free Software Foundation, either version 3 of the License, or
9** (at your option) any later version.
10**
11** This program is distributed in the hope that it will be useful,
12** but WITHOUT ANY WARRANTY; without even the implied warranty of
13** MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
14** GNU General Public License for more details.
15**
16** You should have received a copy of the GNU General Public License
17** along with this program. If not, see <http://www.gnu.org/licenses/>.
18********************************************************************************************/
19
20#ifndef ESTABLISHMENT_H
21#define ESTABLISHMENT_H
22#include <QtCore/QPoint>
23class Climate;
25
27{
28public:
30 Establishment(const Climate *climate, const ResourceUnitSpecies *rus);
32 void setup(const Climate *climate, const ResourceUnitSpecies *rus);
33 void clear();
35 void writeDebugOutputs();
36 // some informations after execution
37 double avgSeedDensity() const { return mPxDensity;}
38 double abioticEnvironment() const {return mPAbiotic; }
39 int numberEstablished() const { return mNumberEstablished; }
40 bool TACAminTemp() const { return mTACA_min_temp;}
41 bool TACAchill() const { return mTACA_chill;}
42 bool TACgdd() const { return mTACA_gdd;}
43 int growingDegreeDays() const { return mGDD; }
44 bool TACAfrostFree() const { return mTACA_frostfree;}
45 int TACAfrostDaysAfterBudBirst() const { return mTACA_frostAfterBuds; }
46 double avgLIFValue() const { return mLIFcount>0?mSumLIFvalue/double(mLIFcount):0.; }
47 double waterLimitation() const { return mWaterLimitation; }
48
49private:
50 double mPAbiotic;
52 double calculateWaterLimitation();
54 double calculateSOLDepthLimitation();
55
56 const Climate *mClimate;
57 const ResourceUnitSpecies *mRUS;
58 // some statistics
59 double mPxDensity;
60 int mNumberEstablished; // number of established trees in the current year
61 // TACA switches
62 bool mTACA_min_temp; // minimum temperature threshold
63 bool mTACA_chill; // (total) chilling requirement
64 bool mTACA_gdd; // gdd-thresholds
65 int mGDD; // growing degree days
66 bool mTACA_frostfree; // frost free days in vegetation period
67 int mTACA_frostAfterBuds; // frost days after bud birst
68 double mSumLIFvalue;
69 double mWaterLimitation; // scalar 0..1 signifying the drought limitation of establishment
70 int mLIFcount;
71
72};
73
74#endif // ESTABLISHMENT_H
Climate handles climate input data and performs some basic related calculations on that data.
Definition: climate.h:66
Establishment deals with the establishment process of saplings.
Definition: establishment.h:27
void clear()
Definition: establishment.cpp:69
Establishment()
Definition: establishment.cpp:43
bool TACgdd() const
TACA flag for growing degree days.
Definition: establishment.h:42
double abioticEnvironment() const
integrated value of abiotic environment (i.e.: TACA-climate + total iLand environment)
Definition: establishment.h:38
void setup(const Climate *climate, const ResourceUnitSpecies *rus)
setup function that links to a climate and the resource unit / species
Definition: establishment.cpp:53
double avgLIFValue() const
average LIF value of LIF pixels where establishment is tested
Definition: establishment.h:46
bool TACAfrostFree() const
TACA flag for number of frost free days.
Definition: establishment.h:44
double waterLimitation() const
scalar value between 0 and 1 (1: no limitation, 0: no establishment)
Definition: establishment.h:47
int growingDegreeDays() const
the groing degree days (species specific)
Definition: establishment.h:43
bool TACAchill() const
TACA flag chilling requirement.
Definition: establishment.h:41
double avgSeedDensity() const
average seed density on the RU
Definition: establishment.h:37
int TACAfrostDaysAfterBudBirst() const
number of frost days after bud birst
Definition: establishment.h:45
void writeDebugOutputs()
Definition: establishment.cpp:261
bool TACAminTemp() const
TACA flag for minimum temperature.
Definition: establishment.h:40
int numberEstablished() const
return number of newly established trees in the current year
Definition: establishment.h:39
void calculateAbioticEnvironment()
calculate the abiotic environment (TACA model)
Definition: establishment.cpp:166
The class contains data available at ResourceUnit x Species scale.
Definition: resourceunitspecies.h:34