LandscapeDNDC 1.37.0
vocjjv.h
1
18#ifndef LM_PHYSIOLOGY_VOCJJV_H_
19#define LM_PHYSIOLOGY_VOCJJV_H_
20
21#include "mbe_legacymodel.h"
22#include "state/mbe_state.h"
23
24namespace ldndc {
25
26class LDNDC_API PhysiologyVOCJJV : public MBE_LegacyModel
27{
28 LMOD_EXPORT_MODULE_INFO(PhysiologyVOCJJV,"physiology:vocjjv","Physiology VOCJJV");
29
30 /*** module specific constants ***/
31
33 static double const BETA;
35 static double const BETA_MONO;
37 static double const BETA_OVOC;
39 static double const TREF;
41 static double const PPFD0;
43 static double const TEMP0;
45 static double const ABSO;
47 static double const C1;
49 static double const C2;
51 static double const GAMMA_MAX;
53 static double const CEO_ISO;
55 static double const CEO_MONO;
57 static double const PAR0_SUN;
59 static double const PAR0_SHD;
60
61
62 public:
63 PhysiologyVOCJJV( MoBiLE_State *,
64 cbm::io_kcomm_t *,
65 timemode_e);
66
67 ~PhysiologyVOCJJV();
68
69 lerr_t configure(
70 ldndc::config_file_t const *);
71
72 lerr_t initialize();
73
74 lerr_t solve();
75
76 lerr_t finalize() { return LDNDC_ERR_OK; }
77
78 lerr_t sleep() { return LDNDC_ERR_OK; }
79 lerr_t wake() { return LDNDC_ERR_OK; }
80
81// private:
82 bool CALC_SYNTHASE_ACTIVITY;
83 bool CALCULATE_PAR_TEMP_TERM;
84
85 /* required state components */
86 substate_airchemistry_t & ac;
87 substate_microclimate_t & mc;
88 substate_physiology_t & ph;
89
90 MoBiLE_PlantVegetation * m_veg;
91 input_class_setup_t const * m_setup;
92
93 private:
94 struct photosynth_t
95 {
96 double par; // photosynthetic active radiation (umol m-2 s-1)
97 double par24; // 1 day aggregated photosynthetic active radiation (umol m-2 s-1)
98 double par240; // 10 days aggregated photosynthetic active radiation (umol m-2 s-1)
99 double parabs; // absorbed sunlit photosynthetic active radiation (umol m-2 s-1)
100
101
102 photosynth_t();
103 };
104 struct foliage_t
105 {
106 double tempK; // foliage temperature within a canopy layer (K)
107 double tempK24; // 1 day aggregated foliage temperature within a canopy layer (K)
108 double tempK240; // 10 days aggregated foliage temperature within a canopy layer (K)
109
110 foliage_t();
111 };
112
113 struct temp_par_seasonality_t
114 {
115 double eopt_iso; // factor for temperature dependence of past days for isoprene emissions
116 double eopt_mono; // factor for temperature dependence of past days for light dependent monoterpene emission
117 double c_p; // 10 days aggregated foliage temperature within a canopy layer (K)
118
119 temp_par_seasonality_t();
120 };
121
122 struct gamma_factor_t
123 {
124 //double a; // activity factor for Leaf Age (rg: common to both MEGAN and JJV; fw: I don't think that we need this in JJv)
125 double t_mono; // monoterpenes activity factor for Temperature (light independent fraction of temperature dependence)
126 double t_ovoc; // other VOCs activity factor for Temperature (light independent fraction of temperature dependence
127 double ph; // BVOC emission activity factor for photosynthesis (energy supply)
128 double ph_sun; // BVOC emission activity factor for photosynthesis (energy supply) of sunlit leaves
129 double ph_shd; // BVOC emission activity factor for photosynthesis (energy supply) of shaded leaves
130
131 double phnorm; // normalized activity factor for photosynthesis (energy supply)
132 double phrel; // fraction of ph and phnorm
133//fw: old and not needed double en; // activity factor related to enzyme activity
134 double en_iso; // activity factor related to enzyme activity (isoprene synthase)
135 double en_mono; // activity factor related to enzyme activity (monoterpene synthase)
136 double ennorm; // normalized activity factor related to enzyme activity
137 double ennorm_iso; // normalized activity factor related to enzyme activity (isoprene synthase)
138 double ennorm_mono;// normalized activity factor related to enzyme activity (monoterpene synthase)
139 double enrel; // fraction of e and enorm
140 double rer; // relative emission response/total scaling factor (-)
141 double iso; // relative emission response/total scaling factor for isoprene (-)
142 double mono; // relative emission response/total scaling factor for monoterpene (-)
143// gamma_factor_t();
144 };
145
146 struct leaf_emission_t
147 {
148 size_t foliage_layer;
149 double isoprene; // leaf level isoprene emission (ug gDW-1 h-1)
150 double monoterpene; // leaf level monoterpene emission (ug gDW-1 h-1)
151 double monoterpene_s; // leaf level monoterpene emission from storages (ug gDW-1 h-1)
152 double ovoc; // leaf level ovoc emission from storages (ug gDW-1 h-1)
153
154 photosynth_t pho;
155 foliage_t fol;
156 temp_par_seasonality_t tpar;
157 };
158
159 lerr_t CalcLeafEmission(
160 leaf_emission_t * /* _lemi */,
161 leaf_emission_t * /* _leminorm */,
162 MoBiLE_Plant *);
163
164 double get_jjv_gamma_PH(
165 leaf_emission_t *,
166 MoBiLE_Plant * ) const;
167
168 double get_jjv_gamma_PH_norm(
169 leaf_emission_t *,
170 MoBiLE_Plant * ) const;
171
172
173 lerr_t get_jjv_gamma_EN(
174 leaf_emission_t *,
175 leaf_emission_t *,
176 MoBiLE_Plant * ,
177 gamma_factor_t *) const;
178
179 lerr_t get_temp_par_seasonality(
180 leaf_emission_t *) const;
181
182
183 void step_init();
184};
185} /*namespace ldndc*/
186
187#endif /* !LM_PHYSIOLOGY_VOCJJV_H_ */
Spatially explicit groundwater model.
Definition: airchemistryput.h:15