![]() |
LandscapeDNDC 1.37.0
|
Functions | |
| build_parent_map (root=xmlparameters) | |
| find_species (root, mnemonic) | |
| _get_from_default (root, name_lower) | |
| get_par (name, species_mnemonic, root=xmlparameters, parent_map=parent_map) | |
| get_par (_name, _type='mean') | |
| Helpers. | |
| weibull (_x, _p1, _p2, _p3=1.0) | |
| Response functions. | |
| get_par_range (_name) | |
| plot_response_row (_ax, _func, _x, _names, _xlabel, _ylabel, _xlim=None, _ylim=None, _legend=False) | |
| plot_response (_filename, _func, _x, _names, _xlabel, _ylabel, _xlim=None, _ylim=None, _legend=False, _adjust=None) | |
| plot_single (_filename, _func, _x, _xlabel, _ylabel, _xlim=None, _ylim=None) | |
| ph_logistic (_x, _ph_50, _width) | |
| ph_bell (_x, _half_width, _exponent, _ph_opt) | |
| ph_cutoff (_fact) | |
| get_par (_name, _xml) | |
| Helpers. | |
Variables | |
| fig = plt.figure( figsize=(7, 4)) | |
| zs = np.array([temp(x, t1, t2) * weibull(y, w1, w2, w3) for x,y in zip(np.ravel(X), np.ravel(Y))]) zs = np.array([2.0 / (1.0/temp(x, t1, t2) + 1.0/weibull(y, w1, w2, w3)) for x,y in zip(np.ravel(X), np.ravel(Y))]) Z = zs.reshape(X.shape) | |
| _xlim | |
| Microbial processes. | |
| _ylim | |
| Nitrification. | |
| p_mix = get_par('METRX_F_PERTUBATION_MIX') | |
| Bioturbation (D_eff_dailyturbation_sl) response factors (constants are hard-coded in soilchemistry-metrx-physics-chemistry.cpp) | |
Response functions of MeTrX plotted for the doxygen documentation. Parameter values (mean, min, max) are read from resources/parameters-site.xml, figures are written to ../figures/.
|
protected |
Fallback: get parameter from species mnemonic='none'.
References find_species().
Referenced by get_par().


| figures.build_parent_map | ( | root = xmlparameters | ) |
Build a dict: child_element -> parent_element.
References build_parent_map().
Referenced by build_parent_map(), and get_par().


| figures.find_species | ( | root, | |
| mnemonic ) |
Return the first <species> element with the given mnemonic.
Referenced by _get_from_default(), and get_par().

| figures.get_par | ( | _name | , |
| _type | = 'mean' ) |
Helpers.
Return value ('mean'), 'min' or 'max' of a site parameter. | figures.get_par | ( | _name, | |
| _type = 'mean' ) |
Helpers.
Return value ('mean'), 'min' or 'max' of a site parameter. References get_par(), and weibull().

| figures.get_par | ( | name, | |
| species_mnemonic, | |||
| root = xmlparameters, | |||
| parent_map = parent_map ) |
name: parameter name (string), e.g. 'aejm' species_mnemonic: e.g. ':corns:' or ':poaceae:' root: root <speciesparameters> element parent_map: optional precomputed parent map (for efficiency)
References _get_from_default(), build_parent_map(), find_species(), and get_par().
Referenced by get_par(), get_par(), and get_par_range().


| figures.get_par_range | ( | _name | ) |
Return dictionary with mean, min and max of a site parameter.
References get_par().
Referenced by plot_response_row().


| figures.ph_bell | ( | _x, | |
| _half_width, | |||
| _exponent, | |||
| _ph_opt ) |
MeTrX_get_fact_ph_bell (arguments in order of site parameters _1, _2, _3).
| figures.ph_cutoff | ( | _fact | ) |
Processes with pH response below FACT_PH_MIN are not calculated (SoilChemistryMeTrX::FACT_PH_MIN).
References plot_response().

| figures.ph_logistic | ( | _x, | |
| _ph_50, | |||
| _width ) |
MeTrX_get_fact_ph_logistic: increasing with pH for _width > 0, decreasing for _width < 0.
| figures.plot_response | ( | _filename, | |
| _func, | |||
| _x, | |||
| _names, | |||
| _xlabel, | |||
| _ylabel, | |||
| _xlim = None, | |||
| _ylim = None, | |||
| _legend = False, | |||
| _adjust = None ) |
Plot response with sensitivity to each parameter (see plot_response_row) and save figure.
References plot_response_row().
Referenced by ph_cutoff().


| figures.plot_response_row | ( | _ax, | |
| _func, | |||
| _x, | |||
| _names, | |||
| _xlabel, | |||
| _ylabel, | |||
| _xlim = None, | |||
| _ylim = None, | |||
| _legend = False ) |
Plot _func(x, *parameters) on a row of axes. The first panel shows the response with all parameters at their mean value. Each further panel varies one parameter between min (blue), mean (black) and max (red) while the other parameters are kept at their mean value.
References get_par_range().
Referenced by plot_response().


| figures.plot_single | ( | _filename, | |
| _func, | |||
| _x, | |||
| _xlabel, | |||
| _ylabel, | |||
| _xlim = None, | |||
| _ylim = None ) |
Plot response without parameter variation and save figure.
|
protected |
Microbial processes.
Methane production and oxidation.
Decomposition and humification.
Denitrification.
|
protected |
Nitrification.
Anaerobic volume fraction and pore connectivity.
| figures.fig = plt.figure( figsize=(7, 4)) |
zs = np.array([temp(x, t1, t2) * weibull(y, w1, w2, w3) for x,y in zip(np.ravel(X), np.ravel(Y))]) zs = np.array([2.0 / (1.0/temp(x, t1, t2) + 1.0/weibull(y, w1, w2, w3)) for x,y in zip(np.ravel(X), np.ravel(Y))]) Z = zs.reshape(X.shape)
ax.plot_surface(X, Y, Z, cmap="winter", rstride=1, cstride=1) ax.set_title('Temperature-moisture factor') ax.set_xlabel('T [oC]') ax.set_ylabel('wfps [-]') ax.set_zlabel('response [-]') plt.savefig(script_dir+"/../figures/temp_moist.png")