The BioCro C++ Library
c4_leaf_photosynthesis.cpp
Go to the documentation of this file.
2#include "c4photo.h" // for c4photoC
3#include "leaf_energy_balance.h" // for leaf_energy_balance
4
6
7string_vector c4_leaf_photosynthesis::get_inputs()
8{
9 return {
10 "absorbed_longwave", // J / (m^2 leaf) / s
11 "absorbed_shortwave", // J / (m^2 leaf) / s
12 "alpha1", // mol / mol
13 "atmospheric_pressure", // Pa
14 "b0", // mol / m^2 / s
15 "b1", // dimensionless
16 "beta", // dimensionless
17 "Catm", // micromol / mol
18 "gbw_canopy", // m / s
19 "Gs_min", // mol / m^2 / s
20 "incident_ppfd", // micromol / (m^2 leaf) / s
21 "kparm", // mol / m^2 / s
22 "leafwidth", // m
23 "lowerT", // degrees C
24 "rh", // dimensionless
25 "RL_at_25", // micromol / m^2 / s
26 "StomataWS", // dimensionless
27 "temp", // degrees C
28 "theta", // dimensionless
29 "upperT", // degrees C
30 "Vcmax_at_25", // micromol / m^2 / s
31 "windspeed" // m / s
32 };
33}
34
36{
37 return {
38 "Assim", // micromol / m^2 /s
39 "Ci", // micromol / mol
40 "Cs", // micromol / m^2 / s
41 "EPenman", // mmol / m^2 / s
42 "EPriestly", // mmol / m^2 / s
43 "gbw", // mol / m^2 / s
44 "GrossAssim", // micromol / m^2 /s
45 "Gs", // mol / m^2 / s
46 "leaf_temperature", // degrees C
47 "RHs", // dimensionless from Pa / Pa
48 "RH_canopy", // dimensionless
49 "RL", // micromol / m^2 / s
50 "Rp", // micromol / m^2 / s
51 "TransR" // mmol / m^2 / s
52 };
53}
54
55void c4_leaf_photosynthesis::do_operation() const
56{
57 // Make an initial guess for boundary layer conductance
58 double const gbw_guess{1.2}; // mol / m^2 / s
59
60 // Get an initial estimate of stomatal conductance, assuming the leaf is at
61 // air temperature
62 const double initial_stomatal_conductance =
64 incident_ppfd, ambient_temperature, ambient_temperature,
65 rh, Vcmax_at_25, alpha1, kparm, theta, beta,
66 RL_at_25, b0, b1, Gs_min, StomataWS, Catm, atmospheric_pressure,
67 upperT, lowerT, gbw_guess)
68 .Gs; // mol / m^2 / s
69
70 // Calculate a new value for leaf temperature
72 absorbed_longwave,
73 absorbed_shortwave,
74 atmospheric_pressure,
75 ambient_temperature,
76 gbw_canopy,
77 leafwidth,
78 rh,
79 initial_stomatal_conductance,
80 windspeed);
81
82 const double leaf_temperature = ambient_temperature + et.Deltat; // degrees C
83
84 // Calculate final values for assimilation, stomatal conductance, and Ci
85 // using the new leaf temperature
86 const photosynthesis_outputs photo =
88 incident_ppfd, leaf_temperature, ambient_temperature,
89 rh, Vcmax_at_25, alpha1, kparm,
90 theta, beta, RL_at_25, b0, b1, Gs_min, StomataWS, Catm,
91 atmospheric_pressure, upperT, lowerT,
92 et.gbw_molecular);
93
94 // Update the outputs
95 update(Assim_op, photo.Assim);
96 update(Ci_op, photo.Ci);
97 update(Cs_op, photo.Cs);
98 update(EPenman_op, et.EPenman);
99 update(EPriestly_op, et.EPriestly);
100 update(gbw_op, et.gbw_molecular);
101 update(GrossAssim_op, photo.GrossAssim);
102 update(Gs_op, photo.Gs);
103 update(leaf_temperature_op, leaf_temperature);
104 update(RHs_op, photo.RHs);
105 update(RH_canopy_op, et.RH_canopy);
106 update(RL_op, photo.RL);
107 update(Rp_op, photo.Rp);
108 update(TransR_op, et.TransR);
109}
photosynthesis_outputs c4photoC(double const Qp, double const leaf_temperature, double const ambient_temperature, double const relative_humidity, double const Vcmax_at_25, double const alpha, double const kparm, double const theta, double const beta, double const RL_at_25, double const bb0, double const bb1, double const Gs_min, double const StomaWS, double const Ca, double const atmospheric_pressure, double const upperT, double const lowerT, double const gbw)
Definition: c4photo.cpp:22
Uses the method from CanAC() to calculate leaf photosynthesis parameters for C4 plants.
energy_balance_outputs leaf_energy_balance(double absorbed_longwave_energy, double absorbed_shortwave_energy, double air_pressure, double air_temperature, double gbw_canopy, double leaf_width, double relative_humidity, double stomatal_conductance, double wind_speed)
Calculates leaf-level temperature and transpiration rate for a leaf within a canopy using a Penman-Mo...
double EPriestly
Priestly transpiration rate (mmol / m^2 / s)
double TransR
Transpiration rate (mmol / m^2 / s)
double EPenman
Potential transpiration rate (mmol / m^2 / s)
double gbw_molecular
Total boundary layer conductance to water vapor, for molecular fluxes (mol / m^2 / s)
double RH_canopy
Relative humidity in the canopy, just outside the leaf boundary layer (dimensionless)
double Deltat
Temperature difference (leaf - air) (degrees C)
A simple structure for holding the output of photosynthesis calculations.
double RL
Rate of non-photorespiratory CO2 release in the light (micromol / m^2 / s)
double Rp
Rate of photorespiration (micromol / m^2 / s)
double Cs
CO2 concentration at the leaf surface (micromol / mol)
double Assim
Net CO2 assimilation rate (micromol / m^2 / s)
double RHs
Relative humidity at the leaf surface (dimensionless)
double Ci
CO2 concentration in intercellular spaces (micromol / mol)
double GrossAssim
Gross CO2 assimilation rate (micromol / m^2 / s)
double Gs
Stomatal conductance to water vapor (mol / m^2 / s)