31    short unsigned int age;  
 
   38    void setSapling(
const float h_m, 
const int age_yrs, 
const int species_idx) { 
height=h_m;
 
   39                                                                                 age=
static_cast<short unsigned int>(age_yrs);
 
  108                             h_max = std::max(
saplings[i].height, h_max);
 
  121            if (
saplings[i].species_index == species_index)
 
  166    short int mAddedVegetative; 
 
  167    short int mRecruited; 
 
  171    short int mCohortsWithDbh; 
 
  172    float mLivingSaplings; 
 
  173    float mLivingSmallSaplings; 
 
  179    float mLeafAreaIndex; 
 
  183    float mCarbonOfRecruitedTrees; 
 
  219    void clearSaplings(
const QRectF &rectangle, 
const bool remove_biomass, 
bool resprout);
 
  226    int addSaplings(
const QRectF &rectangle, QString species, 
double height, 
int age);
 
  236    void vegetativeSprouting(
const Species *species, 
SaplingCell &scell, QPoint tree_pos);
 
  238    static double mRecruitmentVariation;
 
  239    static double mBrowsingPressure;
 
CNPair stores a duple of carbon and nitrogen (kg/ha) use addBiomass(biomass, cnratio) to add biomass;...
Definition: snag.h:31
 
helper class to iterate over a rectangular fraction of a grid
Definition: grid.h:200
 
ResourceUnit is the spatial unit that encapsulates a forest stand and links to several environmental ...
Definition: resourceunit.h:49
 
The class contains data available at ResourceUnit x Species scale.
Definition: resourceunitspecies.h:34
 
Definition: saplings.h:248
 
SaplingCellRunner(const int stand_id, const MapGrid *stand_grid=nullptr)
Definition: saplings.cpp:842
 
SaplingCell * next()
Definition: saplings.cpp:859
 
QPointF currentCoord() const
Definition: saplings.cpp:880
 
ResourceUnit * ru() const
Definition: saplings.h:253
 
~SaplingCellRunner()
Definition: saplings.cpp:853
 
The SaplingStat class stores statistics on the resource unit x species level.
Definition: saplings.h:132
 
double basalArea() const
Definition: saplings.h:159
 
int newSaplingsVegetative() const
Definition: saplings.h:143
 
float leafArea() const
Definition: saplings.h:156
 
const CNPair & carbonGain() const
state of the living
Definition: saplings.h:162
 
void setLeafArea(float leaf_area)
Definition: saplings.h:157
 
double averageAge() const
Definition: saplings.h:153
 
SaplingStat()
Definition: saplings.h:134
 
double averageHeight() const
Definition: saplings.h:152
 
double livingStemNumber(const Species *species, double &rAvgDbh, double &rAvgHeight, double &rAvgAge) const
returns the represented (Reineke's Law) number of trees (N/ha) and the mean dbh/height (cm/m)
Definition: saplings.cpp:800
 
void calculate(const Species *species, ResourceUnit *ru)
calculate statistics (and carbon flows) for the saplings of species 'species' on 'ru'.
Definition: saplings.cpp:689
 
int diedSaplings() const
Definition: saplings.h:144
 
double livingSaplingsSmall() const
Definition: saplings.h:147
 
const CNPair & carbonLiving() const
state of the living
Definition: saplings.h:161
 
double leafAreaIndex() const
Definition: saplings.h:158
 
double livingSaplings() const
number of individual trees in the regen layer (using Reinekes R), with h>1.3m
Definition: saplings.h:146
 
void addCarbonOfDeadSapling(float dbh)
Definition: saplings.h:139
 
double averageDeltaHRealized() const
Definition: saplings.h:155
 
int livingCohorts() const
get the number of cohorts
Definition: saplings.h:145
 
void clearStatistics()
Definition: saplings.cpp:674
 
double averageDeltaHPot() const
Definition: saplings.h:154
 
int recruitedSaplings() const
Definition: saplings.h:148
 
int newSaplings() const
Definition: saplings.h:142
 
The Saplings class the container for the establishment and sapling growth in iLand.
Definition: saplings.h:192
 
QPointF coordOfCell(ResourceUnit *ru, int cell_index)
return the metric coordinates of a given cell at resource unit ru and at the internal index cell_inde...
Definition: saplings.cpp:320
 
void saplingGrowth(const ResourceUnit *ru)
Definition: saplings.cpp:199
 
SaplingCell * cell(QPoint lif_coords, bool only_valid=true, ResourceUnit **rRUPtr=nullptr)
return the SaplingCell (i.e.
Definition: saplings.cpp:297
 
int addSprout(const Tree *t, bool tree_is_removed)
generate vegetative offspring from the tree 't' (sprouts)
Definition: saplings.cpp:408
 
void clearSaplings(const QRectF &rectangle, const bool remove_biomass, bool resprout)
clear/kill all saplings within the rectangle given by 'rectangle'.
Definition: saplings.cpp:328
 
void establishment(const ResourceUnit *ru)
establishment of saplings from seeds see http://iland-model.org/seed+kernel+and+seed+distribution and...
Definition: saplings.cpp:95
 
Saplings()
Definition: saplings.cpp:36
 
static void updateBrowsingPressure()
Definition: saplings.cpp:459
 
int addSaplings(const QRectF &rectangle, QString species, double height, int age)
add saplings by plantings within the (metric) rectangle. Fill cells with trees of given species/heigh...
Definition: saplings.cpp:388
 
void clearAllSaplings()
clear all saplings, biomass is removed (not routed to the soil layer)
Definition: saplings.cpp:376
 
static void setRecruitmentVariation(const double variation)
Definition: saplings.h:231
 
void simplifiedGrassCover(const ResourceUnit *ru)
run the simplified grass cover for a RU
Definition: saplings.cpp:259
 
void setup()
Definition: saplings.cpp:41
 
void calculateInitialStatistics(const ResourceUnit *ru)
Definition: saplings.cpp:60
 
double topHeight(const ResourceUnit *ru) const
calculate the top height of the sapling layer
Definition: saplings.cpp:282
 
The behavior and general properties of tree species.
Definition: species.h:75
 
A tree is the basic simulation entity of iLand and represents a single tree.
Definition: tree.h:44
 
#define NSAPCELLS
Definition: saplings.h:52
 
Definition: saplings.h:53
 
SaplingCell()
Definition: saplings.h:59
 
ECellState
Definition: saplings.h:54
 
@ CellGrass
the cell is empty and has grass cover (see grass module)
Definition: saplings.h:56
 
@ CellEmpty
the cell has no slots occupied (no saplings on the cell)
Definition: saplings.h:55
 
@ CellInvalid
not stockable (outside project area)
Definition: saplings.h:54
 
@ CellFull
Definition: saplings.h:58
 
@ CellFree
seedlings may establish on the cell (at least one slot occupied)
Definition: saplings.h:57
 
SaplingTree saplings[NSAPCELLS]
Definition: saplings.h:64
 
int n_occupied()
count the number of occupied slots on the pixel
Definition: saplings.h:89
 
SaplingTree * saplingOfSpecies(int species_index)
return the sapling tree of the requested species, or 0
Definition: saplings.h:118
 
SaplingTree * addSapling(const float h_m, const int age_yrs, const int species_idx)
add a sapling to this cell, return a pointer to the tree on success, or 0 otherwise
Definition: saplings.h:97
 
void checkState()
Definition: saplings.h:68
 
bool hasFreeSlots() const
returns true if establishment is allowed for the cell
Definition: saplings.h:67
 
int free_index()
get an index to an open slot in the cell, or -1 if all slots are occupied
Definition: saplings.h:82
 
bool has_new_saplings()
Definition: saplings.h:111
 
float max_height()
return the maximum height on the pixel
Definition: saplings.h:105
 
ResourceUnit * ru
Definition: saplings.h:65
 
ECellState state
Definition: saplings.h:63
 
Definition: saplings.h:29
 
ResourceUnitSpecies * resourceUnitSpecies(const ResourceUnit *ru) const
Definition: saplings.cpp:834
 
bool is_browsed() const
Definition: saplings.h:47
 
float height
Definition: saplings.h:35
 
bool is_occupied() const
Definition: saplings.h:36
 
void clear()
Definition: saplings.h:37
 
short unsigned int age
Definition: saplings.h:31
 
unsigned char stress_years
Definition: saplings.h:33
 
bool is_sprout() const
Definition: saplings.h:44
 
short signed int species_index
Definition: saplings.h:32
 
unsigned char flags
Definition: saplings.h:34
 
void set_browsed(const bool browse)
Definition: saplings.h:48
 
void setSapling(const float h_m, const int age_yrs, const int species_idx)
Definition: saplings.h:38
 
void set_sprout(const bool sprout)
Definition: saplings.h:45
 
SaplingTree()
Definition: saplings.h:30