本文整理汇总了C++中BlockModel::number方法的典型用法代码示例。如果您正苦于以下问题:C++ BlockModel::number方法的具体用法?C++ BlockModel::number怎么用?C++ BlockModel::number使用的例子?那么, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类BlockModel
的用法示例。
在下文中一共展示了BlockModel::number方法的15个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的C++代码示例。
示例1: Rootdens
Rootdens_G_P::Rootdens_G_P (const BlockModel& al)
: Rootdens (al),
DensRtTip (al.number ("DensRtTip")),
MinDens (al.number ("MinDens")),
a (-42.42e42),
L0 (-42.42e42)
{ }
示例2: PhotoGL
PhotoGL (const BlockModel& al)
: Photo (al),
Qeff (al.number ("Qeff")),
Fm (al.number ("Fm")),
TempEff (al.plf ("TempEff")),
DSEff (al.plf ("DSEff")),
DAPEff (al.plf ("DAPEff"))
{ }
示例3: Photo
PhotoFarquhar::PhotoFarquhar (const BlockModel& al)
: Photo (al),
Xn (al.number ("Xn")),
Gamma25 (al.number ("Gamma25")),
Ea_Gamma (al.number ("Ea_Gamma")),
rubiscoNdist (Librarian::build_item<RubiscoNdist> (al, "N-dist")),
Stomatacon (Librarian::build_item<StomataCon> (al, "Stomatacon"))
{ }
示例4: Chemistry
ChemistryMulti::ChemistryMulti (const BlockModel& al)
: Chemistry (al),
combine (Librarian::build_vector<Chemistry> (al, "combine")),
ignore (al.name_sequence ("ignore")),
max_sink_total (al.number ("max_sink_total")),
max_sink_solute (al.number ("max_sink_solute")),
max_sink_secondary (al.number ("max_sink_secondary")),
min_sink_total (al.number ("min_sink_total")),
chemicals (find_chemicals (combine))
{ }
示例5: ActionSow
ActionSow (const BlockModel& al)
: Action (al),
metalib (al.metalib ()),
crop (&al.model ("crop").clone ()),
// Use 'plant_distance' if set, otherwise use 'row_width'.
row_width (al.number ("plant_distance", al.number ("row_width"))),
// Use 'plant_distance' if set, otherwise use 'row_width'.
row_pos (al.number ("plant_position", al.number ("row_position"))),
seed (al.number ("seed", -42.42e42))
{ }
示例6: ProgramRootmatch
ProgramRootmatch (const BlockModel& al)
: Program (al),
units (al.units ()),
lex (al),
pos_dim (al.name ("pos_dim")),
dens_dim (al.name ("dens_dim")),
tag_x (al.name ("tag_x")),
tag_z_min (al.name ("tag_z_min")),
tag_z_max (al.name ("tag_z_max")),
tag_density (al.name ("tag_density")),
c_x_pos (-1),
c_z_min (-1),
c_z_max (-1),
c_density (-1),
debug (al.integer ("debug")),
show_data (al.flag ("show_data")),
show_match (al.flag ("show_match")),
x_offset (al.number ("x_offset")),
tabular (al.flag ("tabular")),
row_position (al.number ("row_position")),
min_dist (al.number ("min_dist")),
gp2d (al.number ("row_position"),
al.number ("row_distance"),
al.number ("DensRtTip"),
al.number ("SpRtLength")),
gp1d (al.number ("DensRtTip"),
al.number ("SpRtLength")),
SoilDepth (al.number ("SoilDepth", NAN)),
gnuplot (submodel<Gnuplot> (al, "gnuplot"))
{ }
示例7: Hydraulic
HydraulicM_vGp::HydraulicM_vGp (const BlockModel& al)
: Hydraulic (al),
alpha (al.number ("alpha")),
a (-alpha),
n (al.number ("n")),
m (1 - 1 / n),
l (al.number ("l")),
M_ (),
h_m (al.number ("h_m")),
f (al.number ("f")),
p_m_matrix (pow (1.0 / (-h_m * 1.0 + 1.0), f))
{ }
示例8: Reaction
ReactionDenit::ReactionDenit (const BlockModel& al)
: Reaction (al),
K (al.number ("K")),
K_fast (al.number ("K_fast", K)),
alpha (al.number ("alpha")),
alpha_fast (al.number ("alpha_fast", alpha)),
heat_factor (al.check ("heat_factor")
? al.plf ("heat_factor")
: PLF::empty ()),
water_factor (al.plf ("water_factor")),
water_factor_fast (al.check ("water_factor_fast" )
? al.plf ("water_factor_fast")
: water_factor),
redox_height (al.number ("redox_height", 1.0))
{ }
示例9: PetPM
// Create & Destroy.
PetPM (const BlockModel& al)
: Pet (al),
net_radiation (Librarian::build_stock<NetRadiation> (al.metalib (),
al.msg (),
"brunt", objid)),
rb (al.number ("rb"))
{ }
示例10: Rootdens
Rootdens_AP::Rootdens_AP (const BlockModel& al)
: Rootdens (al),
a_DS (al.plf ("a_DS")),
q (al.number ("q")),
a (-42.42e42),
L0 (-42.42e42)
{ }
示例11:
std::unique_ptr<Volume>
Volume::build_obsolete (const BlockModel& al)
{
Volume *const vol = Librarian::build_item<Volume> (al, "volume");
daisy_assert (vol);
if (al.check ("from"))
{
const double from = al.number ("from");
if (from < 0)
vol->limit_top (from);
}
if (al.check ("to"))
{
const double to = al.number ("to");
if (to < 0)
vol->limit_bottom (to);
}
return std::unique_ptr<Volume> (vol);
}
示例12: Program
ProgramGP2D (const BlockModel& al)
: Program (al),
metalib (al.metalib ()),
geo (submodel<GeometryRect> (al, "Geometry")),
row_width (al.number ("row_width")),
row_position (al.number ("row_position")),
soil_depth (al.number ("soil_depth")),
crop_depth (al.number ("crop_depth")),
crop_width (al.number ("crop_width")),
WRoot (al.number ("WRoot")),
DS (al.number ("DS"))
{ }
示例13: Drain
DrainLateral::DrainLateral (const BlockModel& al)
: Drain (al),
eq_depth (Librarian::build_item<Draineqd> (al, "eq_depth")),
L (al.number ("L")),
rad (al.number ("rad")),
x (al.number ("x", L / 2.0)),
pipe_position (al.number ("pipe_position")),
pipe_outlet (Librarian::build_item<Depth> (al, "pipe_outlet")),
K_to_pipes_ (al.number ("K_to_pipes", -1.0)),
pipe_level (pipe_position),
height (al.number ("height", pipe_position))
{ }
示例14: RubiscoNdist
rubiscoNdist_expr (const BlockModel& al)
: RubiscoNdist (al),
f_photo (al.number ("f_photo")),
expr (Librarian::build_item<Number> (al, "value")),
scope (__FUNCTION__)
{
scope.add_item (new ExchangeNumber (LAI_symbol, Attribute::None(),
"Leaf area index"));
scope.add_item (new ExchangeNumber (distance_from_top_symbol, "cm",
"Distance from top of canopy"));
scope.add_item (new ExchangeNumber (relative_LAI_symbol, Attribute::None(),
"Relative leaf area index"));
scope.add_item (new ExchangeNumber (relative_distance_from_top_symbol, Attribute::None(),
"Relative distance from top of canopy"));
scope.add_item (new ExchangeNumber (DS_symbol, Attribute::None(),
"Development stage"));
scope.done ();
expr->initialize (al.units (), scope, al.msg());
if (!expr->check_dim (al.units (), scope, Attribute::Fraction (), al.msg()))
al.error("Invalid expression of rubisco expr");
}
示例15: anisotropy
Horizon::Implementation::Implementation (const BlockModel& al)
: dry_bulk_density (al.number ("dry_bulk_density", -42.42e42)),
SOM_C_per_N (al.number_sequence ("SOM_C_per_N")),
C_per_N (al.number ("C_per_N", -42.42e42)),
SOM_fractions (al.check ("SOM_fractions")
? al.number_sequence ("SOM_fractions")
: std::vector<double> ()),
turnover_factor (al.number ("turnover_factor")),
anisotropy (al.number ("anisotropy")),
attributes (get_attributes (al.submodel_sequence ("attributes"))),
dimensions (get_dimensions (al.submodel_sequence ("attributes"))),
nitrification (Librarian::build_item<Nitrification> (al, "Nitrification")),
secondary (Librarian::build_item<Secondary> (al, "secondary_domain")),
r_pore_min (al.number ("r_pore_min")),
primary_sorption_fraction (NAN),
hor_heat (al.submodel ("HorHeat")),
CEC (al.number ("CEC", -42.42e42))
{ }