ALMaSS  1.2 (after EcoStack, March 2024)
The Animal, Landscape and Man Simulation System
VegElement Class Reference

#include <Elements.h>

Inheritance diagram for VegElement:
LE BeetleBank Field FieldBoundary FlowerStrip ForestElement HedgeBank Hedges MownGrassStrip NaturalGrass Orchard OrchardBand PastureElement PermanentSetaside RoadsideVerge UnsprayedFieldMargin WaterBufferZone

Public Member Functions

 VegElement (TTypesOfLandscapeElement tole, Landscape *L)
 
virtual ~VegElement (void)
 
virtual void DoDevelopment (void)
 
virtual double GetDigestibility (void)
 
virtual double GetLAGreen (void)
 
virtual double GetLATotal (void)
 
virtual bool GetIsVeg (void)
 
virtual double GetVegCover (void)
 
virtual double GetVegHeight (void)
 
virtual double GetVegBiomass (void)
 
virtual double GetDeadBiomass (void)
 
virtual double GetGreenBiomass (void)
 
virtual double GetInterestedGreenBiomass (void)
 
virtual double GetGreenBiomassProp (void)
 
virtual double GetWeedBiomass (void)
 
virtual int GetVegDensity (void)
 
virtual bool GetSkScrapes (void)
 
void Tick (void) override
 
virtual void SetVegGrowthScalerRand ()
 
virtual double GetInsectPop (void)
 
virtual void SetInsectPop (double insects)
 
virtual TTypesOfVegetation GetVegType (void)
 
virtual TTypesOfCrops GetCropType ()
 
virtual void SetCropType (TTypesOfCrops a_type)
 
void SetInsectBiomassParametersIndex (TTypesOfCrops a_type)
 
void SetInterestedBiomassFractionForCrop (TTypesOfCrops a_crop_type)
 
virtual void Insecticide (double a_fraction)
 
virtual bool Is_Att_Veg (void)
 
virtual void Set_Att_Veg (bool p)
 
virtual bool Is_Att_VegPatchy (void)
 
virtual void Set_Att_VegPatchy (bool p)
 
virtual bool Is_Att_VegCereal ()
 
virtual void Set_Att_VegCereal (bool p)
 
virtual bool Is_Att_VegMatureCereal ()
 
virtual void Set_Att_VegMatureCereal (bool p)
 
virtual bool Is_Att_VegMaize ()
 
virtual void Set_Att_VegMaize (bool p)
 
virtual bool Is_Att_VegGrass ()
 
virtual void Set_Att_VegGrass (bool p)
 
virtual bool Is_Att_VegGooseGrass ()
 
virtual void Set_Att_VegGooseGrass (bool p)
 
bool IsMatureCereal ()
 
bool IsMaize ()
 
bool IsCereal ()
 
bool IsGooseGrass ()
 
void SetVegPatchy (bool p)
 
virtual void InsectMortality (double a_fraction)
 
virtual void ReduceWeedBiomass (double a_fraction)
 
virtual void ToggleCattleGrazing (void)
 
virtual void TogglePigGrazing (void)
 
virtual void GrazeVegetation (double a_grams, bool a_force)
 
virtual void GrazeVegetationHeight (double a_reduc)
 
virtual void GrazeVegetationTotal (double a_grams)
 The function that reduces the vegetation due to grazing. More...
 
virtual void SetVegType (TTypesOfVegetation a_vege_type)
 
virtual void SetVegType (TTypesOfVegetation a_vege_type, TTypesOfVegetation a_weed_type)
 
virtual void SetCropData (double, double, double, TTypesOfVegetation, double, int)
 
virtual void SetCropDataAll (double, double, double, double, TTypesOfVegetation, double, double, int, double, bool, double, double, double)
 
virtual void SetVegHeight (double a_veg_height)
 
virtual void SetDigestibility (double a_digestability)
 
virtual void SetGrazingLevel (int a_grazing)
 
virtual void SetVegParameters (double a_veg_height, double a_LAtotal, double a_LAgreen, double a_WeedBiomass)
 
virtual void SetGrowthPhase (int a_phase)
 
virtual void StoreLAItotal ()
 
virtual void ForceGrowthInitialize (bool a_force_decreasing=false)
 
virtual void ForceGrowthInitialiseForFirstYearCrop (void)
 
virtual void ForceGrowthTest (void)
 
virtual void ForceGrowthDevelopment (void)
 
virtual void ZeroVeg (void)
 
virtual void ReduceVeg (double a_reduc)
 
virtual void ReduceVeg_Extended (double a_reduc)
 
virtual void ResetDigestibility ()
 sets growth record to zero More...
 
virtual int GetVegPhase ()
 
virtual void SetSpeciesFunction (TTypesOfPopulation a_species)
 Sets the correct species simulation behaviour for the current species. More...
 
void SetInterestedBiomassFraction (double a_interested_biomass_fraction)
 Function to set the instrested biomass fraction. More...
 
- Public Member Functions inherited from LE
 LE (Landscape *L)
 
virtual ~LE (void)
 
virtual int GetAphidDensity ()
 
int GetVegStore (void)
 Variable used to record the current grazing pressure by e.g. voles *‍/ double m_volegrazing; /**. More...
 
void SetVegStore (int a_veg)
 
void ZeroVegAge ()
 
int GetVegAge ()
 
virtual double GetVegGrowthStage (void)
 
virtual APoint GetCentroid ()
 
virtual int GetCentroidX ()
 
virtual int GetCentroidY ()
 
virtual void SetCentroid (int x, int y)
 
virtual double GetDayDegrees (void)
 
virtual void ToggleIrrigation (void)
 
virtual void SetVegBiomass (int)
 
virtual void GrazeVeg_Extended (double)
 
virtual double GetTrafficLoad (void)
 
virtual TTypesOfVegetation GetPreviousTov (int)
 
bool GetPoison (void)
 
void SetPoison (bool a_poison)
 
bool Is_Att_High (void)
 
void Set_Att_High (bool a_high)
 
bool Is_Att_Water (void)
 
void Set_Att_Water (bool a_water)
 
bool Is_Att_Forest (void)
 
void Set_Att_Forest (bool a_forest)
 
bool Is_Att_Woody (void)
 
void Set_Att_Woody (bool a_woody)
 
bool Is_Att_UrbanNoVeg (void)
 
void Set_Att_UrbanNoVeg (bool a_unv)
 
bool Is_Att_UserDefinedBool (void)
 
void Set_Att_UserDefinedBool (bool a_value)
 
int Is_Att_UserDefinedInt (void)
 
void Set_Att_UserDefinedInt (int a_value)
 
void SetVegPatchy (bool p)
 
int GetCattleGrazing (void)
 
bool GetPigGrazing (void)
 
bool HasTramlines (void)
 
bool IsRecentlyMown (void)
 
int IsRecentlySprayed (void)
 
int GetPoly (void)
 Returns the polyref number for this polygon. More...
 
int GetMapIndex (void)
 
void SetMapIndex (int a_map_index)
 
int GetOwnerFile (void)
 
int GetOwnerIndex (void)
 
int GetLastTreatment (int *a_index)
 
int GetLastTreatment ()
 Returns the last treatment recorded for the polygon. More...
 
void ClearManagementActionSum ()
 clears the management action counters More...
 
void AddManagementActionDone (FarmManagementCategory a_action)
 Record management action throught a crop management action. More...
 
vector< int > GetManagementTotals ()
 
FarmGetOwner (void)
 
double GetArea (void)
 
double GetGooseGrazingForage (GooseSpecies a_goose)
 
double GetBirdSeed (void)
 
void SetBirdSeed (double a_forage)
 
double GetBirdMaize (void)
 
void SetBirdMaize (double a_forage)
 
int GetCountryDesignation (void)
 
void SetCountryDesignation (int a_designation)
 
long GetOldDays (void)
 
void SetOwner (Farm *a_owner, int a_owner_num, int a_owner_index)
 
void SetPoly (int a_poly)
 
void SetMapValid (bool a_valid)
 
bool GetMapValid (void)
 
void SetArea (double a_area)
 
int GetSoilType ()
 
int GetSoilTypeR ()
 
void SetSoilType (int a_st)
 
void SetLastSownVeg (TTypesOfVegetation a_tov)
 Records the last vegetation type to be sown. More...
 
TTypesOfVegetation GetLastSownVeg ()
 Returns the last vegetation type to be sown. More...
 
void SetLastTreatment (int a_treatment)
 
void SetSprayedToday (bool a_didit)
 
bool GetSprayedToday ()
 
void SetCopyTreatment (int a_treatment)
 
void SetOldDays (long a_days)
 
void SetRotIndex (int a_index)
 
int GetRotIndex (void)
 
void SetTramlinesDecay (int a_decaytime_days)
 
void SetHerbicideDelay (int a_decaytime_days)
 
void SetMownDecay (int a_decaytime_days)
 
void AddArea (double a_area_diff)
 
LEGetBorder (void)
 
int GetUnsprayedMarginPolyRef (void)
 
void SetBorder (LE *a_border)
 
void SetUnsprayedMarginPolyRef (int a_unsprayedmargin)
 
void SetPesticideCell (int a_cell)
 
int GetPesticideCell ()
 
void SetValidXY (int a_valid_x, int a_valid_y)
 
int GetValidX (void)
 
int GetValidY (void)
 
int GetMaxX (void)
 
int GetMaxY (void)
 
int GetMinX (void)
 
int GetMinY (void)
 
void SetMaxX (int x)
 
void SetMaxY (int y)
 
void SetMinX (int x)
 
void SetMinY (int y)
 
int GetMDates (int a, int b)
 
void SetMDates (int a, int b, int c)
 
int GetMConstants (int a)
 
void SetMConstants (int a, int c)
 
double GetVegDDegs ()
 Get the total of day degrees for the crop/veg on this element. More...
 
int GetOpenness (void)
 For goose model functionality, openness score for the polygon. More...
 
double GetElevation (void)
 Get elevation data. More...
 
double GetSlope (void)
 
double GetAspect (void)
 
void SetGooseNos (int a_number, int a_day)
 
void SetGooseSpNos (int a_number, int a_day, GooseSpecies a_goose)
 
void SetGooseNosTimed (int a_number, int a_day)
 
void SetGooseSpNosTimed (int a_number, int a_day, GooseSpecies a_goose)
 
void SetGooseRoostDist (int a_dist, GooseSpecies a_goose)
 
int GetGooseNosToday ()
 For goose model functionality, returns the number of geese today. More...
 
int GetGooseNosTodayTimed ()
 For goose model functionality, returns the number of geese today at a predefined time. More...
 
int GetGooseNos ()
 For goose model functionality, returns the number of geese yesterday. More...
 
int GetQuarryNos ()
 For goose model functionality, returns the number of geese yesterday which can be hunted as legal quarry. More...
 
int GetGooseSpNosToday (GooseSpecies a_goose)
 For goose model functionality, returns the number of geese per species yesterday. More...
 
int GetGooseSpNosTodayTimed (GooseSpecies a_goose)
 For goose model functionality, returns the number of geese per species yesterday at a predefined time. More...
 
int GetGooseRoostDist (GooseSpecies a_goose)
 For goose model functionality, returns the distance to closest roost. More...
 
void SetOpenness (int a_openness)
 Records the openness statistic for this polygon. More...
 
void SetElevation (double a_elevation)
 Records the elevation of the polygon. More...
 
void SetSlope (double a_slope)
 
void SetAspect (double a_aspect)
 
void DoCopy (const LE *a_Le)
 a copy function to be used because a copy constuctor won't work More...
 
virtual void SetMaleNewtPresent (bool)
 Sets a male newt as present/absent in descendent classes - here only to prevent need for dynamic casts. More...
 
virtual bool IsMaleNewtPresent ()
 Sets a male newt as present/absent in descendent classes - here only to prevent need for dynamic casts. More...
 
void SetStubble (bool a_flag)
 Sets the in stubble flag. More...
 
bool GetStubble ()
 Return the in stubble flag. More...
 
PlantProtectionProducts GetSprayPPPType (void)
 Return the sprayed pesticide type in the field. More...
 
double GetSprayPPPRate (void)
 Return the sprayed pesticide application rate. More...
 
void SetSprayPPPType (PlantProtectionProducts a_type)
 Set the sprayed pesticide type in the field. More...
 
void SetSprayPPPRate (double a_rate)
 Set the sprayed pesticide application rate. More...
 
void SetPollenNectarCurveRef (int a_PollenNectarCurve)
 Sets the pollen/nectar curve number. More...
 
void SetPollenNectarType (TTypesOfVegetation a_new_veg)
 sets the pollen and nectar information based on tov More...
 
virtual PollenNectarData GetPollen ()
 Gets the pollen quantity & quality for this landscape element. More...
 
virtual PollenNectarData GetNectar ()
 Gets the nectar quantity & quality for this landscape element. More...
 
virtual double GetPollenQuantity ()
 Gets the pollen quantity for this landscape element. More...
 
virtual double GetPollenQuality ()
 Gets the pollen quality for this landscape element. More...
 
virtual double GetNectarQuantity ()
 Gets the nectar quantity for this landscape element. More...
 
virtual double GetSugar ()
 Gets the nectar quality (sugar) for this landscape element. More...
 
virtual double GetTotalPollen ()
 Returns the total pollen quantity for this landscape element. More...
 
virtual double GetTotalNectar ()
 Returns the total nectar quantity for this landscape element. More...
 
virtual void ChangeTotalPollen (double a_amount)
 Removes a_amount from total LE pollen. More...
 
virtual void ChangeTotalNectar (double a_amount)
 Removes a_amount from total LE nectar. More...
 
void SetPollenNectarCurves (PollenNectarDevelopmentCurveSet *a_set)
 Set method for pollen and nectar curves. More...
 
virtual void CalculateFlowerResourceForCrop (TTypesOfVegetation a_new_veg)
 The function to calculate flower resource for the crop in a year. More...
 
virtual void CalculateFlowerResourceForCropSow (TTypesOfVegetation a_new_veg)
 
virtual double supplyNecDD ()
 
virtual double supplySugDD ()
 
virtual double supplyPolDD ()
 
virtual bool GetPollenNectarFlag ()
 Returns the flag showing whether there is potential pollen/nectar here or not. More...
 
int GetPollenNectarCurveRef (void)
 Returns the pollen nectart curve number. More...
 

Static Public Member Functions

static void SetBiomassScalers (TTypesOfVegetation a_tov)
 

Protected Member Functions

void ReadBugPercentageFile (void)
 
virtual void RecalculateBugsNStuff (void)
 This method is responsible for. More...
 
void CalcGooseForageResources ()
 Calculates spilled grain and grazing forage resources for geese. More...
 
void RandomVegStartValues (double *a_LAtotal, double *a_LAgreen, double *a_veg_height, double *a_weed_biomass)
 
void ForceGrowthSpringTest (void)
 
virtual void PollenNectarPhenologyCalculation ()
 This methods calculates the daily availability of pollen and nectar per square meter and in total. More...
 
void CalculateDigestibility ()
 Sets vegetation digestability for hare and vole. More...
 
void CalculateAphidDrivers ()
 Determines the amount of new growth. More...
 
void CalculateInsectBiomass ()
 An insect biomass calculation for those species that need it. More...
 
virtual void PollenNectarReset ()
 Resets the daily availability of pollen and nectar per square meter and in total to zero. More...
 
void ResetGeese (void)
 Reset geese numbers to zero in case this was not done by the population manager (the normal situation). More...
 
void DoNothing (void)
 The default for SpeciesSpecificCalculations. More...
 

Protected Attributes

int m_insect_biomass_parameters_index { 0 }
 
double m_interested_biomass_fraction
 Fraction of the the interested biomass. More...
 
TTypesOfVegetation m_vege_type
 
int m_curve_num
 
int m_weed_curve_num
 
int m_veg_phase
 
double m_growth_scaler
 
int m_nutrient_status
 
double m_LAtotal
 
double m_oldLAtotal
 
double m_LAgreen
 
double m_insect_pop
 
double m_veg_biomass
 
double m_total_biomass
 
double m_total_biomass_old
 
double m_green_biomass
 
double m_interested_green_biomass
 
double m_dead_biomass
 
double m_weed_biomass
 
double m_veg_height
 
int m_veg_density
 
bool m_att_veg
 
bool m_att_veg_patchy
 
bool m_att_veg_cereal
 
bool m_att_veg_maturecereal
 
bool m_att_veg_maize
 
bool m_att_veg_grass
 
bool m_att_veg_goosegrass
 
bool m_att_veg_forest
 
double m_veg_cover
 
double m_newgrowth
 
double m_new_weed_growth
 
bool m_forced_phase_shift
 
double m_digestability
 
double m_oldnewgrowth [32]
 
double m_oldnewgrowth2 [14]
 
int m_newoldgrowthindex
 
int m_newoldgrowthindex2
 
double m_newgrowthsum
 
double m_newgrowthruningaveragesum
 
double m_newgrowthruningaverage
 
double m_greenbiomass_per
 
double m_force_Weed
 
double m_force_LAgreen
 
double m_force_LAtotal
 
double m_force_veg_height
 
bool m_force_growth
 
bool m_start_dd_flower
 The flag to start accumulating day degrees for flower resource. More...
 
ifstream m_ifile
 
int m_crop_index
 
double m_acc_DD_flower_resource
 Contains the day degrees since the sowing, this is only used for the crops. More...
 
double m_num_flowring_peroid
 Contains the number of days of the flowring period, this is only used for the crops. More...
 
void(VegElement::* SpeciesSpecificCalculations )(void)
 A useful function pointer that we can use to specify species specific calculations. The default does nothing. More...
 
- Protected Attributes inherited from LE
Landscapem_Landscape
 
vector< int > m_ManagementActionCounts
 
int m_ptrace [256]
 
int m_pdates [256]
 
int m_pindex
 
long m_running
 
LEm_border
 
int m_unsprayedmarginpolyref
 
int m_valid_x
 
int m_valid_y
 
int m_centroidx
 
int m_centroidy
 
int m_vege_danger_store
 
int m_PesticideGridCell
 
bool m_is_in_map
 
int m_subtype
 
int m_maxx
 
int m_minx
 
int m_maxy
 
int m_miny
 
long m_olddays
 
long m_management_loop_detect_date
 
long m_management_loop_detect_count
 
Farmm_owner {nullptr}
 
int m_countrydesignation
 
int m_owner_file
 
int m_owner_index
 
int m_rot_index
 
bool m_sprayedtoday
 flag to indicate an overspray situation More...
 
int m_poly
 The polyref number for this polygon. More...
 
int m_map_index
 
int m_almass_le_type
 This holds the ALMaSS element type reference number. More...
 
int m_farmfunc_tried_to_do
 
int m_tramlinesdecay
 
int m_mowndecay
 
int m_herbicidedelay
 
TTypesOfLandscapeElement m_type
 
TTypesOfLandscapeElement m_owner_tole
 
double m_area
 The element area in m2. More...
 
int m_gooseNos [366]
 The number of geese each day. More...
 
int m_gooseSpNos [366][gs_foobar]
 The number of geese of each species each day. More...
 
int m_gooseNosTimed [366]
 The number of geese at a predefined time per day. More...
 
int m_gooseSpNosTimed [366][gs_foobar]
 The number of geese of each species at a predefined time per day. More...
 
bool m_instubble
 A flag describing the state of the field from a visual perspective - will be in stubble following a cereal crop until either soil cultivation or March 1st. More...
 
double m_birdseedforage
 The grain forage present in seeds/m2. More...
 
double m_birdmaizeforage
 The maize forage present in seeds/m2. More...
 
double m_goosegrazingforage [gs_foobar]
 The grazing forage present in KJ/min. The last value indicates cereal 1 or not -1. More...
 
TTypesOfVegetation m_lastsownvegtype
 Records the last vegegetation type that was sown on the element. More...
 
int m_openness
 The openness metric for a field (if any) More...
 
double m_elevation
 Elevation data. More...
 
double m_slope
 
double m_aspect
 
double m_dist_to_closest_roost [gs_foobar]
 An array holding the distance to the nearest goose roost. More...
 
int m_vegage
 
int m_soiltype
 
int m_days_since_insecticide_spray
 
bool m_att_high
 
bool m_att_water
 
bool m_att_forest
 
bool m_att_woody
 
bool m_att_urbannoveg
 
bool m_att_userdefinedbool
 a userdefined attribute which can be set by a species model without changing other standard values More...
 
int m_att_userdefinedint
 a userdefined attribute which can be set by a species model without changing other standard values More...
 
bool m_poison
 
int m_cattle_grazing
 
int m_default_grazing_level
 
bool m_pig_grazing
 
double m_vegddegs
 
double m_yddegs
 
double m_weedddegs
 
double m_ddegs
 
vector< int > m_lasttreat
 
unsigned int m_lastindex
 
int MDates [2][25]
 
int MConsts [10]
 
LE_Signal m_signal_mask
 
double m_OsmiaNestProb
 to record the chance of osmia nesting More...
 
int m_maxOsmiaNests
 to record the number of possible osmia nests More...
 
int m_currentOsmiaNests
 to record the number of actual osmia nests More...
 
PollenNectarData m_polleninfo
 
PollenNectarData m_nectarinfo
 
double m_totalPollen
 
double m_totalNectar
 
int m_pollen_nectar_curve_index
 Variable to record the pollen and nectar curve number. More...
 
int m_flowering_day_counter
 The day counter to enter the flowering period. More...
 
vector< int > m_flowering_phases
 The array to store the day numbers of for turning point of flower resource. More...
 
vector< double > m_nectar_amount
 The array to store the nectar amount for each period. More...
 
vector< double > m_pollen_amount
 The array to store the pollen amount for each period. More...
 
vector< double > m_sugar_amount
 The array to store the sugar quality for each period. More...
 
PollenNectarDevelopmentCurveSetm_OurPollenNectarCurveSet {NULL}
 pointer to the correct pollen curve set More...
 
bool m_PollenNectarFlag
 Records whether there is any pollen possibility here or not. More...
 
PlantProtectionProducts m_spray_ppp_type
 This is to store the sprayed pesticide type. More...
 
double m_spray_ppp_rate
 This is to store the sprayed pesticide rate. More...
 

Static Protected Attributes

static double m_insect_biomass_parameters_a [9] = {EL_BUG_PERCENT_A, EL_BUG_PERCENT_SB_A, EL_BUG_PERCENT_WW_A, EL_BUG_PERCENT_WRy_A, EL_BUG_PERCENT_WR_A, EL_BUG_PERCENT_G_A, EL_BUG_PERCENT_Edges_A,EL_BUG_PERCENT_SA_A,0}
 
static double m_insect_biomass_parameters_b [9] = {EL_BUG_PERCENT_B, EL_BUG_PERCENT_SB_B, EL_BUG_PERCENT_WW_B, EL_BUG_PERCENT_WRy_B, EL_BUG_PERCENT_WR_B, EL_BUG_PERCENT_G_B, EL_BUG_PERCENT_Edges_B,EL_BUG_PERCENT_SA_B,0}
 
static double m_insect_biomass_parameters_c [9] = {EL_BUG_PERCENT_C, EL_BUG_PERCENT_SB_C, EL_BUG_PERCENT_WW_C, EL_BUG_PERCENT_WRy_C, EL_BUG_PERCENT_WR_C, EL_BUG_PERCENT_G_C, EL_BUG_PERCENT_Edges_C,EL_BUG_PERCENT_SA_C,0}
 
static double m_SeasonalInsectScaler [12] = { 0.1, 0.1, 0.15, 0.25, 0.75, 1.0, 1.0, 1.0, 0.9, 0.75, 0.25, 0.1 }
 
static double m_biomass_scale [tov_Undefined] = {}
 
- Static Protected Attributes inherited from LE
static double m_monthly_traffic []
 Used for birds that feed on grain on cereal fields 3% spill is expected. More...
 
static double m_largeroad_load []
 
static double m_smallroad_load []
 

Additional Inherited Members

- Public Attributes inherited from LE
int m_tried_to_do
 
int m_squares_in_map
 
TTypesOfCrops m_CropType
 
bool m_skylarkscrapes
 For management testing of skylark scrapes. More...
 

Constructor & Destructor Documentation

◆ VegElement()

VegElement::VegElement ( TTypesOfLandscapeElement  tole,
Landscape L 
)
1282  : LE(L) {
1283  m_interested_biomass_fraction = 1.1; //by default we are interested in all biomass
1284  m_type = tole;
1285  m_owner_tole = m_type;
1286  // Set default Attribute Flags
1287  Set_Att_Veg(true);
1288  Set_Att_VegPatchy(false);
1289  Set_Att_VegCereal(false);
1290  Set_Att_VegMatureCereal(false);
1291  Set_Att_VegGooseGrass(false);
1292  Set_Att_VegGrass(false);
1293  Set_Att_VegMaize(false);
1294  m_growth_scaler = 1.0; // default
1295  m_veg_biomass = 0.0;
1296  m_weed_biomass = 0.0;
1297  m_veg_height = 0.0;
1298  m_veg_cover = 0.0;
1299  m_insect_pop = 1.0;
1301  m_insect_biomass_parameters_index = 8; // No insects is the default so future constructors need to set this explicitly
1303  m_weed_curve_num = 99; // 99 used as default weed curve
1304  m_yddegs = 0.0;
1305  m_vegddegs = -1.0;
1306  m_ddegs = 0.0;
1307  m_LAgreen = 0.0;
1308  m_LAtotal = 0.0;
1309  m_digestability = 1.0;
1310  for (int i = 0; i < 32; i++) m_oldnewgrowth[i] = 0.5;
1311  for (int i = 0; i < 14; i++) m_oldnewgrowth2[i] = 0.0;
1312  for (int i = 0; i < 12; i++) m_SeasonalInsectScaler[i] = cfg_SeasonalInsectScaler.value().at(i);
1313  m_newoldgrowthindex = 0;
1314  m_newgrowthsum = 8.0;
1315  m_newgrowth = 0.0;
1316  m_new_weed_growth = 0.0;
1317  m_forced_phase_shift = false;
1318  m_force_growth = false;
1320  m_total_biomass = 0.0;
1321  m_total_biomass_old = 0.0;
1322  // Set default for species specific calculations
1324  //we need to let the pollen nectar model run in the hidden year if we need to use it
1327  }
1328  m_start_dd_flower = false;
1329 
1331  //ReadBugPercentageFile();
1332  return;
1333  }
1334  // Default 0.1 - only those that differ need to be listed below - todo this and move this out of the constructor
1335  for (int i = 0; i < tov_Undefined; i++) { g_weed_percent[i] = 0.1; }
1336  g_weed_percent[tov_Carrots] = 0.1;
1337  g_weed_percent[ tov_BroadBeans ] = 0.1;
1338  g_weed_percent[ tov_Maize ] = 0.05;
1375  g_weed_percent[ tov_OFieldPeas ] = 0.1;
1378  g_weed_percent[tov_OOats] = 0.1;
1379  g_weed_percent[tov_Oats] = 0.1;
1380  g_weed_percent[tov_Heath] = 0.1;
1382  g_weed_percent[ tov_FieldPeas ] = 0.1;
1399  g_weed_percent[tov_None] = 0.1;
1424 
1432  g_weed_percent[tov_PLMaize] = 0.1;
1435  g_weed_percent[tov_PLBeet] = 0.1;
1442  g_weed_percent[tov_PLBeans] = 0.1;
1443 
1446  g_weed_percent[tov_NLMaize] = 0.1;
1448  g_weed_percent[tov_NLBeet] = 0.1;
1470 
1471  g_weed_percent[tov_UKBeans] = 0.1;
1472  g_weed_percent[tov_UKBeet] = 0.1;
1473  g_weed_percent[tov_UKMaize] = 0.1;
1481 
1482  g_weed_percent[tov_BEBeet] = 0.1;
1489  g_weed_percent[tov_BEMaize] = 0.1;
1499 
1513  g_weed_percent[tov_PTBeans] = 0.1;
1517  g_weed_percent[tov_PTMaize] = 0.1;
1519  g_weed_percent[tov_PTOats] = 0.1;
1529 
1536  g_weed_percent[tov_DEMaize] = 0.1;
1538  g_weed_percent[tov_DEOats] = 0.1;
1546  g_weed_percent[tov_DEOOats] = 0.1;
1577  g_weed_percent[tov_DEPeas] = 0.1;
1578  g_weed_percent[tov_DEOPeas] = 0.1;
1581 
1631  g_weed_percent[tov_DKMaize] = 0.05;
1635  g_weed_percent[tov_DKOMaize] = 0.05;
1707 
1756 
1760 
1773  g_weed_percent[tov_FRMaize] = 0.05;
1782  g_weed_percent[tov_FRSorghum] = 0.05;
1783 
1787 
1789  //reset if there is flower resource
1790  //if (m_OurPollenNectarCurveSet) {
1791  // PollenNectarReset();
1792  //}
1793 
1794 
1795 }

References cfg_pollen_nectar_on, cfg_SeasonalInsectScaler, DoNothing(), g_crops, g_weed_percent, janfirst, l_el_read_bug_percentage_file(), m_curve_num, LE::m_ddegs, m_digestability, m_force_growth, m_forced_phase_shift, m_growth_scaler, m_insect_biomass_parameters_index, m_insect_pop, m_interested_biomass_fraction, m_LAgreen, m_LAtotal, m_new_weed_growth, m_newgrowth, m_newgrowthsum, m_newoldgrowthindex, m_newoldgrowthindex2, m_oldnewgrowth, m_oldnewgrowth2, LE::m_owner_tole, m_SeasonalInsectScaler, m_start_dd_flower, m_total_biomass, m_total_biomass_old, LE::m_type, m_veg_biomass, m_veg_cover, m_veg_height, LE::m_vegddegs, m_vege_type, m_weed_biomass, m_weed_curve_num, LE::m_yddegs, PollenNectarPhenologyCalculation(), Set_Att_Veg(), Set_Att_VegCereal(), Set_Att_VegGooseGrass(), Set_Att_VegGrass(), Set_Att_VegMaize(), Set_Att_VegMatureCereal(), Set_Att_VegPatchy(), SetGrowthPhase(), SpeciesSpecificCalculations, tov_AgroChemIndustryCereal, tov_BEBeet, tov_BEBeetSpring, tov_BECatchPeaCrop, tov_BEGrassGrazed1, tov_BEGrassGrazed1Spring, tov_BEGrassGrazed2, tov_BEGrassGrazedLast, tov_BEMaize, tov_BEMaizeCC, tov_BEMaizeSpring, tov_BEOrchardCrop, tov_BEPotatoes, tov_BEPotatoesSpring, tov_BEWinterBarley, tov_BEWinterBarleyCC, tov_BEWinterWheat, tov_BEWinterWheatCC, tov_BroadBeans, tov_Carrots, tov_CloverGrassGrazed1, tov_CloverGrassGrazed2, tov_DEAsparagusEstablishedPlantation, tov_DEBushFruitPerm, tov_DECabbage, tov_DECarrots, tov_DEGrasslandSilageAnnual, tov_DEGreenFallow_1year, tov_DEHerbsPerennial_1year, tov_DEHerbsPerennial_after1year, tov_DELegumes, tov_DEMaize, tov_DEMaizeSilage, tov_DEOAsparagusEstablishedPlantation, tov_DEOats, tov_DEOBushFruitPerm, tov_DEOCabbages, tov_DEOCarrots, tov_DEOGrasslandSilageAnnual, tov_DEOGreenFallow_1year, tov_DEOHerbsPerennial_1year, tov_DEOHerbsPerennial_after1year, tov_DEOLegume, tov_DEOMaize, tov_DEOMaizeSilage, tov_DEOOats, tov_DEOOrchard, tov_DEOPeas, tov_DEOPermanentGrassGrazed, tov_DEOPermanentGrassLowYield, tov_DEOPotatoes, tov_DEOrchard, tov_DEOSpringRye, tov_DEOSugarBeet, tov_DEOTriticale, tov_DEOWinterBarley, tov_DEOWinterRape, tov_DEOWinterRye, tov_DEOWinterWheat, tov_DEPeas, tov_DEPermanentGrassGrazed, tov_DEPermanentGrassLowYield, tov_DEPotatoes, tov_DEPotatoesIndustry, tov_DESpringBarley, tov_DESpringRye, tov_DESugarBeet, tov_DETriticale, tov_DEWinterBarley, tov_DEWinterRape, tov_DEWinterRye, tov_DEWinterWheat, tov_DEWinterWheatLate, tov_DKBushFruit_Perm1, tov_DKBushFruit_Perm2, tov_DKCabbages, tov_DKCarrots, tov_DKCatchCrop, tov_DKCerealLegume, tov_DKCerealLegume_Whole, tov_DKChristmasTrees_Perm, tov_DKCloverGrassGrazed1, tov_DKCloverGrassGrazed2, tov_DKCloverGrassGrazed3, tov_DKEnergyCrop_Perm, tov_DKFarmForest_Perm, tov_DKFarmYoungForest_Perm, tov_DKFodderBeets, tov_DKGrassGrazed_Perm, tov_DKGrassLowYield_Perm, tov_DKGrassTussocky_Perm, tov_DKGrazingPigs, tov_DKGrazingPigs_Perm, tov_DKLegume_Beans, tov_DKLegume_Peas, tov_DKLegume_Whole, tov_DKMaize, tov_DKMaizeSilage, tov_DKMixedVeg, tov_DKOBushFruit_Perm1, tov_DKOBushFruit_Perm2, tov_DKOCabbages, tov_DKOCarrots, tov_DKOCatchCrop, tov_DKOCerealLegume, tov_DKOCerealLegume_Whole, tov_DKOChristmasTrees_Perm, tov_DKOCloverGrassGrazed1, tov_DKOCloverGrassGrazed2, tov_DKOCloverGrassGrazed3, tov_DKOEnergyCrop_Perm, tov_DKOFarmForest_Perm, tov_DKOFarmYoungForest_Perm, tov_DKOFodderBeets, tov_DKOGrassGrazed_Perm, tov_DKOGrassLowYield_Perm, tov_DKOGrazingPigs, tov_DKOGrazingPigs_Perm, tov_DKOLegume_Beans, tov_DKOLegume_Beans_CC, tov_DKOLegume_Peas, tov_DKOLegume_Peas_CC, tov_DKOLegume_Whole, tov_DKOLegume_Whole_CC, tov_DKOLegumeCloverGrass_Whole, tov_DKOLentils, tov_DKOLupines, tov_DKOMaize, tov_DKOMaizeSilage, tov_DKOMixedVeg, tov_DKOOrchApple, tov_DKOOrchardCrop_Perm, tov_DKOOrchCherry, tov_DKOOrchOther, tov_DKOOrchPear, tov_DKOPotato, tov_DKOPotatoIndustry, tov_DKOPotatoSeed, tov_DKOptimalFlowerMix1, tov_DKOptimalFlowerMix2, tov_DKOptimalFlowerMix3, tov_DKOrchApple, tov_DKOrchardCrop_Perm, tov_DKOrchCherry, tov_DKOrchOther, tov_DKOrchPear, tov_DKOSeedGrassRye_Spring, tov_DKOSetAside, tov_DKOSetAside_AnnualFlower, tov_DKOSetAside_PerennialFlower, tov_DKOSetAside_SummerMow, tov_DKOSpringBarley, tov_DKOSpringBarley_CC, tov_DKOSpringBarleyCloverGrass, tov_DKOSpringBarleySilage, tov_DKOSpringFodderGrass, tov_DKOSpringOats, tov_DKOSpringOats_CC, tov_DKOSpringWheat, tov_DKOSugarBeets, tov_DKOVegSeeds, tov_DKOWinterBarley, tov_DKOWinterCloverGrassGrazedSown, tov_DKOWinterFodderGrass, tov_DKOWinterRape, tov_DKOWinterRye, tov_DKOWinterRye_CC, tov_DKOWinterWheat, tov_DKOWinterWheat_CC, tov_DKPlantNursery_Perm, tov_DKPotato, tov_DKPotatoIndustry, tov_DKPotatoSeed, tov_DKSeedGrassFescue_Spring, tov_DKSeedGrassRye_Spring, tov_DKSetAside, tov_DKSetAside_SummerMow, tov_DKSpringBarley, tov_DKSpringBarley_CC, tov_DKSpringBarley_Green, tov_DKSpringBarleyCloverGrass, tov_DKSpringBarleySilage, tov_DKSpringFodderGrass, tov_DKSpringOats, tov_DKSpringOats_CC, tov_DKSpringWheat, tov_DKSugarBeets, tov_DKUndefined, tov_DKVegSeeds, tov_DKWinterBarley, tov_DKWinterCloverGrassGrazedSown, tov_DKWinterFodderGrass, tov_DKWinterRape, tov_DKWinterRye, tov_DKWinterRye_CC, tov_DKWinterWheat, tov_DKWinterWheat_CC, tov_FIBufferZone, tov_FIBufferZone_Perm, tov_FICaraway1, tov_FICaraway2, tov_FieldPeas, tov_FieldPeasSilage, tov_FieldPeasStrigling, tov_FIFabaBean, tov_FIFeedingGround, tov_FIGrasslandPasturePerennial1, tov_FIGrasslandPasturePerennial2, tov_FIGrasslandSilageAnnual, tov_FIGrasslandSilagePerennial1, tov_FIGrasslandSilagePerennial2, tov_FIGreenFallow_1year, tov_FIGreenFallow_Perm, tov_FINaturalGrassland, tov_FINaturalGrassland_Perm, tov_FIOCaraway1, tov_FIOCaraway2, tov_FIOFabaBean, tov_FIOPotato_North, tov_FIOPotato_South, tov_FIOPotatoIndustry_North, tov_FIOPotatoIndustry_South, tov_FIOSpringBarley_Fodder, tov_FIOSpringBarley_Malt, tov_FIOSpringOats, tov_FIOSpringRape, tov_FIOSpringWheat, tov_FIOStarchPotato_North, tov_FIOStarchPotato_South, tov_FIOTurnipRape, tov_FIOWinterRye, tov_FIOWinterWheat, tov_FIPotato_North, tov_FIPotato_South, tov_FIPotatoIndustry_North, tov_FIPotatoIndustry_South, tov_FISpringBarley_Fodder, tov_FISpringBarley_Malt, tov_FISpringOats, tov_FISpringRape, tov_FISpringWheat, tov_FISprSpringBarley_Fodder, tov_FIStarchPotato_North, tov_FIStarchPotato_South, tov_FISugarBeet, tov_FITurnipRape, tov_FIWinterRye, tov_FIWinterWheat, tov_FodderBeet, tov_FodderGrass, tov_FRGrassland, tov_FRGrassland_Perm, tov_FRMaize, tov_FRMaize_Silage, tov_FRPotatoes, tov_FRSorghum, tov_FRSpringBarley, tov_FRSpringOats, tov_FRSpringWheat, tov_FRSunflower, tov_FRWinterBarley, tov_FRWinterRape, tov_FRWinterTriticale, tov_FRWinterWheat, tov_Heath, tov_IRGrassland_no_reseed, tov_IRGrassland_reseed, tov_IRSpringBarley, tov_IRSpringOats, tov_IRSpringWheat, tov_IRWinterBarley, tov_IRWinterOats, tov_IRWinterWheat, tov_ITGrassland, tov_ITOOrchard, tov_ITOrchard, tov_Maize, tov_MaizeSilage, tov_MaizeStrigling, tov_NaturalGrass, tov_NLBeet, tov_NLBeetSpring, tov_NLCabbage, tov_NLCabbageSpring, tov_NLCarrots, tov_NLCarrotsSpring, tov_NLCatchCropPea, tov_NLGrassGrazed1, tov_NLGrassGrazed1Spring, tov_NLGrassGrazed2, tov_NLGrassGrazedExtensive1, tov_NLGrassGrazedExtensive1Spring, tov_NLGrassGrazedExtensive2, tov_NLGrassGrazedExtensiveLast, tov_NLGrassGrazedLast, tov_NLMaize, tov_NLMaizeSpring, tov_NLOrchardCrop, tov_NLPermanentGrassGrazed, tov_NLPermanentGrassGrazedExtensive, tov_NLPotatoes, tov_NLPotatoesSpring, tov_NLSpringBarley, tov_NLSpringBarleySpring, tov_NLTulips, tov_NLWinterWheat, tov_NoGrowth, tov_None, tov_Oats, tov_OBarleyPeaCloverGrass, tov_OCarrots, tov_OCloverGrassGrazed1, tov_OCloverGrassGrazed2, tov_OCloverGrassSilage1, tov_OFieldPeas, tov_OFieldPeasSilage, tov_OFirstYearDanger, tov_OFodderBeet, tov_OGrazingPigs, tov_OMaizeSilage, tov_OOats, tov_OPermanentGrassGrazed, tov_OPotatoes, tov_OrchardCrop, tov_OSBarleySilage, tov_OSeedGrass1, tov_OSeedGrass2, tov_OSetAside, tov_OSpringBarley, tov_OSpringBarleyExt, tov_OSpringBarleyPigs, tov_OTriticale, tov_OWinterBarley, tov_OWinterBarleyExt, tov_OWinterRape, tov_OWinterRye, tov_OWinterWheat, tov_OWinterWheatUndersown, tov_OWinterWheatUndersownExt, tov_PermanentGrassGrazed, tov_PermanentGrassLowYield, tov_PermanentGrassTussocky, tov_PermanentSetAside, tov_PLBeans, tov_PLBeet, tov_PLBeetSpr, tov_PLCarrots, tov_PLFodderLucerne1, tov_PLFodderLucerne2, tov_PLMaize, tov_PLMaizeSilage, tov_PLPotatoes, tov_PLSpringBarley, tov_PLSpringBarleySpr, tov_PLSpringWheat, tov_PLWinterBarley, tov_PLWinterRape, tov_PLWinterRye, tov_PLWinterTriticale, tov_PLWinterWheat, tov_PLWinterWheatLate, tov_Potatoes, tov_PTBeans, tov_PTCabbage, tov_PTCabbage_Hort, tov_PTCloverGrassGrazed1, tov_PTCloverGrassGrazed2, tov_PTCorkOak, tov_PTFodderMix, tov_PTGrassGrazed, tov_PTHorticulture, tov_PTMaize, tov_PTMaize_Hort, tov_PTOats, tov_PTOliveGroveIntensive, tov_PTOliveGroveSuperIntensive, tov_PTOliveGroveTraditional, tov_PTOliveGroveTradOrganic, tov_PTOtherDryBeans, tov_PTPermanentGrassGrazed, tov_PTPotatoes, tov_PTRyegrass, tov_PTSetAside, tov_PTSorghum, tov_PTTriticale, tov_PTTurnipGrazed, tov_PTVineyards, tov_PTWinterBarley, tov_PTWinterRye, tov_PTWinterWheat, tov_PTYellowLupin, tov_SeedGrass1, tov_SeedGrass2, tov_SESpringBarley, tov_SetAside, tov_SEWinterRape_Seed, tov_SEWinterWheat, tov_SpringBarley, tov_SpringBarleyCloverGrass, tov_SpringBarleyCloverGrassStrigling, tov_SpringBarleyPeaCloverGrassStrigling, tov_SpringBarleyPTreatment, tov_SpringBarleySeed, tov_SpringBarleySilage, tov_SpringBarleySKManagement, tov_SpringBarleySpr, tov_SpringBarleyStrigling, tov_SpringBarleyStriglingCulm, tov_SpringBarleyStriglingSingle, tov_SugarBeet, tov_Triticale, tov_UKBeans, tov_UKBeet, tov_UKMaize, tov_UKPermanentGrass, tov_UKPotatoes, tov_UKSpringBarley, tov_UKTempGrass, tov_UKWinterBarley, tov_UKWinterRape, tov_UKWinterWheat, tov_Undefined, tov_Wasteland, tov_WaterBufferZone, tov_WinterBarley, tov_WinterBarleyStrigling, tov_WinterRape, tov_WinterRapeStrigling, tov_WinterRye, tov_WinterRyeStrigling, tov_WinterWheat, tov_WinterWheatShort, tov_WinterWheatStrigling, tov_WinterWheatStriglingCulm, tov_WinterWheatStriglingSingle, tov_WWheatPControl, tov_WWheatPToxicControl, tov_WWheatPTreatment, tov_YoungForest, CfgBool::value(), CfgArray_Double::value(), and PlantGrowthData::VegTypeToCurveNum().

◆ ~VegElement()

virtual VegElement::~VegElement ( void  )
inlinevirtual
699 { ; };

Member Function Documentation

◆ CalcGooseForageResources()

void VegElement::CalcGooseForageResources ( )
protected

Calculates spilled grain and grazing forage resources for geese.

The 1.0325 is a quick fix to account for higher energy intake on winter cereal - Based on Therkildsen & Madsen 2000 Energetics of feeding...

or potentially it is a grazable grass

2309 {
2310  // For geese that eat spilled grain and maize we need to remove some of this daily (loss to other things than geese)
2311  // Get the Julian day
2312  int day = g_date->DayInYear();
2313  double rate, maizerate;
2316  maizerate = cfg_goose_MaizeDecayRateWinter.value();
2317  }
2318  else{
2319  if ((day > March) && (day < July)){
2321  maizerate = cfg_goose_MaizeDecayRateSpring.value();
2322  }
2323  else {
2325  maizerate = cfg_goose_MaizeDecayRateWinter.value();
2326  }
2327  }
2328 
2329  //std::cout<<"DEBUG: grain decay rate is "<<rate<<"\n";
2330  if (m_birdseedforage>0){
2331  m_birdseedforage *= rate;
2332  }
2333 
2334 
2335  if (m_birdseedforage < 0.01) m_birdseedforage = 0.0;
2336  if (m_birdmaizeforage>0){
2337  m_birdmaizeforage *= maizerate;
2338  }
2339 
2340  if (m_birdmaizeforage < 0.01) m_birdmaizeforage = 0.0;
2341  // We also need to calculate non-grain forage for geese
2342  if (IsCereal()) {
2343  //if (m_green_biomass > 0.5) //Testing if this could be a suitable fix for the cereals
2344  //{
2345  for (unsigned i = 0; i < gs_foobar; i++) {
2348  }
2349  //}
2350  //else for (unsigned i = 0; i < gs_foobar; i++) {
2351  // m_goosegrazingforage[i] = 0.0;
2352  //}
2353  //m_goosegrazingforage[gs_foobar] = 1; // Is cereal
2354  }
2356  else {
2357  if (IsGooseGrass()) {
2358  for (unsigned i = 0; i < gs_foobar; i++) {
2359  //m_goosegrazingforage[ i ] = 0.0;
2361  }
2362  }
2363  else for (unsigned i = 0; i < gs_foobar; i++) m_goosegrazingforage[i] = 0.0;
2364  }
2365 }

References cfg_goose_GrainDecayRateSpring, cfg_goose_GrainDecayRateWinter, cfg_goose_grass_to_winter_cereal_scaler, cfg_goose_MaizeDecayRateSpring, cfg_goose_MaizeDecayRateWinter, cfg_goose_UniformDecayRate, Calendar::DayInYear(), g_date, IsCereal(), IsGooseGrass(), July, LE::m_birdmaizeforage, LE::m_birdseedforage, LE::m_goosegrazingforage, LE::m_Landscape, m_veg_height, March, Landscape::SupplyGooseGrazingForageH(), CfgFloat::value(), and CfgBool::value().

Referenced by SetSpeciesFunction().

◆ CalculateAphidDrivers()

void VegElement::CalculateAphidDrivers ( )
protected

Determines the amount of new growth.

This is meant to be used for aphids, but may calculate useful things for other organisms.

1976 {
1978 
1979  //Calculation of the green biomass percentage to the total biomass.
1980  m_greenbiomass_per = 0;
1983  }
1984 }

References m_green_biomass, m_greenbiomass_per, m_veg_biomass, and m_weed_biomass.

Referenced by SetSpeciesFunction().

◆ CalculateDigestibility()

void VegElement::CalculateDigestibility ( )
protected

Sets vegetation digestability for hare and vole.

This is used for hare and voles. It is a 32-day running sum of the amount of new growth per day divided by total veg biomass with a minimum value of 0.5

1935 {
1937  ++m_newoldgrowthindex &= 31;
1938  if ((m_veg_biomass+m_weed_biomass) > 0) {
1939  switch (m_vege_type) {
1940  case tov_NoGrowth:
1941  case tov_None:
1942  case tov_OFirstYearDanger:
1943  m_digestability = 0.0;
1944  break;
1945  case tov_OPotatoes:
1946  case tov_Potatoes:
1947  case tov_PotatoesIndustry:
1948  case tov_PLMaizeSilage:
1949  case tov_PLPotatoes:
1950  case tov_NLPotatoes:
1951  case tov_NLPotatoesSpring:
1952  case tov_UKPotatoes:
1953  case tov_DEPotatoes:
1954  case tov_PTPotatoes:
1955  m_digestability = 0.5;
1956  break;
1957  default:
1958  //m_oldnewgrowth[m_newoldgrowthindex]=(newgrowth/m_veg_biomass);
1960  m_newgrowthsum = 0.0;
1961  for (int i = 0; i < 32; i++) {
1963  }
1965  m_digestability += 0.5;
1966  if (m_digestability > 0.8) m_digestability = 0.8;
1967  }
1968  }
1969  else {
1971  m_digestability = 0.0;
1972  }
1973 }

References m_digestability, m_new_weed_growth, m_newgrowth, m_newgrowthsum, m_newoldgrowthindex, m_oldnewgrowth, m_veg_biomass, m_vege_type, m_weed_biomass, tov_DEPotatoes, tov_NLPotatoes, tov_NLPotatoesSpring, tov_NoGrowth, tov_None, tov_OFirstYearDanger, tov_OPotatoes, tov_PLMaizeSilage, tov_PLPotatoes, tov_Potatoes, tov_PotatoesIndustry, tov_PTPotatoes, and tov_UKPotatoes.

Referenced by SetSpeciesFunction().

◆ CalculateInsectBiomass()

void VegElement::CalculateInsectBiomass ( )
protected

An insect biomass calculation for those species that need it.

2176 {
2177  // The insect calculation part
2178  // Bugmass = a + b(biomass) + c(height)
2179  //double temp_bugmass = //g_bug_percent_d[ m_vege_type ] // This was used as a scaler - now not used
2180  // g_bug_percent_a[m_vege_type] + ((m_veg_biomass + m_weed_biomass) * g_bug_percent_b[m_vege_type])
2181  // + (m_veg_height * g_bug_percent_c[m_vege_type]);
2185  temp_bugmass *= m_SeasonalInsectScaler[g_date->GetMonthRaw()]; // Raw version is zero based
2186  // Set a minimum value (regressions will otherwise sometimes give a -ve value
2187  if (temp_bugmass < 0.05) temp_bugmass = 0.05;
2188  temp_bugmass *= cfg_insectbiomassscaling.value();
2189  // Now need to check for deviations caused by management
2190  // First spot the deviation - this is easy because the only deviation that does
2191  // not affect the vegetation too is insecticide spraying
2193  // Need to change insects still, so grow towards the target, but only when 21 days from zero effect
2196  }
2197  else {
2198  m_insect_pop = temp_bugmass;
2199  }
2200 }

References cfg_insectbiomassscaling, g_date, Calendar::GetMonthRaw(), LE::m_days_since_insecticide_spray, m_dead_biomass, m_green_biomass, m_insect_biomass_parameters_a, m_insect_biomass_parameters_b, m_insect_biomass_parameters_c, m_insect_biomass_parameters_index, m_insect_pop, m_SeasonalInsectScaler, m_veg_height, m_weed_biomass, and CfgFloat::value().

Referenced by SetSpeciesFunction().

◆ DoDevelopment()

void VegElement::DoDevelopment ( void  )
virtual

Next grows weeds proportionally to day degrees and using the weed curve if no herbicide effect before calling RecalculateBugsNStuff to caculate insect biomass, cover, digestability etc..

Here we need to set today's goose numbers to zero in case they are not written by the goose population manager (the normal situation)

Reimplemented from LE.

Reimplemented in MownGrassStrip, OrchardBand, Orchard, ForestElement, UnsprayedFieldMargin, WaterBufferZone, RoadsideVerge, FieldBoundary, FlowerStripWithRotation, FlowerStrip, BeetleBank, HedgeBank, Hedges, Field, and NaturalGrass.

2564  {
2565  //update the flower resource for the crops without sowing date
2566 
2569  if(!sowing_flag){
2576  m_OurPollenNectarCurveSet = temp_curve_set; //set it back to the original curve set
2579  }
2580  }
2581 
2582  m_new_weed_growth = 0.0;
2583  if (!m_force_growth) {
2584  //** First does the day degree calculations */
2585  m_yddegs = m_ddegs;
2586  double pos_temp_today = g_weather->GetDDDegs(g_date->Date());
2587  if (m_vegddegs != -1.0)
2588  m_vegddegs += pos_temp_today; // Sum up the vegetation day degrees since sowing
2589  m_ddegs = pos_temp_today + m_yddegs; // and sum up the phase ddegs
2590 
2594 
2595  m_LAgreen += dLAG;
2596  if (m_LAgreen < 0.0) m_LAgreen = 0.0;
2597  m_LAtotal += dLAT;
2598  if (m_LAtotal < 0.0) m_LAtotal = 0.0;
2599  m_veg_height += dHgt;
2600  if (m_veg_height < 0.0) m_veg_height = 0.0;
2601 
2602  if (this->m_owner_index != -1) { // This only works because only crops and similar structures have owners
2603  if (m_herbicidedelay == 0)
2604  {
2605  // Need to force some weed growth so switch growth for weeds only
2606  // We want to follow the original curve but reset it
2607  m_weedddegs = pos_temp_today;
2608  } else m_weedddegs += pos_temp_today;
2610  const double fintensity = m_Landscape->SupplyFarmIntensity(m_poly);
2611  if (m_herbicidedelay <= 0) {
2612  const double dWee = g_crops->GetLAtotalDiff(m_weedddegs, m_weedddegs -pos_temp_today, m_weed_curve_num, m_veg_phase);
2613  m_new_weed_growth = dWee * cfg_ele_weedscaling.value() * (1+fintensity);
2616  }
2617  if (m_weed_biomass < 0.0) m_weed_biomass = 0.0;
2618  }
2619  }
2620  else {
2622  }
2623 
2624  // check here that m_LAtotal is bigger than m_LAgreen
2625  if (m_LAtotal < m_LAgreen)
2626  {
2627  char error_num[100];
2628  sprintf(error_num, "%f < %f (force growth = %d)", m_LAtotal, m_LAgreen, m_force_growth);
2629  g_msg->WarnAddInfo(WARN_TRIVIAL, "Landscape::DoDevelopment(): Leaf Area Total smaller than Leaf Area Green (Veg Growth Model inconsistent). Performing hack correction.", error_num);
2630  m_LAtotal = 1.1 * m_LAgreen;
2631  // exit(1);
2632  }
2635  ResetGeese();
2636  // Deal with any possible unsprayed margin, transferring info as necessary
2637  if (GetUnsprayedMarginPolyRef() != -1) {
2640  }
2641 
2643 }

References LE::CalculateFlowerResourceForCrop(), cfg_ele_weedscaling, cfg_FloweringPeriodPhasesProportionArray, Calendar::Date(), ForceGrowthDevelopment(), g_crops, g_date, g_msg, g_nectarpollen, g_weather, CfgArray_Double::get_array_size(), Weather::GetDDDegs(), PlantGrowthData::GetHeightDiffScaled(), PlantGrowthData::GetLAgreenDiffScaled(), PlantGrowthData::GetLAtotalDiff(), PlantGrowthData::GetLAtotalDiffScaled(), LE::GetUnsprayedMarginPolyRef(), Calendar::JanFirst(), m_att_veg_patchy, LE::m_cattle_grazing, m_curve_num, LE::m_ddegs, m_dead_biomass, LE::m_flowering_phases, m_force_growth, m_green_biomass, m_growth_scaler, LE::m_herbicidedelay, m_insect_pop, m_interested_biomass_fraction, m_interested_green_biomass, m_LAgreen, LE::m_Landscape, m_LAtotal, LE::m_nectar_amount, m_new_weed_growth, LE::m_OurPollenNectarCurveSet, LE::m_owner_index, LE::m_pollen_amount, LE::m_pollen_nectar_curve_index, LE::m_poly, LE::m_sugar_amount, m_veg_biomass, m_veg_cover, m_veg_density, m_veg_height, m_veg_phase, LE::m_vegddegs, m_vege_type, m_weed_biomass, m_weed_curve_num, LE::m_weedddegs, LE::m_yddegs, PollenNectarReset(), RecalculateBugsNStuff(), ResetGeese(), LE::SetCropDataAll(), Landscape::SupplyFarmIntensity(), Landscape::SupplyLEPointer(), PollenNectarDevelopmentData::tovGetPollenNectarCurveSowingFlag(), CfgFloat::value(), WARN_TRIVIAL, and MapErrorMsg::WarnAddInfo().

Referenced by Field::DoDevelopment(), Hedges::DoDevelopment(), HedgeBank::DoDevelopment(), BeetleBank::DoDevelopment(), FlowerStrip::DoDevelopment(), FlowerStripWithRotation::DoDevelopment(), FieldBoundary::DoDevelopment(), RoadsideVerge::DoDevelopment(), WaterBufferZone::DoDevelopment(), NaturalGrass::DoDevelopment(), ForestElement::DoDevelopment(), Orchard::DoDevelopment(), OrchardBand::DoDevelopment(), and MownGrassStrip::DoDevelopment().

◆ DoNothing()

void VegElement::DoNothing ( void  )
inlineprotected

The default for SpeciesSpecificCalculations.

929 { return; }

Referenced by SetSpeciesFunction(), and VegElement().

◆ ForceGrowthDevelopment()

void VegElement::ForceGrowthDevelopment ( void  )
virtual

Reimplemented from LE.

2531  {
2532  if ( m_herbicidedelay <= 0 ) {
2533  m_weed_biomass += m_force_Weed; // ***CJT*** 12th Sept 2008 - rather than force growth, weeds might be allowed to grow on their own
2535  }
2539 
2540  if (m_LAgreen < 0) m_LAgreen = 0;
2541  if (m_LAtotal < 0) m_LAtotal = 0;
2542  if (m_veg_height < 0) m_veg_height = 0;
2543 }

References m_force_LAgreen, m_force_LAtotal, m_force_veg_height, m_force_Weed, LE::m_herbicidedelay, m_LAgreen, m_LAtotal, m_new_weed_growth, m_veg_height, and m_weed_biomass.

Referenced by DoDevelopment().

◆ ForceGrowthInitialiseForFirstYearCrop()

void VegElement::ForceGrowthInitialiseForFirstYearCrop ( void  )
virtual

Reimplemented from LE.

2462  {
2463  double LAgreen_target;
2464  double Weed_target;
2465  double LAtotal_target;
2466  double veg_height_target;
2467  int next_phase = janfirst; //this type crop always force grow to the first day of the year
2468  int daysleft = 366 - g_date->DayInYear();
2469 
2470  double vari = (g_rand_uni_fnc() * 0.4) + 0.8;
2471  Weed_target = g_crops->GetStartValue(m_weed_curve_num, next_phase, 0) * vari;
2472  LAgreen_target = g_crops->GetStartValue(m_curve_num, next_phase, 0) * vari;
2473  LAtotal_target = g_crops->GetStartValue(m_curve_num, next_phase, 1) * vari;
2474  veg_height_target = g_crops->GetStartValue(m_curve_num, next_phase, 2) * vari;
2475  m_force_growth = true;
2476  m_force_Weed = ( Weed_target - m_weed_biomass ) / ( double )daysleft;
2477  m_force_LAgreen = ( LAgreen_target - m_LAgreen ) / ( double )daysleft;
2478  m_force_LAtotal = ( LAtotal_target - m_LAtotal ) / ( double )daysleft;
2479  m_force_veg_height = ( veg_height_target - m_veg_height ) / ( double )daysleft;
2480 
2481 }

References Calendar::DayInYear(), g_crops, g_date, g_rand_uni_fnc(), PlantGrowthData::GetStartValue(), janfirst, m_curve_num, m_force_growth, m_force_LAgreen, m_force_LAtotal, m_force_veg_height, m_force_Weed, m_LAgreen, m_LAtotal, m_veg_height, m_weed_biomass, and m_weed_curve_num.

◆ ForceGrowthInitialize()

void VegElement::ForceGrowthInitialize ( bool  a_force_decreasing = false)
virtual

Reimplemented from LE.

2484  {
2485  double LAgreen_target;
2486  double Weed_target;
2487  double LAtotal_target;
2488  double veg_height_target;
2489  int next_phase, daysleft;
2490 
2491  // Figure out what our target phase is.
2492  if ( g_date->DayInYear() < g_date->DayInYear( 3, 1 ) ) {
2493  daysleft = g_date->DayInYear( 1, 3 ) - g_date->DayInYear();
2494  next_phase = marchfirst;
2495  } else if ( g_date->DayInYear() >= g_date->DayInYear( 1, 11 ) ) {
2496  daysleft = 366 - g_date->DayInYear(); // Adjusted from 365 to prevent occaisional negative values
2497  next_phase = janfirst;
2498  } else {
2499  return;
2500  }
2501  if ( daysleft <= 0 )
2502  // Uh! Oh! This really shouldn't happen.
2503  return;
2504 
2505  if ( !g_crops->StartValid( m_curve_num, next_phase ) ) {
2506  // If no valid starting values for next phase, then
2507  // preinitialize the random starting values! Ie. make the
2508  // choice here and then do not choose another set come
2509  // next phase transition, but use the values we already
2510  // got at that point in time.
2511  RandomVegStartValues( & LAtotal_target, & LAgreen_target, & veg_height_target, & Weed_target );
2512  }
2513  else {
2514  //add +/- 20% variation
2515  double vari = (g_rand_uni_fnc() * 0.4) + 0.8;
2516  Weed_target = g_crops->GetStartValue(m_weed_curve_num, next_phase, 0) * vari;
2517  LAgreen_target = g_crops->GetStartValue(m_curve_num, next_phase, 0) * vari;
2518  LAtotal_target = g_crops->GetStartValue(m_curve_num, next_phase, 1) * vari;
2519  veg_height_target = g_crops->GetStartValue(m_curve_num, next_phase, 2) * vari;
2520  }
2521 
2522  if(!a_force_decreasing && (( LAgreen_target - m_LAgreen ) <= 0.0 || ( LAtotal_target - m_LAtotal ) <= 0.0 || ( veg_height_target - m_veg_height ) <= 0.00)) return; // No need to force growth if we are already there
2523  m_force_growth = true;
2524  m_force_Weed = ( Weed_target - m_weed_biomass ) / ( double )daysleft;
2525  m_force_LAgreen = ( LAgreen_target - m_LAgreen ) / ( double )daysleft;
2526  m_force_LAtotal = ( LAtotal_target - m_LAtotal ) / ( double )daysleft;
2527  m_force_veg_height = ( veg_height_target - m_veg_height ) / ( double )daysleft;
2528 }

References Calendar::DayInYear(), g_crops, g_date, g_rand_uni_fnc(), PlantGrowthData::GetStartValue(), janfirst, m_curve_num, m_force_growth, m_force_LAgreen, m_force_LAtotal, m_force_veg_height, m_force_Weed, m_LAgreen, m_LAtotal, m_veg_height, m_weed_biomass, m_weed_curve_num, marchfirst, RandomVegStartValues(), and PlantGrowthData::StartValid().

Referenced by ForceGrowthSpringTest(), and ForceGrowthTest().

◆ ForceGrowthSpringTest()

void VegElement::ForceGrowthSpringTest ( void  )
protected
2443  {
2444  // Check if there are any positive growth differentials in the curve
2445  // for the first two months of the year. Do nothing if there is.
2446  // If we have any positive growth then no need to force either
2447  if (g_crops->GetLAgreenDiff(90000.0, 0.0, m_curve_num, janfirst) > 0.001
2448  || g_crops->GetLAtotalDiff(90000.0, 0.0, m_curve_num, janfirst) > 0.001
2449  || g_crops->GetHeightDiff(90000.0, 0.0, m_curve_num, janfirst) > 0.001) {
2450  return;
2451  }
2452  if (g_crops->GetLAgreenDiff(90000.0, 0.0, m_curve_num, janfirst) < 0
2453  || g_crops->GetLAtotalDiff(90000.0, 0.0, m_curve_num, janfirst) < 0
2454  || g_crops->GetHeightDiff(90000.0, 0.0, m_curve_num, janfirst) < 0) {
2455  return;
2456  }
2457  // No growth, force it.
2459 }

References ForceGrowthInitialize(), g_crops, PlantGrowthData::GetHeightDiff(), PlantGrowthData::GetLAgreenDiff(), PlantGrowthData::GetLAtotalDiff(), janfirst, and m_curve_num.

Referenced by SetGrowthPhase().

◆ ForceGrowthTest()

void VegElement::ForceGrowthTest ( void  )
virtual

Reimplemented from LE.

2428  {
2429  // Called whenever the farmer does something 'destructive' to a
2430  // field, that reduced the vegetaion.
2431  if ( g_date->DayInYear() >= g_date->DayInYear( 1, 11 )) {
2432  ForceGrowthInitialize(true); // in winter, we want negative growth (decreasing)
2433  }
2434 
2435  if ( g_date->DayInYear() >= g_date->DayInYear( 1, 11 )
2436  || ( g_date->DayInYear() < g_date->DayInYear( 1, 3 ) && m_force_growth ) ) {
2438  }
2439 }

References Calendar::DayInYear(), ForceGrowthInitialize(), g_date, and m_force_growth.

Referenced by ReduceVeg(), ReduceVeg_Extended(), and ZeroVeg().

◆ GetCropType()

virtual TTypesOfCrops VegElement::GetCropType ( void  )
inlinevirtual

Reimplemented in Field.

721 { return m_CropType; }

References LE::m_CropType.

◆ GetDeadBiomass()

virtual double VegElement::GetDeadBiomass ( void  )
inlinevirtual

Reimplemented from LE.

708 { return m_dead_biomass; }

References m_dead_biomass.

◆ GetDigestibility()

virtual double VegElement::GetDigestibility ( void  )
inlinevirtual

Reimplemented from LE.

701 { return m_digestability; }

References m_digestability.

◆ GetGreenBiomass()

virtual double VegElement::GetGreenBiomass ( void  )
inlinevirtual

Reimplemented from LE.

709 { return m_green_biomass; }

References m_green_biomass.

◆ GetGreenBiomassProp()

virtual double VegElement::GetGreenBiomassProp ( void  )
inlinevirtual

Reimplemented from LE.

711 { return m_greenbiomass_per; }

References m_greenbiomass_per.

◆ GetInsectPop()

virtual double VegElement::GetInsectPop ( void  )
inlinevirtual

Reimplemented from LE.

718 { return m_insect_pop; }

References m_insect_pop.

◆ GetInterestedGreenBiomass()

virtual double VegElement::GetInterestedGreenBiomass ( void  )
inlinevirtual

Reimplemented from LE.

710 { return m_interested_green_biomass; }

References m_interested_green_biomass.

◆ GetIsVeg()

virtual bool VegElement::GetIsVeg ( void  )
inlinevirtual

Reimplemented from LE.

704 { return true; }

◆ GetLAGreen()

virtual double VegElement::GetLAGreen ( void  )
inlinevirtual

Reimplemented from LE.

702 { return m_LAgreen; }

References m_LAgreen.

◆ GetLATotal()

virtual double VegElement::GetLATotal ( void  )
inlinevirtual

Reimplemented from LE.

703 { return m_LAtotal; }

References m_LAtotal.

◆ GetSkScrapes()

virtual bool VegElement::GetSkScrapes ( void  )
inlinevirtual

Reimplemented from LE.

714 { return m_skylarkscrapes; }

References LE::m_skylarkscrapes.

◆ GetVegBiomass()

virtual double VegElement::GetVegBiomass ( void  )
inlinevirtual

◆ GetVegCover()

virtual double VegElement::GetVegCover ( void  )
inlinevirtual

Reimplemented from LE.

705 { return m_veg_cover; }

References m_veg_cover.

◆ GetVegDensity()

virtual int VegElement::GetVegDensity ( void  )
inlinevirtual

Reimplemented from LE.

713 { return m_veg_density; }

References m_veg_density.

◆ GetVegHeight()

virtual double VegElement::GetVegHeight ( void  )
inlinevirtual

Reimplemented from LE.

706 { return m_veg_height; }

References m_veg_height.

◆ GetVegPhase()

virtual int VegElement::GetVegPhase ( void  )
inlinevirtual

Reimplemented from LE.

841 { return m_veg_phase; }

References m_veg_phase.

◆ GetVegType()

virtual TTypesOfVegetation VegElement::GetVegType ( void  )
inlinevirtual
720 { return m_vege_type; }

References m_vege_type.

◆ GetWeedBiomass()

virtual double VegElement::GetWeedBiomass ( void  )
inlinevirtual

Reimplemented from LE.

712 { return m_weed_biomass; }

References m_weed_biomass.

◆ GrazeVegetation()

void VegElement::GrazeVegetation ( double  a_grams,
bool  a_force 
)
virtual

/brief Reduce the total vegetation biomass as a result of grazing per m2

Used to calculate the change in vegetation height and biomass as a result of grazing. Input parameter is the change in wet biomass/m2. The problem is to convert this into changes in LAtotal, LAgreen and height. We have an area, biomass, total biomass, height and density. If biomass is missing we need to change height and biomass before continuing and and do something with LA_total and LA_Green. Some assumptions: 1 - The grazing takes all LA equally 2 - That biomass is evenly distributed 3 - That LA is proportional to biomass in some way, so LA is also evenly distributed 4 - That we can use the current grazing pressure to alter a_reduc

Reimplemented from LE.

2689 {
2701  if (!a_force) a_reduc *= m_default_grazing_level;
2702  if (a_reduc >= m_veg_biomass) return;
2703  double propreduc = 1.0 - (a_reduc / m_veg_biomass);
2704  m_veg_height *= propreduc;
2705  m_weed_biomass *= propreduc;
2706  m_veg_biomass -= a_reduc;
2707  // Need to do something with the LA too -
2708  m_LAgreen *= propreduc;
2709  m_LAtotal *= propreduc;
2710  m_oldLAtotal = m_LAtotal; // this stops double reduction of biomass later in RecalculateBugsNStuff();
2711  if (propreduc > 0 && propreduc < 1) g_pest->ReducePlantPesticide(GetMinX(), GetMaxX(), GetMinY(), GetMaxY(), GetMapIndex(), propreduc);
2712 }

References g_pest, LE::GetMapIndex(), LE::GetMaxX(), LE::GetMaxY(), LE::GetMinX(), LE::GetMinY(), LE::m_default_grazing_level, m_LAgreen, m_LAtotal, m_oldLAtotal, m_veg_biomass, m_veg_height, m_weed_biomass, and Pesticide::ReducePlantPesticide().

Referenced by GrazeVegetationTotal().

◆ GrazeVegetationHeight()

void VegElement::GrazeVegetationHeight ( double  a_reduc)
virtual

/brief Reduces the vegetation by length of grass (in cm)

Used to calculate the change in vegetation height and biomass as a result of grazing. Input parameter is the change in height. Some assumptions: 1 - The grazing takes all LA equally 2 - That biomass is evenly distributed 3 - That LA is proportional to biomass in some way, so LA is also evenly distributed

Reimplemented from LE.

2665 {
2674  if (m_veg_height - a_reduc < cfg_farm_cattle_grass_low.value()){
2675  a_reduc = m_veg_height - cfg_farm_cattle_grass_low.value() + 0.5;
2676  }
2677  double propreduc = 1.0 - (a_reduc / m_veg_height);
2678  m_veg_height *= propreduc;
2679  m_weed_biomass *= propreduc;
2680  m_veg_biomass *= propreduc;
2681  // Need to do something with the LA too -
2682  m_LAgreen *= propreduc;
2683  m_LAtotal *= propreduc;
2684  m_oldLAtotal = m_LAtotal; // this stops double reduction of biomass later in RecalculateBugsNStuff();
2685  if (propreduc > 0 && propreduc < 1) g_pest->ReducePlantPesticide(GetMinX(), GetMaxX(), GetMinY(), GetMaxY(), GetMapIndex(), propreduc);
2686 }

References cfg_farm_cattle_grass_low, g_pest, LE::GetMapIndex(), LE::GetMaxX(), LE::GetMaxY(), LE::GetMinX(), LE::GetMinY(), m_LAgreen, m_LAtotal, m_oldLAtotal, m_veg_biomass, m_veg_height, m_weed_biomass, Pesticide::ReducePlantPesticide(), and CfgInt::value().

◆ GrazeVegetationTotal()

void VegElement::GrazeVegetationTotal ( double  a_grams)
virtual

The function that reduces the vegetation due to grazing.

/brief Reduce the total vegetation biomass as a result of grazing per polygon

On Nov 18 Andrey has updated the function to take into account the digestability. the search revealed that there is no other model is using it apart from Goose model so hopefully there would be no unintended effects

Reimplemented from LE.

2659 {
2660 
2661  GrazeVegetation( (a_grams*m_digestability)/m_area, true );
2662 }

References GrazeVegetation(), LE::m_area, and m_digestability.

◆ Insecticide()

virtual void VegElement::Insecticide ( double  a_fraction)
inlinevirtual

Reimplemented from LE.

758  {
759  m_insect_pop *= a_fraction;
760  if(a_fraction <= 0.36) //normal pesticide
762  if(a_fraction > 0.36 && a_fraction < 1) //bio pesticide
764  }

References LE::m_days_since_insecticide_spray, and m_insect_pop.

◆ InsectMortality()

void VegElement::InsectMortality ( double  a_fraction)
virtual

Reimplemented from LE.

2843  {
2844  m_insect_pop *= a_fraction;
2845 }

References m_insect_pop.

Referenced by FlowerStripWithRotation::DoDevelopment().

◆ Is_Att_Veg()

virtual bool VegElement::Is_Att_Veg ( void  )
inlinevirtual

Reimplemented from LE.

767 { return m_att_veg; }

References m_att_veg.

◆ Is_Att_VegCereal()

virtual bool VegElement::Is_Att_VegCereal ( )
inlinevirtual

Reimplemented from LE.

771 { return m_att_veg_cereal; }

References m_att_veg_cereal.

Referenced by IsCereal().

◆ Is_Att_VegGooseGrass()

virtual bool VegElement::Is_Att_VegGooseGrass ( )
inlinevirtual

Reimplemented from LE.

779 { return m_att_veg_goosegrass; }

References m_att_veg_goosegrass.

Referenced by IsGooseGrass().

◆ Is_Att_VegGrass()

virtual bool VegElement::Is_Att_VegGrass ( )
inlinevirtual

Reimplemented from LE.

777 { return m_att_veg_grass; }

References m_att_veg_grass.

◆ Is_Att_VegMaize()

virtual bool VegElement::Is_Att_VegMaize ( )
inlinevirtual

Reimplemented from LE.

775 { return m_att_veg_maize; }

References m_att_veg_maize.

Referenced by IsMaize().

◆ Is_Att_VegMatureCereal()

virtual bool VegElement::Is_Att_VegMatureCereal ( )
inlinevirtual

Reimplemented from LE.

773 { return m_att_veg_maturecereal; }

References m_att_veg_maturecereal.

Referenced by IsMatureCereal().

◆ Is_Att_VegPatchy()

virtual bool VegElement::Is_Att_VegPatchy ( void  )
inlinevirtual

Reimplemented from LE.

769 { return m_att_veg_patchy; }

References m_att_veg_patchy.

◆ IsCereal()

bool VegElement::IsCereal ( )
inline
786 { return Is_Att_VegCereal(); }

References Is_Att_VegCereal().

Referenced by CalcGooseForageResources().

◆ IsGooseGrass()

bool VegElement::IsGooseGrass ( )
inline
787 { return Is_Att_VegGooseGrass(); }

References Is_Att_VegGooseGrass().

Referenced by CalcGooseForageResources().

◆ IsMaize()

bool VegElement::IsMaize ( )
inline
785 { return Is_Att_VegMaize(); }

References Is_Att_VegMaize().

◆ IsMatureCereal()

bool VegElement::IsMatureCereal ( )
inline
784 { return Is_Att_VegMatureCereal(); }

References Is_Att_VegMatureCereal().

◆ PollenNectarPhenologyCalculation()

void VegElement::PollenNectarPhenologyCalculation ( )
protectedvirtual

This methods calculates the daily availability of pollen and nectar per square meter and in total.

2228 {
2229  //Update habitat
2230  //if (m_OurPollenNectarCurveSet == NULL && m_pollen_nectar_curve_index >0){
2232  if(g_date->JanFirst()){
2234  return;
2235  }
2240  return;
2241  }
2242 
2243  //update setaside crops
2246  if(g_date->JanFirst()){
2248  return;
2249  }
2252  m_polleninfo.m_quantity /= 2.0;
2253  m_nectarinfo.m_quantity /= 2.0;
2254  m_nectarinfo.m_quality /= 2.0;
2257  return;
2258  }
2259 
2260  //update flower strip with rotation crops
2263  if (g_date->JanFirst()) {
2265  return;
2266  }
2271  return;
2272  }
2273 
2274  //update crop
2277  double temp_nectar = 0.0;
2278  double temp_sugar = 0.0;
2279  double temp_pollen = 0.0;
2280  double temp_pollen_quality = 0.0;
2281 
2282 
2283 
2285  for (int i = m_flowering_phases.size()-2; i>=0; i--){
2287  temp_nectar = m_nectar_amount[i];
2288  temp_sugar = m_sugar_amount[i];
2289  temp_pollen = m_pollen_amount[i];
2290  if(temp_pollen>0){
2291  temp_pollen_quality = m_OurPollenNectarCurveSet->m_pollen_quality;
2292  }
2293  break;
2294  }
2295  }
2296  }
2297 
2298  m_polleninfo.m_quantity = temp_pollen;
2299  m_polleninfo.m_quality = temp_pollen_quality;
2300  m_nectarinfo.m_quantity = temp_nectar;
2301  m_nectarinfo.m_quality = temp_sugar;
2304  return;
2305  }
2306 }

References g_date, Calendar::JanFirst(), LE::m_area, LE::m_CropType, LE::m_flowering_day_counter, LE::m_flowering_phases, LE::m_Landscape, LE::m_nectar_amount, LE::m_nectarinfo, LE::m_OurPollenNectarCurveSet, LE::m_pollen_amount, LE::m_pollen_nectar_curve_index, PollenNectarDevelopmentCurveSet::m_pollen_quality, LE::m_polleninfo, PollenNectarData::m_quality, PollenNectarData::m_quantity, LE::m_sugar_amount, LE::m_totalNectar, LE::m_totalPollen, m_vege_type, PollenNectarReset(), Landscape::SupplyNectarHabitatType(), Landscape::SupplyPollenHabitatType(), toc_OSetAside, toc_OSetAside_Flower, toc_SetAside, tov_DKOptimalFlowerMix1, tov_DKOptimalFlowerMix2, and tov_DKOptimalFlowerMix3.

Referenced by SetSpeciesFunction(), and VegElement().

◆ PollenNectarReset()

void VegElement::PollenNectarReset ( )
protectedvirtual

Resets the daily availability of pollen and nectar per square meter and in total to zero.

Reset its the first day of the year for the habitat or the sowing day for the crops.

Reimplemented from LE.

2203 {
2206 
2210  m_polleninfo.m_quality = 0;
2212  m_nectarinfo.m_quality = 0;
2213  m_totalNectar = 0;
2214  m_totalPollen = 0;
2215  m_start_dd_flower = false;
2219  m_pollen_nectar_curve_index = 0; //0 means there is not flower resouce, if there is flower resource, it will be set int the new crop
2220  }
2221  m_flowering_phases.clear();
2222  m_nectar_amount.clear();
2223  m_pollen_amount.clear();
2224  m_sugar_amount.clear();
2225 }

References m_acc_DD_flower_resource, LE::m_flowering_day_counter, LE::m_flowering_phases, LE::m_nectar_amount, LE::m_nectarinfo, m_num_flowring_peroid, LE::m_OurPollenNectarCurveSet, LE::m_pollen_amount, LE::m_pollen_nectar_curve_index, LE::m_polleninfo, PollenNectarData::m_quality, PollenNectarData::m_quantity, m_start_dd_flower, LE::m_sugar_amount, LE::m_totalNectar, and LE::m_totalPollen.

Referenced by DoDevelopment(), and PollenNectarPhenologyCalculation().

◆ RandomVegStartValues()

void VegElement::RandomVegStartValues ( double *  a_LAtotal,
double *  a_LAgreen,
double *  a_veg_height,
double *  a_weed_biomass 
)
protected
2367  {
2368  * a_LAtotal = EL_VEG_START_LAIT * ( ( ( ( double )( g_random_fnc( 21 ) - 10 ) ) / 100.0 ) + 1.0 ); // +/- 10%
2369  * a_LAgreen = * a_LAtotal / 4.0;
2370  * a_veg_height = * a_LAgreen * EL_VEG_HEIGHTSCALE;
2371  * a_weed_biomass = * a_LAgreen * 0.1; // 10% weeds by biomass
2372 }

References EL_VEG_HEIGHTSCALE, EL_VEG_START_LAIT, and g_random_fnc().

Referenced by ForceGrowthInitialize().

◆ ReadBugPercentageFile()

void VegElement::ReadBugPercentageFile ( void  )
protected
1797  {
1798  FILE* lm_ifile=fopen(l_el_bug_percentage_file.value(), "r" );
1799  if ( !lm_ifile ) {
1800  g_msg->Warn( WARN_FILE, "PlantGrowthData::ReadBugPercentageFile(): Unable to open file", l_el_bug_percentage_file.value() );
1801  exit( 1 );
1802  }
1803  for ( int i = 0; i < tov_Undefined; i++ ) {
1804  int vegnum;
1805  // **cjt** modified 31/01/2004
1806  double weedpercent, bugpercent_a, bugpercent_b, bugpercent_c, bugpercent_d;
1807  if ( 2 != fscanf( lm_ifile, "%d %lf %lf %lf %lf %lf", & vegnum, & weedpercent, & bugpercent_a, & bugpercent_b,
1808  & bugpercent_c, & bugpercent_d ) ) {
1809  char vegnums[ 20 ];
1810  sprintf( vegnums, "%d", tov_Undefined );
1811  g_msg->Warn( WARN_FILE,
1812  "VegElement::ReadBugPercentageFile(): Unable to read"
1813  " sufficient number of int/double pairs from bug percentage file."" Lines expected:", vegnums );
1814  exit( 1 );
1815  }
1816  //FloatToDouble( g_weed_percent[ vegnum ], weedpercent);
1817  //FloatToDouble( g_bug_percent_a[ vegnum ] , bugpercent_a);
1818  //FloatToDouble( g_bug_percent_b[ vegnum ] , bugpercent_b);
1819  //FloatToDouble( g_bug_percent_c[ vegnum ] , bugpercent_c);
1820  //FloatToDouble( g_bug_percent_d[ vegnum ] , bugpercent_d);
1821  g_weed_percent[ vegnum ] = weedpercent;
1822  g_bug_percent_a[ vegnum ] = bugpercent_a;
1823  g_bug_percent_b[ vegnum ] = bugpercent_b;
1824  g_bug_percent_c[ vegnum ] = bugpercent_c;
1825  g_bug_percent_d[ vegnum ] = bugpercent_d;
1826  }
1827  fclose( lm_ifile );
1828 }

References g_bug_percent_a, g_bug_percent_b, g_bug_percent_c, g_bug_percent_d, g_msg, g_weed_percent, l_el_bug_percentage_file(), tov_Undefined, CfgStr::value(), MapErrorMsg::Warn(), and WARN_FILE.

◆ RecalculateBugsNStuff()

void VegElement::RecalculateBugsNStuff ( void  )
protectedvirtual

This method is responsible for.

This is the heart of the dynamics of vegetation elements. It calculates vegetation cover and uses this to determine vegetation biomass. It also calculates spilled grain and goose forage, as well a calculating insect biomass, vegetation density and dead biomass

Here we also want to know how much biomass we have on the field in total. So we multiply the current biomass by area

Reimplemented from LE.

1830  {
1833  m_newgrowth = 0;
1834  m_veg_cover = 1.0 - (exp(-cfg_beer_law_extinction_coef.value()*m_LAtotal )); // Beer's Law to give cover
1835  double usefull_veg_cover = 1.0 - (exp(m_LAgreen * -0.4)); // This is used to calc growth rate
1836  // Need gloabal radiation today
1837  double glrad = m_Landscape->SupplyGlobalRadiation();
1838  // This is different for maize (a C4 plant)
1839  int ptype;
1840  if ((m_vege_type == tov_Maize) || (m_vege_type == tov_OMaizeSilage) || (m_vege_type == tov_MaizeSilage) || (m_vege_type == tov_MaizeStrigling)) ptype = 1; else ptype = 0;
1841  int index = (int)floor(0.5 + m_Landscape->SupplyTemp()) + 30; // There are 30 negative temps
1842  double radconv = c_SolarConversion[ptype][index];
1843  if (m_LAtotal >= m_oldLAtotal) {
1844  // we are in positive growth so grow depending on our equation
1845  m_newgrowth = usefull_veg_cover * glrad * radconv * m_biomass_scale[m_vege_type];
1846  if (m_owner_index != -1) { // This only works because only crops and similar structures have owners
1847  double fintensity = m_Landscape->SupplyFarmIntensity(m_poly);
1848  if (fintensity >= 1) {
1849  // 1 means extensive, so reduce vegetation biomass by 20%
1850  // NB this cannot be used with extensive crop types otherwise you get an additional 20% reduction
1851  // This way of doing things provides a quick and dirty general effect.
1852  m_veg_biomass += m_newgrowth * 0.8;
1853  }
1854  else m_veg_biomass += m_newgrowth;
1855  }
1856  else m_veg_biomass += m_newgrowth;
1857  }
1858  else {
1859  // Negative growth - so shrink proportional to the loss in LAI Total
1860  if (m_oldLAtotal > 0) {
1861  double temp_propotion = m_LAtotal / m_oldLAtotal;
1862  //m_newgrowth = m_veg_biomass*(temp_propotion-1);
1863  m_veg_biomass *= temp_propotion;
1864  }
1865  }
1869  // NB The m_weed_biomass is calculated directly from the curve in Curves.pre
1870  // rather than going through the rigmarole of converting leaf-area index
1871  m_veg_density = (int)(floor(0.5 + (m_veg_biomass / (1 + m_veg_height))));
1872  if (m_veg_density > 100) m_veg_density = 100; // to stop array bounds problems
1873  if (m_LAtotal == 0.0) m_green_biomass = 0.0;
1876  // Here we use our member function pointer to call the correct piece of code for our current species
1877  (this->*(SpeciesSpecificCalculations))();
1878  // update the cell level pollen if there is
1879  if (cfg_pollen_nectar_on.value()) {
1880  if(m_polleninfo.m_quantity > 0){
1882  }
1883  if(m_nectarinfo.m_quantity > 0){
1885  }
1886  // update the green biomass map
1889  }
1890  }
1891 }

References c_SolarConversion, cfg_beer_law_extinction_coef, cfg_pollen_nectar_on, LE::m_area, m_biomass_scale, m_dead_biomass, m_green_biomass, m_LAgreen, LE::m_Landscape, m_LAtotal, LE::m_maxx, LE::m_maxy, LE::m_minx, LE::m_miny, LE::m_nectarinfo, m_newgrowth, m_oldLAtotal, LE::m_owner_index, LE::m_polleninfo, LE::m_poly, PollenNectarData::m_quantity, m_total_biomass, m_total_biomass_old, m_veg_biomass, m_veg_cover, m_veg_density, m_veg_height, m_vege_type, Landscape::SetGreenBiomassMap(), Landscape::SetNectarMap(), Landscape::SetPollenMap(), SpeciesSpecificCalculations, Landscape::SupplyFarmIntensity(), Landscape::SupplyGlobalRadiation(), Landscape::SupplyTemp(), tov_Maize, tov_MaizeSilage, tov_MaizeStrigling, tov_OMaizeSilage, CfgFloat::value(), and CfgBool::value().

Referenced by FlowerStrip::Cutting(), FieldBoundary::Cutting(), RoadsideVerge::Cutting(), Orchard::Cutting(), MownGrassStrip::Cutting(), DoDevelopment(), and ZeroVeg().

◆ ReduceVeg()

void VegElement::ReduceVeg ( double  a_reduc)
virtual

Reimplemented from LE.

2714  {
2715  m_LAgreen *= a_reduc;
2716  m_LAtotal *= a_reduc;
2717  m_veg_height *= a_reduc;
2718  m_veg_biomass *= a_reduc;
2719  m_weed_biomass *= a_reduc;
2720 
2721  if (a_reduc > 0 && a_reduc < 1) g_pest->ReducePlantPesticide(GetMinX(), GetMaxX(), GetMinY(), GetMaxY(), GetMapIndex(), a_reduc);
2722  ForceGrowthTest();
2723  m_oldLAtotal = m_LAtotal; // this stops double reduction of biomass later in RecalculateBugsNStuff();
2724 }

References ForceGrowthTest(), g_pest, LE::GetMapIndex(), LE::GetMaxX(), LE::GetMaxY(), LE::GetMinX(), LE::GetMinY(), m_LAgreen, m_LAtotal, m_oldLAtotal, m_veg_biomass, m_veg_height, m_weed_biomass, and Pesticide::ReducePlantPesticide().

Referenced by FlowerStripWithRotation::DoDevelopment(), and OrchardBand::DoDevelopment().

◆ ReduceVeg_Extended()

void VegElement::ReduceVeg_Extended ( double  a_reduc)
virtual

Reimplemented from LE.

2726  {
2727  m_LAgreen *= a_reduc;
2728  m_LAtotal *= a_reduc;
2729  m_veg_height *= a_reduc;
2730  m_veg_biomass *= a_reduc;
2731  m_weed_biomass *= a_reduc;
2732 
2733  if (a_reduc < EL_GROWTH_PHASE_SHIFT_LEVEL) {
2734  m_yddegs = 0.0;
2736  }
2737 
2740  m_forced_phase_shift = true;
2741  }
2742 
2743  if (a_reduc > 0 && a_reduc < 1) g_pest->ReducePlantPesticide(GetMinX(), GetMaxX(), GetMinY(), GetMaxY(), GetMapIndex(), a_reduc);
2744  ForceGrowthTest();
2745  m_oldLAtotal = m_LAtotal; // this stops double reduction of biomass later in RecalculateBugsNStuff();
2746 }

References Calendar::DayInYear(), EL_GROWTH_DATE_MAGIC, EL_GROWTH_DAYDEG_MAGIC, EL_GROWTH_PHASE_SHIFT_LEVEL, ForceGrowthTest(), g_date, g_pest, LE::GetMapIndex(), LE::GetMaxX(), LE::GetMaxY(), LE::GetMinX(), LE::GetMinY(), harvest1, LE::m_ddegs, m_forced_phase_shift, m_LAgreen, m_LAtotal, m_oldLAtotal, m_veg_biomass, m_veg_height, m_weed_biomass, LE::m_yddegs, Pesticide::ReducePlantPesticide(), and SetGrowthPhase().

◆ ReduceWeedBiomass()

virtual void VegElement::ReduceWeedBiomass ( double  a_fraction)
inlinevirtual

Reimplemented from LE.

794  {
795  m_weed_biomass *= a_fraction;
796  }

References m_weed_biomass.

◆ ResetDigestibility()

virtual void VegElement::ResetDigestibility ( )
inlinevirtual

sets growth record to zero

Reimplemented from LE.

836  {
837  StoreLAItotal();
838  for (int i = 0; i < 32; i++) m_oldnewgrowth[i] = 0.0;
839  }

References m_oldnewgrowth, and StoreLAItotal().

◆ ResetGeese()

void VegElement::ResetGeese ( void  )
protected

Reset geese numbers to zero in case this was not done by the population manager (the normal situation).

2645  {
2646  m_gooseNos[ g_date->DayInYear() ] = 0;
2647  for (unsigned i = 0; i < gs_foobar; i++) {
2648  m_gooseSpNos[ g_date->DayInYear() ][ (GooseSpecies)i ] = 0;
2649  m_gooseSpNosTimed[ g_date->DayInYear() ][ (GooseSpecies)i ] = 0;
2650  }
2651 }

References Calendar::DayInYear(), g_date, LE::m_gooseNos, LE::m_gooseSpNos, and LE::m_gooseSpNosTimed.

Referenced by DoDevelopment().

◆ Set_Att_Veg()

virtual void VegElement::Set_Att_Veg ( bool  p)
inlinevirtual
768 { m_att_veg = p; }

References m_att_veg.

Referenced by VegElement().

◆ Set_Att_VegCereal()

virtual void VegElement::Set_Att_VegCereal ( bool  p)
inlinevirtual

Reimplemented from LE.

772 { m_att_veg_cereal = p; }

References m_att_veg_cereal.

Referenced by VegElement().

◆ Set_Att_VegGooseGrass()

virtual void VegElement::Set_Att_VegGooseGrass ( bool  p)
inlinevirtual

Reimplemented from LE.

780 { m_att_veg_goosegrass = p; }

References m_att_veg_goosegrass.

Referenced by VegElement().

◆ Set_Att_VegGrass()

virtual void VegElement::Set_Att_VegGrass ( bool  p)
inlinevirtual

Reimplemented from LE.

778 { m_att_veg_grass = p; }

References m_att_veg_grass.

Referenced by FlowerStrip::DoDevelopment(), FieldBoundary::FieldBoundary(), and VegElement().

◆ Set_Att_VegMaize()

virtual void VegElement::Set_Att_VegMaize ( bool  p)
inlinevirtual

Reimplemented from LE.

776 { m_att_veg_maize = p; }

References m_att_veg_maize.

Referenced by VegElement().

◆ Set_Att_VegMatureCereal()

virtual void VegElement::Set_Att_VegMatureCereal ( bool  p)
inlinevirtual

Reimplemented from LE.

774 { m_att_veg_maturecereal = p; }

References m_att_veg_maturecereal.

Referenced by VegElement().

◆ Set_Att_VegPatchy()

◆ SetBiomassScalers()

void VegElement::SetBiomassScalers ( TTypesOfVegetation  a_tov)
static
344  {
345  switch (a_tov)
346  {
347  case tov_BroadBeans: m_biomass_scale[a_tov] = 0.857; break;
348  case tov_FieldPeas: m_biomass_scale[a_tov] = 0.857; break;
349  case tov_FieldPeasSilage: m_biomass_scale[a_tov] = 0.857; break;
350  case tov_OWinterWheat: m_biomass_scale[a_tov] = 1.00 * 0.8; break;
351  case tov_OWinterWheatUndersown: m_biomass_scale[a_tov] = 1.00 * 0.8; break;
352  case tov_OWinterWheatUndersownExt: m_biomass_scale[a_tov] = 1.00 * 0.8 * 0.8; break;
353  case tov_AgroChemIndustryCereal: m_biomass_scale[a_tov] = 1; break;
354  case tov_BEBeet: m_biomass_scale[a_tov] = 0.857; break;
355  case tov_BEBeetSpring: m_biomass_scale[a_tov] = 0.857; break;
356  case tov_BECatchPeaCrop: m_biomass_scale[a_tov] = 0.857; break;
357  case tov_BEGrassGrazed1: m_biomass_scale[a_tov] = 1.2; break;
358  case tov_BEGrassGrazed1Spring: m_biomass_scale[a_tov] = 1.2; break;
359  case tov_BEGrassGrazed2: m_biomass_scale[a_tov] = 1.2; break;
360  case tov_BEGrassGrazedLast: m_biomass_scale[a_tov] = 1.2; break;
361  case tov_BEMaize: m_biomass_scale[a_tov] = 1; break;
362  case tov_BEMaizeCC: m_biomass_scale[a_tov] = 1; break;
363  case tov_BEMaizeSpring: m_biomass_scale[a_tov] = 1; break;
364  case tov_BEOrchardCrop: m_biomass_scale[a_tov] = 0.7857; break;
365  case tov_BEPotatoes: m_biomass_scale[a_tov] = 0.857; break;
366  case tov_BEPotatoesSpring: m_biomass_scale[a_tov] = 0.857; break;
367  case tov_BEWinterBarley: m_biomass_scale[a_tov] = 0.857; break;
368  case tov_BEWinterBarleyCC: m_biomass_scale[a_tov] = 1; break;
369  case tov_BEWinterWheat: m_biomass_scale[a_tov] = 1; break;
370  case tov_BEWinterWheatCC: m_biomass_scale[a_tov] = 1; break;
371  case tov_Carrots: m_biomass_scale[a_tov] = 0.7857; break;
372  case tov_CloverGrassGrazed1: m_biomass_scale[a_tov] = 1.2; break;
373  case tov_CloverGrassGrazed2: m_biomass_scale[a_tov] = 1.2; break;
374  case tov_DEAsparagusEstablishedPlantation: m_biomass_scale[a_tov] = 0.857 * 0.8; break;
375  case tov_DEBushFruitPerm: m_biomass_scale[a_tov] = 0.7857; break;
376  case tov_DECabbage: m_biomass_scale[a_tov] = 0.7857; break;
377  case tov_DECarrots: m_biomass_scale[a_tov] = 0.7857; break;
378  case tov_DEGrasslandSilageAnnual: m_biomass_scale[a_tov] = 1.1; break;
379  case tov_DEGreenFallow_1year: m_biomass_scale[a_tov] = 0.7857; break;
380  case tov_DEHerbsPerennial_1year: m_biomass_scale[a_tov] = 0.857 * 0.8; break;
381  case tov_DEHerbsPerennial_after1year: m_biomass_scale[a_tov] = 0.857 * 0.8; break;
382  case tov_DELegumes: m_biomass_scale[a_tov] = 0.857; break;
383  case tov_DEMaize: m_biomass_scale[a_tov] = 1; break;
384  case tov_DEMaizeSilage: m_biomass_scale[a_tov] = 1; break;
385  case tov_DEOAsparagusEstablishedPlantation: m_biomass_scale[a_tov] = 0.857 * 0.8; break;
386  case tov_DEOats: m_biomass_scale[a_tov] = 0.857; break;
387  case tov_DEOBushFruitPerm: m_biomass_scale[a_tov] = 0.7857; break;
388  case tov_DEOCabbages: m_biomass_scale[a_tov] = 0.7857 * 0.8; break;
389  case tov_DEOCarrots: m_biomass_scale[a_tov] = 0.7857 * 0.8; break;
390  case tov_DEOGrasslandSilageAnnual: m_biomass_scale[a_tov] = 1.1 * 0.8; break;
391  case tov_DEOGreenFallow_1year: m_biomass_scale[a_tov] = 0.857 * 0.8; break;
392  case tov_DEOHerbsPerennial_1year: m_biomass_scale[a_tov] = 0.857 * 0.8; break;
393  case tov_DEOHerbsPerennial_after1year: m_biomass_scale[a_tov] = 0.857 * 0.8; break;
394  case tov_DEOLegume: m_biomass_scale[a_tov] = 0.857 * 0.8; break;
395  case tov_DEOMaize: m_biomass_scale[a_tov] = 1.0 * 0.8; break;
396  case tov_DEOMaizeSilage: m_biomass_scale[a_tov] = 1.0 * 0.8; break;
397  case tov_DEOOats: m_biomass_scale[a_tov] = 0.857 * 0.8; break;
398  case tov_DEOOrchard: m_biomass_scale[a_tov] = 0.7857; break;
399  case tov_DEOPeas: m_biomass_scale[a_tov] = 0.857; break;
400  case tov_DEOPermanentGrassGrazed: m_biomass_scale[a_tov] = 1; break;
401  case tov_DEOPermanentGrassLowYield: m_biomass_scale[a_tov] = 1; break;
402  case tov_DEOPotatoes: m_biomass_scale[a_tov] = 0.857 * 0.8; break;
403  case tov_DEOrchard: m_biomass_scale[a_tov] = 0.7857; break;
404  case tov_DEOSpringRye: m_biomass_scale[a_tov] = 0.857 * 0.8; break;
405  case tov_DEOSugarBeet: m_biomass_scale[a_tov] = 0.857 * 0.8; break;
406  case tov_DEOTriticale: m_biomass_scale[a_tov] = 0.8; break;
407  case tov_DEOWinterBarley: m_biomass_scale[a_tov] = 0.8; break;
408  case tov_DEOWinterRape: m_biomass_scale[a_tov] = 0.8; break;
409  case tov_DEOWinterRye: m_biomass_scale[a_tov] = 0.857 * 0.8; break;
410  case tov_DEOWinterWheat: m_biomass_scale[a_tov] = 0.8; break;
411  case tov_DEPeas: m_biomass_scale[a_tov] = 0.857; break;
412  case tov_DEPermanentGrassGrazed: m_biomass_scale[a_tov] = 1; break;
413  case tov_DEPermanentGrassLowYield: m_biomass_scale[a_tov] = 1; break;
414  case tov_DEPotatoes: m_biomass_scale[a_tov] = 0.857; break;
415  case tov_DEPotatoesIndustry: m_biomass_scale[a_tov] = 0.857; break;
416  case tov_DESpringBarley: m_biomass_scale[a_tov] = 0.857; break;
417  case tov_DESpringRye: m_biomass_scale[a_tov] = 0.857; break;
418  case tov_DESugarBeet: m_biomass_scale[a_tov] = 0.857; break;
419  case tov_DETriticale: m_biomass_scale[a_tov] = 1; break;
420  case tov_DEWinterBarley: m_biomass_scale[a_tov] = 1; break;
421  case tov_DEWinterRape: m_biomass_scale[a_tov] = 1; break;
422  case tov_DEWinterRye: m_biomass_scale[a_tov] = 0.857; break;
423  case tov_DEWinterWheat: m_biomass_scale[a_tov] = 1; break;
424  case tov_DEWinterWheatLate: m_biomass_scale[a_tov] = 1; break;
425  case tov_DKBushFruit_Perm1: m_biomass_scale[a_tov] = 0.7857; break;
426  case tov_DKBushFruit_Perm2: m_biomass_scale[a_tov] = 0.7857; break;
427  case tov_DKCabbages: m_biomass_scale[a_tov] = 0.7857; break;
428  case tov_DKCarrots: m_biomass_scale[a_tov] = 0.7857; break;
429  case tov_DKCatchCrop: m_biomass_scale[a_tov] = 0.857; break;
430  case tov_DKCerealLegume: m_biomass_scale[a_tov] = 0.857; break;
431  case tov_DKCerealLegume_Whole: m_biomass_scale[a_tov] = 0.857; break;
432  case tov_DKChristmasTrees_Perm: m_biomass_scale[a_tov] = 0.7857 * 0.67; break;
433  case tov_DKCloverGrassGrazed1: m_biomass_scale[a_tov] = 1.1; break;
434  case tov_DKCloverGrassGrazed2: m_biomass_scale[a_tov] = 1.1; break;
435  case tov_DKCloverGrassGrazed3: m_biomass_scale[a_tov] = 1.1; break;
436  case tov_DKEnergyCrop_Perm: m_biomass_scale[a_tov] = 0.7857 * 0.67; break;
437  case tov_DKFarmForest_Perm: m_biomass_scale[a_tov] = 0.7857 * 0.67; break;
438  case tov_DKFarmYoungForest_Perm: m_biomass_scale[a_tov] = 0.7857 * 0.67; break;
439  case tov_DKFodderBeets: m_biomass_scale[a_tov] = 0.857; break;
440  case tov_DKGrassGrazed_Perm: m_biomass_scale[a_tov] = 1.1; break;
441  case tov_DKGrassLowYield_Perm: m_biomass_scale[a_tov] = 1; break;
442  case tov_DKGrassTussocky_Perm: m_biomass_scale[a_tov] = 0.7857; break;
443  case tov_DKGrazingPigs: m_biomass_scale[a_tov] = 0.7857; break;
444  case tov_DKGrazingPigs_Perm: m_biomass_scale[a_tov] = 0.7857; break;
445  case tov_DKLegume_Beans: m_biomass_scale[a_tov] = 0.857; break;
446  case tov_DKLegume_Peas: m_biomass_scale[a_tov] = 0.857; break;
447  case tov_DKLegume_Whole: m_biomass_scale[a_tov] = 0.857; break;
448  case tov_DKMaize: m_biomass_scale[a_tov] = 1; break;
449  case tov_DKMaizeSilage: m_biomass_scale[a_tov] = 1; break;
450  case tov_DKMixedVeg: m_biomass_scale[a_tov] = 0.7857; break;
451  case tov_DKOBushFruit_Perm1: m_biomass_scale[a_tov] = 0.7857 * 0.8; break;
452  case tov_DKOBushFruit_Perm2: m_biomass_scale[a_tov] = 0.7857 * 0.8; break;
453  case tov_DKOCabbages: m_biomass_scale[a_tov] = 0.7857 * 0.8; break;
454  case tov_DKOCarrots: m_biomass_scale[a_tov] = 0.7857 * 0.8; break;
455  case tov_DKOCatchCrop: m_biomass_scale[a_tov] = 0.857; break;
456  case tov_DKOCerealLegume: m_biomass_scale[a_tov] = 0.857 * 0.8; break;
457  case tov_DKOCerealLegume_Whole: m_biomass_scale[a_tov] = 0.857 * 0.8; break;
458  case tov_DKOChristmasTrees_Perm: m_biomass_scale[a_tov] = 0.7857 * 0.67; break;
459  case tov_DKOCloverGrassGrazed1: m_biomass_scale[a_tov] = 1.1; break;
460  case tov_DKOCloverGrassGrazed2: m_biomass_scale[a_tov] = 1.1; break;
461  case tov_DKOCloverGrassGrazed3: m_biomass_scale[a_tov] = 1.1; break;
462  case tov_DKOEnergyCrop_Perm: m_biomass_scale[a_tov] = 0.7857 * 0.67; break;
463  case tov_DKOFarmForest_Perm: m_biomass_scale[a_tov] = 0.7857 * 0.67; break;
464  case tov_DKOFarmYoungForest_Perm: m_biomass_scale[a_tov] = 0.7857 * 0.67; break;
465  case tov_DKOFodderBeets: m_biomass_scale[a_tov] = 0.857; break;
466  case tov_DKOGrassGrazed_Perm: m_biomass_scale[a_tov] = 1.1; break;
467  case tov_DKOGrassLowYield_Perm: m_biomass_scale[a_tov] = 1; break;
468  case tov_DKOGrazingPigs: m_biomass_scale[a_tov] = 0.7857 * 0.8; break;
469  case tov_DKOGrazingPigs_Perm: m_biomass_scale[a_tov] = 0.7857 * 0.8; break;
470  case tov_DKOLegume_Beans: m_biomass_scale[a_tov] = 0.857 * 0.8; break;
471  case tov_DKOLegume_Beans_CC: m_biomass_scale[a_tov] = 0.857 * 0.8; break;
472  case tov_DKOLegume_Peas: m_biomass_scale[a_tov] = 0.857 * 0.8; break;
473  case tov_DKOLegume_Peas_CC: m_biomass_scale[a_tov] = 0.857 * 0.8; break;
474  case tov_DKOLegume_Whole: m_biomass_scale[a_tov] = 0.857 * 0.8; break;
475  case tov_DKOLegume_Whole_CC: m_biomass_scale[a_tov] = 0.857 * 0.8; break;
476  case tov_DKOLegumeCloverGrass_Whole: m_biomass_scale[a_tov] = 0.857 * 0.8; break;
477  case tov_DKOLentils: m_biomass_scale[a_tov] = 0.857 * 0.8; break;
478  case tov_DKOLupines: m_biomass_scale[a_tov] = 0.857 * 0.8; break;
479  case tov_DKOMaize: m_biomass_scale[a_tov] = 1.00 * 0.8; break;
480  case tov_DKOMaizeSilage: m_biomass_scale[a_tov] = 1.00 * 0.8; break;
481  case tov_DKOMixedVeg: m_biomass_scale[a_tov] = 0.7857 * 0.8; break;
482  case tov_DKOOrchApple: m_biomass_scale[a_tov] = 0.7857; break;
483  case tov_DKOOrchardCrop_Perm: m_biomass_scale[a_tov] = 0.7857 * 0.8; break;
484  case tov_DKOOrchCherry: m_biomass_scale[a_tov] = 0.7857; break;
485  case tov_DKOOrchOther: m_biomass_scale[a_tov] = 0.7857; break;
486  case tov_DKOOrchPear: m_biomass_scale[a_tov] = 0.7857; break;
487  case tov_DKOPotato: m_biomass_scale[a_tov] = 0.857 * 0.8; break;
488  case tov_DKOPotatoIndustry: m_biomass_scale[a_tov] = 0.857 * 0.8; break;
489  case tov_DKOPotatoSeed: m_biomass_scale[a_tov] = 0.857 * 0.8; break;
490  case tov_DKOptimalFlowerMix1: m_biomass_scale[a_tov] = 0.7857; break;
491  case tov_DKOptimalFlowerMix2: m_biomass_scale[a_tov] = 0.7857; break;
492  case tov_DKOptimalFlowerMix3: m_biomass_scale[a_tov] = 0.7857; break;
493  case tov_DKOrchApple: m_biomass_scale[a_tov] = 0.7857; break;
494  case tov_DKOrchardCrop_Perm: m_biomass_scale[a_tov] = 0.7857; break;
495  case tov_DKOrchCherry: m_biomass_scale[a_tov] = 0.7857; break;
496  case tov_DKOrchOther: m_biomass_scale[a_tov] = 0.7857; break;
497  case tov_DKOrchPear: m_biomass_scale[a_tov] = 0.7857; break;
498  case tov_DKOSeedGrassRye_Spring: m_biomass_scale[a_tov] = 0.7857; break;
499  case tov_DKOSetAside: m_biomass_scale[a_tov] = 0.7857; break;
500  case tov_DKOSetAside_AnnualFlower: m_biomass_scale[a_tov] = 0.7857; break;
501  case tov_DKOSetAside_PerennialFlower: m_biomass_scale[a_tov] = 0.7857; break;
502  case tov_DKOSetAside_SummerMow: m_biomass_scale[a_tov] = 0.7857; break;
503  case tov_DKOSpringBarley: m_biomass_scale[a_tov] = 0.857 * 0.8; break;
504  case tov_DKOSpringBarley_CC: m_biomass_scale[a_tov] = 0.857 * 0.8; break;
505  case tov_DKOSpringBarleyCloverGrass: m_biomass_scale[a_tov] = 0.857 * 0.8; break;
506  case tov_DKOSpringBarleySilage: m_biomass_scale[a_tov] = 0.857 * 0.8; break;
507  case tov_DKOSpringFodderGrass: m_biomass_scale[a_tov] = 1.2; break;
508  case tov_DKOSpringOats: m_biomass_scale[a_tov] = 0.857 * 0.8; break;
509  case tov_DKOSpringOats_CC: m_biomass_scale[a_tov] = 0.857 * 0.8; break;
510  case tov_DKOSpringWheat: m_biomass_scale[a_tov] = 1.0 * 0.8; break;
511  case tov_DKOSugarBeets: m_biomass_scale[a_tov] = 0.857 * 0.8; break;
512  case tov_DKOVegSeeds: m_biomass_scale[a_tov] = 0.7857; break;
513  case tov_DKOWinterBarley: m_biomass_scale[a_tov] = 0.857 * 0.8; break;
514  case tov_DKOWinterCloverGrassGrazedSown: m_biomass_scale[a_tov] = 1.1; break;
515  case tov_DKOWinterFodderGrass: m_biomass_scale[a_tov] = 1.2; break;
516  case tov_DKOWinterRape: m_biomass_scale[a_tov] = 1.071 * 0.8; break;
517  case tov_DKOWinterRye: m_biomass_scale[a_tov] = 0.857 * 0.8; break;
518  case tov_DKOWinterRye_CC: m_biomass_scale[a_tov] = 0.857 * 0.8; break;
519  case tov_DKOWinterWheat: m_biomass_scale[a_tov] = 1.00 * 0.8; break;
520  case tov_DKOWinterWheat_CC: m_biomass_scale[a_tov] = 1.00 * 0.8; break;
521  case tov_DKPlantNursery_Perm: m_biomass_scale[a_tov] = 0.7857; break;
522  case tov_DKPotato: m_biomass_scale[a_tov] = 0.857; break;
523  case tov_DKPotatoIndustry: m_biomass_scale[a_tov] = 0.857; break;
524  case tov_DKPotatoSeed: m_biomass_scale[a_tov] = 0.857; break;
525  case tov_DKSeedGrassFescue_Spring: m_biomass_scale[a_tov] = 0.7857; break;
526  case tov_DKSeedGrassRye_Spring: m_biomass_scale[a_tov] = 0.7857; break;
527  case tov_DKSetAside: m_biomass_scale[a_tov] = 0.7857; break;
528  case tov_DKSetAside_SummerMow: m_biomass_scale[a_tov] = 0.7857; break;
529  case tov_DKSpringBarley: m_biomass_scale[a_tov] = 0.857; break;
530  case tov_DKSpringBarley_CC: m_biomass_scale[a_tov] = 0.857; break;
531  case tov_DKSpringBarley_Green: m_biomass_scale[a_tov] = 0.857; break;
532  case tov_DKSpringBarleyCloverGrass: m_biomass_scale[a_tov] = 0.857; break;
533  case tov_DKSpringBarleySilage: m_biomass_scale[a_tov] = 0.857; break;
534  case tov_DKSpringFodderGrass: m_biomass_scale[a_tov] = 1.2; break;
535  case tov_DKSpringOats: m_biomass_scale[a_tov] = 0.857; break;
536  case tov_DKSpringOats_CC: m_biomass_scale[a_tov] = 0.857; break;
537  case tov_DKSpringWheat: m_biomass_scale[a_tov] = 1; break;
538  case tov_DKSugarBeets: m_biomass_scale[a_tov] = 0.857; break;
539  case tov_DKUndefined: m_biomass_scale[a_tov] = 0; break;
540  case tov_DKVegSeeds: m_biomass_scale[a_tov] = 0.7857; break;
541  case tov_DKWinterBarley: m_biomass_scale[a_tov] = 0.857; break;
542  case tov_DKWinterCloverGrassGrazedSown: m_biomass_scale[a_tov] = 1.1; break;
543  case tov_DKWinterFodderGrass: m_biomass_scale[a_tov] = 1.2; break;
544  case tov_DKWinterRape: m_biomass_scale[a_tov] = 1.071; break;
545  case tov_DKWinterRye: m_biomass_scale[a_tov] = 0.857; break;
546  case tov_DKWinterRye_CC: m_biomass_scale[a_tov] = 0.857; break;
547  case tov_DKWinterWheat: m_biomass_scale[a_tov] = 1; break;
548  case tov_DKWinterWheat_CC: m_biomass_scale[a_tov] = 1; break;
549  case tov_GenericCatchCrop: m_biomass_scale[a_tov] = 0.857; break;
550  case tov_FIBufferZone: m_biomass_scale[a_tov] = 1.1; break;
551  case tov_FIBufferZone_Perm: m_biomass_scale[a_tov] = 1.1; break;
552  case tov_FICaraway1: m_biomass_scale[a_tov] = 0.7857; break;
553  case tov_FICaraway2: m_biomass_scale[a_tov] = 0.7857; break;
554  case tov_FieldPeasStrigling: m_biomass_scale[a_tov] = 0.857; break;
555  case tov_FIFabaBean: m_biomass_scale[a_tov] = 0.857; break;
556  case tov_FIFeedingGround: m_biomass_scale[a_tov] = 1.1; break;
557  case tov_FIGrasslandPasturePerennial1: m_biomass_scale[a_tov] = 1.1; break;
558  case tov_FIGrasslandPasturePerennial2: m_biomass_scale[a_tov] = 1.1; break;
559  case tov_FIGrasslandSilageAnnual: m_biomass_scale[a_tov] = 1.1; break;
560  case tov_FIGrasslandSilagePerennial1: m_biomass_scale[a_tov] = 1.1; break;
561  case tov_FIGrasslandSilagePerennial2: m_biomass_scale[a_tov] = 1.1; break;
562  case tov_FIGreenFallow_1year: m_biomass_scale[a_tov] = 1.1; break;
563  case tov_FIGreenFallow_Perm: m_biomass_scale[a_tov] = 1.1; break;
564  case tov_FINaturalGrassland: m_biomass_scale[a_tov] = 0.567; break; // actual yield
565  case tov_FINaturalGrassland_Perm: m_biomass_scale[a_tov] = 0.567; break; // actual yield
566  case tov_FIOCaraway1: m_biomass_scale[a_tov] = 0.7857; break;
567  case tov_FIOCaraway2: m_biomass_scale[a_tov] = 0.7857; break;
568  case tov_FIOFabaBean: m_biomass_scale[a_tov] = 0.857 * 0.8; break;
569  case tov_FIOPotato_North: m_biomass_scale[a_tov] = 0.857 * 0.8; break;
570  case tov_FIOPotato_South: m_biomass_scale[a_tov] = 0.857 * 0.8; break;
571  case tov_FIOPotatoIndustry_North: m_biomass_scale[a_tov] = 0.857 * 0.8; break;
572  case tov_FIOPotatoIndustry_South: m_biomass_scale[a_tov] = 0.857 * 0.8; break;
573  case tov_FIOSpringBarley_Fodder: m_biomass_scale[a_tov] = 0.857 * 0.8; break;
574  case tov_FIOSpringBarley_Malt: m_biomass_scale[a_tov] = 0.857 * 0.8; break;
575  case tov_FIOSpringOats: m_biomass_scale[a_tov] = 0.857 * 0.8; break;
576  case tov_FIOSpringRape: m_biomass_scale[a_tov] = 1.071 * 0.8; break;
577  case tov_FIOSpringWheat: m_biomass_scale[a_tov] = 1.0 * 0.8; break;
578  case tov_FIOStarchPotato_North: m_biomass_scale[a_tov] = 0.857 * 0.8; break;
579  case tov_FIOStarchPotato_South: m_biomass_scale[a_tov] = 0.857 * 0.8; break;
580  case tov_FIOTurnipRape: m_biomass_scale[a_tov] = 1.071 * 0.8; break;
581  case tov_FIOWinterRye: m_biomass_scale[a_tov] = 0.857 * 0.8; break;
582  case tov_FIOWinterWheat: m_biomass_scale[a_tov] = 1.0 * 0.8; break;
583  case tov_FIPotato_North: m_biomass_scale[a_tov] = 0.857; break;
584  case tov_FIPotato_South: m_biomass_scale[a_tov] = 0.857; break;
585  case tov_FIPotatoIndustry_North: m_biomass_scale[a_tov] = 0.857; break;
586  case tov_FIPotatoIndustry_South: m_biomass_scale[a_tov] = 0.857; break;
587  case tov_FISpringBarley_Fodder: m_biomass_scale[a_tov] = 0.857; break;
588  case tov_FISpringBarley_Malt: m_biomass_scale[a_tov] = 0.857; break;
589  case tov_FISpringOats: m_biomass_scale[a_tov] = 0.857; break;
590  case tov_FISpringRape: m_biomass_scale[a_tov] = 1.071; break;
591  case tov_FISpringWheat: m_biomass_scale[a_tov] = 1; break;
592  case tov_FISprSpringBarley_Fodder: m_biomass_scale[a_tov] = 0.857; break;
593  case tov_FIStarchPotato_North: m_biomass_scale[a_tov] = 0.857; break;
594  case tov_FIStarchPotato_South: m_biomass_scale[a_tov] = 0.857; break;
595  case tov_FISugarBeet: m_biomass_scale[a_tov] = 0.857; break;
596  case tov_FITurnipRape: m_biomass_scale[a_tov] = 1.071; break;
597  case tov_FIWinterRye: m_biomass_scale[a_tov] = 0.857; break;
598  case tov_FIWinterWheat: m_biomass_scale[a_tov] = 1; break;
599  case tov_FlowerStrip1: m_biomass_scale[a_tov] = 0.567; break; //0.567 low yield
600  case tov_FlowerStrip2: m_biomass_scale[a_tov] = 0.676; break; //
601  case tov_FlowerStrip3: m_biomass_scale[a_tov] = 0.7857; break; // high yield
602  case tov_FodderBeet: m_biomass_scale[a_tov] = 0.857; break;
603  case tov_FodderGrass: m_biomass_scale[a_tov] = 1.2; break;
604  case tov_FRGrassland: m_biomass_scale[a_tov] = 1.1; break;
605  case tov_FRGrassland_Perm: m_biomass_scale[a_tov] = 1.1; break;
606  case tov_FRMaize: m_biomass_scale[a_tov] = 1; break;
607  case tov_FRMaize_Silage: m_biomass_scale[a_tov] = 1; break;
608  case tov_FRPotatoes: m_biomass_scale[a_tov] = 0.857; break;
609  case tov_FRSorghum: m_biomass_scale[a_tov] = 1; break; // should be similar to maize
610  case tov_FRSpringBarley: m_biomass_scale[a_tov] = 0.857; break;
611  case tov_FRSpringOats: m_biomass_scale[a_tov] = 0.857; break;
612  case tov_FRSpringWheat: m_biomass_scale[a_tov] = 1; break;
613  case tov_FRSunflower: m_biomass_scale[a_tov] = 1; break; // need to check this
614  case tov_FRWinterBarley: m_biomass_scale[a_tov] = 0.857; break;
615  case tov_FRWinterRape: m_biomass_scale[a_tov] = 1.071; break;
616  case tov_FRWinterTriticale: m_biomass_scale[a_tov] = 1; break;
617  case tov_FRWinterWheat: m_biomass_scale[a_tov] = 1; break;
618  case tov_Heath: m_biomass_scale[a_tov] = 0.567; break; //0.567 is scaled for actual yield
619  case tov_IRGrassland_no_reseed: m_biomass_scale[a_tov] = 1.1; break;
620  case tov_IRGrassland_reseed: m_biomass_scale[a_tov] = 1.1; break;
621  case tov_IRSpringBarley: m_biomass_scale[a_tov] = 0.857; break;
622  case tov_IRSpringOats: m_biomass_scale[a_tov] = 0.857; break;
623  case tov_IRSpringWheat: m_biomass_scale[a_tov] = 1; break;
624  case tov_IRWinterBarley: m_biomass_scale[a_tov] = 1; break;
625  case tov_IRWinterOats: m_biomass_scale[a_tov] = 0.857; break;
626  case tov_IRWinterWheat: m_biomass_scale[a_tov] = 1; break;
627  case tov_ITGrassland: m_biomass_scale[a_tov] = 1.1; break;
628  case tov_ITOOrchard: m_biomass_scale[a_tov] = 0.7857 * 0.8; break;
629  case tov_ITOrchard: m_biomass_scale[a_tov] = 0.7857; break;
630  case tov_Lawn: m_biomass_scale[a_tov] = 0.5; break;
631  case tov_Maize: m_biomass_scale[a_tov] = 1; break;
632  case tov_MaizeSilage: m_biomass_scale[a_tov] = 1; break;
633  case tov_MaizeStrigling: m_biomass_scale[a_tov] = 0.857; break;
634  case tov_NaturalGrass: m_biomass_scale[a_tov] = 0.567; break; //0.567 is scaled for actual yield
635  case tov_NLBeet: m_biomass_scale[a_tov] = 0.857; break;
636  case tov_NLBeetSpring: m_biomass_scale[a_tov] = 0.857; break;
637  case tov_NLCabbage: m_biomass_scale[a_tov] = 0.7857; break;
638  case tov_NLCabbageSpring: m_biomass_scale[a_tov] = 0.7857; break;
639  case tov_NLCarrots: m_biomass_scale[a_tov] = 0.7857; break;
640  case tov_NLCarrotsSpring: m_biomass_scale[a_tov] = 0.7857; break;
641  case tov_NLCatchCropPea: m_biomass_scale[a_tov] = 0.857; break;
642  case tov_NLGrassGrazed1: m_biomass_scale[a_tov] = 1.2; break;
643  case tov_NLGrassGrazed1Spring: m_biomass_scale[a_tov] = 1.2; break;
644  case tov_NLGrassGrazed2: m_biomass_scale[a_tov] = 1.2; break;
645  case tov_NLGrassGrazedExtensive1: m_biomass_scale[a_tov] = 1.2; break;
646  case tov_NLGrassGrazedExtensive1Spring: m_biomass_scale[a_tov] = 1.2; break;
647  case tov_NLGrassGrazedExtensive2: m_biomass_scale[a_tov] = 1.2; break;
648  case tov_NLGrassGrazedExtensiveLast: m_biomass_scale[a_tov] = 1.2; break;
649  case tov_NLGrassGrazedLast: m_biomass_scale[a_tov] = 1.2; break;
650  case tov_NLMaize: m_biomass_scale[a_tov] = 1; break;
651  case tov_NLMaizeSpring: m_biomass_scale[a_tov] = 1; break;
652  case tov_NLOrchardCrop: m_biomass_scale[a_tov] = 0.7857; break;
653  case tov_NLPermanentGrassGrazed: m_biomass_scale[a_tov] = 1.1; break;
654  case tov_NLPermanentGrassGrazedExtensive: m_biomass_scale[a_tov] = 1.1; break;
655  case tov_NLPotatoes: m_biomass_scale[a_tov] = 0.857; break;
656  case tov_NLPotatoesSpring: m_biomass_scale[a_tov] = 0.857; break;
657  case tov_NLSpringBarley: m_biomass_scale[a_tov] = 0.857; break;
658  case tov_NLSpringBarleySpring: m_biomass_scale[a_tov] = 0.857; break;
659  case tov_NLTulips: m_biomass_scale[a_tov] = 0.7857; break;
660  case tov_NLWinterWheat: m_biomass_scale[a_tov] = 1; break;
661  case tov_NoGrowth: m_biomass_scale[a_tov] = 0; break;
662  case tov_None: m_biomass_scale[a_tov] = 0; break;
663  case tov_NorwegianOats: m_biomass_scale[a_tov] = 0.857; break;
664  case tov_NorwegianSpringBarley: m_biomass_scale[a_tov] = 0.857; break;
665  case tov_NorwegianPotatoes: m_biomass_scale[a_tov] = 0.857; break;
666  case tov_Oats: m_biomass_scale[a_tov] = 0.857; break;
667  case tov_OBarleyPeaCloverGrass: m_biomass_scale[a_tov] = 0.857; break;
668  case tov_OCarrots: m_biomass_scale[a_tov] = 0.7857 * 0.8; break;
669  case tov_OCloverGrassGrazed1: m_biomass_scale[a_tov] = 1.1; break;
670  case tov_OCloverGrassGrazed2: m_biomass_scale[a_tov] = 1.1; break;
671  case tov_OCloverGrassSilage1: m_biomass_scale[a_tov] = 1.1; break;
672  case tov_OFieldPeas: m_biomass_scale[a_tov] = 0.857 * 0.8; break;
673  case tov_OFieldPeasSilage: m_biomass_scale[a_tov] = 0.857 * 0.8; break;
674  case tov_OFirstYearDanger: m_biomass_scale[a_tov] = 0; break;
675  case tov_OFodderBeet: m_biomass_scale[a_tov] = 0.857; break;
676  case tov_OGrazingPigs: m_biomass_scale[a_tov] = 0.7857 * 0.8; break;
677  case tov_OMaizeSilage: m_biomass_scale[a_tov] = 1; break;
678  case tov_OOats: m_biomass_scale[a_tov] = 0.857 * 0.8; break;
679  case tov_OPermanentGrassGrazed: m_biomass_scale[a_tov] = 0.7857; break;
680  case tov_OPotatoes: m_biomass_scale[a_tov] = 0.857 * 0.8; break;
681  case tov_OrchardCrop: m_biomass_scale[a_tov] = 0.7857; break;
682  case tov_OSBarleySilage: m_biomass_scale[a_tov] = 0.857 * 0.8; break;
683  case tov_OSeedGrass1: m_biomass_scale[a_tov] = 0.7857; break;
684  case tov_OSeedGrass2: m_biomass_scale[a_tov] = 0.7857; break;
685  case tov_OSetAside: m_biomass_scale[a_tov] = 0.7857; break;
686  case tov_OSpringBarley: m_biomass_scale[a_tov] = 0.857 * 0.8; break;
687  case tov_OSpringBarleyClover: m_biomass_scale[a_tov] = 0.857 * 0.8; break;
688  case tov_OSpringBarleyExt: m_biomass_scale[a_tov] = 0.857 * 0.8 * 0.8; break;
689  case tov_OSpringBarleyGrass: m_biomass_scale[a_tov] = 0.857 * 0.8; break;
690  case tov_OSpringBarleyPigs: m_biomass_scale[a_tov] = 0.857 * 0.8; break;
691  case tov_OTriticale: m_biomass_scale[a_tov] = 1.00 * 0.8; break;
692  case tov_OWinterBarley: m_biomass_scale[a_tov] = 0.857 * 0.8; break;
693  case tov_OWinterBarleyExt: m_biomass_scale[a_tov] = 0.857 * 0.8 * 0.8; break;
694  case tov_OWinterRape: m_biomass_scale[a_tov] = 1.071 * 0.8; break;
695  case tov_OWinterRye: m_biomass_scale[a_tov] = 0.857 * 0.8; break;
696  case tov_PermanentGrassGrazed: m_biomass_scale[a_tov] = 1.1; break;
697  case tov_PermanentGrassLowYield: m_biomass_scale[a_tov] = 1; break;
698  case tov_PermanentGrassTussocky: m_biomass_scale[a_tov] = 0.7857; break;
699  case tov_PermanentSetAside: m_biomass_scale[a_tov] = 0.7857; break;
700  case tov_PlantNursery: m_biomass_scale[a_tov] = 0.1; break;
701  case tov_PLBeans: m_biomass_scale[a_tov] = 0.857; break;
702  case tov_PLBeet: m_biomass_scale[a_tov] = 0.857; break;
703  case tov_PLBeetSpr: m_biomass_scale[a_tov] = 0.857; break;
704  case tov_PLCarrots: m_biomass_scale[a_tov] = 0.7857; break;
705  case tov_PLFodderLucerne1: m_biomass_scale[a_tov] = 1.2; break;
706  case tov_PLFodderLucerne2: m_biomass_scale[a_tov] = 1.2; break;
707  case tov_PLMaize: m_biomass_scale[a_tov] = 1; break;
708  case tov_PLMaizeSilage: m_biomass_scale[a_tov] = 1; break;
709  case tov_PLPotatoes: m_biomass_scale[a_tov] = 0.857; break;
710  case tov_PLSpringBarley: m_biomass_scale[a_tov] = 0.857; break;
711  case tov_PLSpringBarleySpr: m_biomass_scale[a_tov] = 0.857; break;
712  case tov_PLSpringWheat: m_biomass_scale[a_tov] = 1; break;
713  case tov_PLWinterBarley: m_biomass_scale[a_tov] = 0.857; break;
714  case tov_PLWinterRape: m_biomass_scale[a_tov] = 1.071; break;
715  case tov_PLWinterRye: m_biomass_scale[a_tov] = 0.857; break;
716  case tov_PLWinterTriticale: m_biomass_scale[a_tov] = 1; break;
717  case tov_PLWinterWheat: m_biomass_scale[a_tov] = 1; break;
718  case tov_PLWinterWheatLate: m_biomass_scale[a_tov] = 1; break;
719  case tov_Potatoes: m_biomass_scale[a_tov] = 0.857; break;
720  case tov_PotatoesIndustry: m_biomass_scale[a_tov] = 0.857; break;
721  case tov_PTBeans: m_biomass_scale[a_tov] = 0.857; break;
722  case tov_PTCabbage: m_biomass_scale[a_tov] = 0.857; break;
723  case tov_PTCabbage_Hort: m_biomass_scale[a_tov] = 0.857; break;
724  case tov_PTCloverGrassGrazed1: m_biomass_scale[a_tov] = 1.2; break;
725  case tov_PTCloverGrassGrazed2: m_biomass_scale[a_tov] = 1.2; break;
726  case tov_PTCorkOak: m_biomass_scale[a_tov] = 0.7857; break;
727  case tov_PTFodderMix: m_biomass_scale[a_tov] = 1.2; break;
728  case tov_PTGrassGrazed: m_biomass_scale[a_tov] = 1.2; break;
729  case tov_PTHorticulture: m_biomass_scale[a_tov] = 0.857; break;
730  case tov_PTMaize: m_biomass_scale[a_tov] = 1; break;
731  case tov_PTMaize_Hort: m_biomass_scale[a_tov] = 1; break;
732  case tov_PTOats: m_biomass_scale[a_tov] = 0.857; break;
733  case tov_PTOliveGroveIntensive: m_biomass_scale[a_tov] = 0.7857; break;
734  case tov_PTOliveGroveSuperIntensive: m_biomass_scale[a_tov] = 0.7857; break;
735  case tov_PTOliveGroveTraditional: m_biomass_scale[a_tov] = 0.7857; break;
736  case tov_PTOliveGroveTradOrganic: m_biomass_scale[a_tov] = 0.7857; break;
737  case tov_PTOtherDryBeans: m_biomass_scale[a_tov] = 0.857; break;
738  case tov_PTPermanentGrassGrazed: m_biomass_scale[a_tov] = 1.1; break;
739  case tov_PTPotatoes: m_biomass_scale[a_tov] = 0.857; break;
740  case tov_PTRyegrass: m_biomass_scale[a_tov] = 1.2; break;
741  case tov_PTShrubPastures: m_biomass_scale[a_tov] = 0.567; break;
742  case tov_PTSorghum: m_biomass_scale[a_tov] = 1; break;
743  case tov_PTTriticale: m_biomass_scale[a_tov] = 1; break;
744  case tov_PTTurnipGrazed: m_biomass_scale[a_tov] = 0.7857; break;
745  case tov_PTVineyards: m_biomass_scale[a_tov] = 0.7857; break;
746  case tov_PTWinterBarley: m_biomass_scale[a_tov] = 1; break;
747  case tov_PTWinterRye: m_biomass_scale[a_tov] = 0.857; break;
748  case tov_PTWinterWheat: m_biomass_scale[a_tov] = 1; break;
749  case tov_PTYellowLupin: m_biomass_scale[a_tov] = 1.2; break;
750  case tov_PTSetAside: m_biomass_scale[a_tov] = 0.7857; break;
751  case tov_SeedGrass1: m_biomass_scale[a_tov] = 0.7857; break;
752  case tov_SeedGrass2: m_biomass_scale[a_tov] = 0.7857; break;
753  case tov_SESpringBarley: m_biomass_scale[a_tov] = 0.857; break;
754  case tov_SetAside: m_biomass_scale[a_tov] = 0.7857; break;
755  case tov_SEWinterRape_Seed: m_biomass_scale[a_tov] = 1.071; break;
756  case tov_SEWinterWheat: m_biomass_scale[a_tov] = 1; break;
757  case tov_SpringBarley: m_biomass_scale[a_tov] = 0.857; break;
758  case tov_SpringBarleyCloverGrass: m_biomass_scale[a_tov] = 0.857; break;
759  case tov_SpringBarleyCloverGrassStrigling: m_biomass_scale[a_tov] = 0.857; break;
760  case tov_SpringBarleyGrass: m_biomass_scale[a_tov] = 0.857; break;
761  case tov_SpringBarleyPeaCloverGrassStrigling: m_biomass_scale[a_tov] = 0.857; break;
762  case tov_SpringBarleyPTreatment: m_biomass_scale[a_tov] = 0.857; break;
763  case tov_SpringBarleySeed: m_biomass_scale[a_tov] = 0.857; break;
764  case tov_SpringBarleySilage: m_biomass_scale[a_tov] = 0.857; break;
765  case tov_SpringBarleySKManagement: m_biomass_scale[a_tov] = 0.857; break;
766  case tov_SpringBarleySpr: m_biomass_scale[a_tov] = 0.857; break;
767  case tov_SpringBarleyStrigling: m_biomass_scale[a_tov] = 0.857; break;
768  case tov_SpringBarleyStriglingCulm: m_biomass_scale[a_tov] = 0.857; break;
769  case tov_SpringBarleyStriglingSingle: m_biomass_scale[a_tov] = 0.857; break;
770  case tov_SpringRape: m_biomass_scale[a_tov] = 1.071; break;
771  case tov_SpringWheat: m_biomass_scale[a_tov] = 1; break;
772  case tov_SugarBeet: m_biomass_scale[a_tov] = 0.857; break;
773  case tov_Triticale: m_biomass_scale[a_tov] = 1; break;
774  case tov_UKBeans: m_biomass_scale[a_tov] = 0.857; break;
775  case tov_UKBeet: m_biomass_scale[a_tov] = 0.857; break;
776  case tov_UKMaize: m_biomass_scale[a_tov] = 1; break;
777  case tov_UKPermanentGrass: m_biomass_scale[a_tov] = 1.1; break;
778  case tov_UKPotatoes: m_biomass_scale[a_tov] = 0.857; break;
779  case tov_UKSpringBarley: m_biomass_scale[a_tov] = 0.857; break;
780  case tov_UKTempGrass: m_biomass_scale[a_tov] = 1.2; break;
781  case tov_UKWinterBarley: m_biomass_scale[a_tov] = 0.857; break;
782  case tov_UKWinterRape: m_biomass_scale[a_tov] = 1.071; break;
783  case tov_UKWinterWheat: m_biomass_scale[a_tov] = 1; break;
784  case tov_Wasteland: m_biomass_scale[a_tov] = 0.7857 * 0.67; break;
785  case tov_WaterBufferZone: m_biomass_scale[a_tov] = 0.567; break;
786  case tov_WinterBarley: m_biomass_scale[a_tov] = 0.857; break;
787  case tov_WinterBarleyStrigling: m_biomass_scale[a_tov] = 0.857; break;
788  case tov_WinterRape: m_biomass_scale[a_tov] = 1.071; break;
789  case tov_WinterRapeStrigling: m_biomass_scale[a_tov] = 1.071; break;
790  case tov_WinterRye: m_biomass_scale[a_tov] = 0.857; break;
791  case tov_WinterRyeStrigling: m_biomass_scale[a_tov] = 0.857; break;
792  case tov_WinterWheat: m_biomass_scale[a_tov] = 1; break; // This gives approx 18 tonnes biomass for WW
793  case tov_WinterWheatShort: m_biomass_scale[a_tov] = 1; break;
794  case tov_WinterWheatStrigling: m_biomass_scale[a_tov] = 1; break;
795  case tov_WinterWheatStriglingCulm: m_biomass_scale[a_tov] = 1; break;
796  case tov_WinterWheatStriglingSingle: m_biomass_scale[a_tov] = 1; break;
797  case tov_WWheatPControl: m_biomass_scale[a_tov] = 1; break;
798  case tov_WWheatPToxicControl: m_biomass_scale[a_tov] = 1; break;
799  case tov_WWheatPTreatment: m_biomass_scale[a_tov] = 1; break;
800  case tov_YoungForest: m_biomass_scale[a_tov] = 0.7857 * 0.67; break;
801 
802  case tov_Undefined: m_biomass_scale[a_tov] = 0; break;
803  }
804 }

References tov_AgroChemIndustryCereal, tov_BEBeet, tov_BEBeetSpring, tov_BECatchPeaCrop, tov_BEGrassGrazed1, tov_BEGrassGrazed1Spring, tov_BEGrassGrazed2, tov_BEGrassGrazedLast, tov_BEMaize, tov_BEMaizeCC, tov_BEMaizeSpring, tov_BEOrchardCrop, tov_BEPotatoes, tov_BEPotatoesSpring, tov_BEWinterBarley, tov_BEWinterBarleyCC, tov_BEWinterWheat, tov_BEWinterWheatCC, tov_BroadBeans, tov_Carrots, tov_CloverGrassGrazed1, tov_CloverGrassGrazed2, tov_DEAsparagusEstablishedPlantation, tov_DEBushFruitPerm, tov_DECabbage, tov_DECarrots, tov_DEGrasslandSilageAnnual, tov_DEGreenFallow_1year, tov_DEHerbsPerennial_1year, tov_DEHerbsPerennial_after1year, tov_DELegumes, tov_DEMaize, tov_DEMaizeSilage, tov_DEOAsparagusEstablishedPlantation, tov_DEOats, tov_DEOBushFruitPerm, tov_DEOCabbages, tov_DEOCarrots, tov_DEOGrasslandSilageAnnual, tov_DEOGreenFallow_1year, tov_DEOHerbsPerennial_1year, tov_DEOHerbsPerennial_after1year, tov_DEOLegume, tov_DEOMaize, tov_DEOMaizeSilage, tov_DEOOats, tov_DEOOrchard, tov_DEOPeas, tov_DEOPermanentGrassGrazed, tov_DEOPermanentGrassLowYield, tov_DEOPotatoes, tov_DEOrchard, tov_DEOSpringRye, tov_DEOSugarBeet, tov_DEOTriticale, tov_DEOWinterBarley, tov_DEOWinterRape, tov_DEOWinterRye, tov_DEOWinterWheat, tov_DEPeas, tov_DEPermanentGrassGrazed, tov_DEPermanentGrassLowYield, tov_DEPotatoes, tov_DEPotatoesIndustry, tov_DESpringBarley, tov_DESpringRye, tov_DESugarBeet, tov_DETriticale, tov_DEWinterBarley, tov_DEWinterRape, tov_DEWinterRye, tov_DEWinterWheat, tov_DEWinterWheatLate, tov_DKBushFruit_Perm1, tov_DKBushFruit_Perm2, tov_DKCabbages, tov_DKCarrots, tov_DKCatchCrop, tov_DKCerealLegume, tov_DKCerealLegume_Whole, tov_DKChristmasTrees_Perm, tov_DKCloverGrassGrazed1, tov_DKCloverGrassGrazed2, tov_DKCloverGrassGrazed3, tov_DKEnergyCrop_Perm, tov_DKFarmForest_Perm, tov_DKFarmYoungForest_Perm, tov_DKFodderBeets, tov_DKGrassGrazed_Perm, tov_DKGrassLowYield_Perm, tov_DKGrassTussocky_Perm, tov_DKGrazingPigs, tov_DKGrazingPigs_Perm, tov_DKLegume_Beans, tov_DKLegume_Peas, tov_DKLegume_Whole, tov_DKMaize, tov_DKMaizeSilage, tov_DKMixedVeg, tov_DKOBushFruit_Perm1, tov_DKOBushFruit_Perm2, tov_DKOCabbages, tov_DKOCarrots, tov_DKOCatchCrop, tov_DKOCerealLegume, tov_DKOCerealLegume_Whole, tov_DKOChristmasTrees_Perm, tov_DKOCloverGrassGrazed1, tov_DKOCloverGrassGrazed2, tov_DKOCloverGrassGrazed3, tov_DKOEnergyCrop_Perm, tov_DKOFarmForest_Perm, tov_DKOFarmYoungForest_Perm, tov_DKOFodderBeets, tov_DKOGrassGrazed_Perm, tov_DKOGrassLowYield_Perm, tov_DKOGrazingPigs, tov_DKOGrazingPigs_Perm, tov_DKOLegume_Beans, tov_DKOLegume_Beans_CC, tov_DKOLegume_Peas, tov_DKOLegume_Peas_CC, tov_DKOLegume_Whole, tov_DKOLegume_Whole_CC, tov_DKOLegumeCloverGrass_Whole, tov_DKOLentils, tov_DKOLupines, tov_DKOMaize, tov_DKOMaizeSilage, tov_DKOMixedVeg, tov_DKOOrchApple, tov_DKOOrchardCrop_Perm, tov_DKOOrchCherry, tov_DKOOrchOther, tov_DKOOrchPear, tov_DKOPotato, tov_DKOPotatoIndustry, tov_DKOPotatoSeed, tov_DKOptimalFlowerMix1, tov_DKOptimalFlowerMix2, tov_DKOptimalFlowerMix3, tov_DKOrchApple, tov_DKOrchardCrop_Perm, tov_DKOrchCherry, tov_DKOrchOther, tov_DKOrchPear, tov_DKOSeedGrassRye_Spring, tov_DKOSetAside, tov_DKOSetAside_AnnualFlower, tov_DKOSetAside_PerennialFlower, tov_DKOSetAside_SummerMow, tov_DKOSpringBarley, tov_DKOSpringBarley_CC, tov_DKOSpringBarleyCloverGrass, tov_DKOSpringBarleySilage, tov_DKOSpringFodderGrass, tov_DKOSpringOats, tov_DKOSpringOats_CC, tov_DKOSpringWheat, tov_DKOSugarBeets, tov_DKOVegSeeds, tov_DKOWinterBarley, tov_DKOWinterCloverGrassGrazedSown, tov_DKOWinterFodderGrass, tov_DKOWinterRape, tov_DKOWinterRye, tov_DKOWinterRye_CC, tov_DKOWinterWheat, tov_DKOWinterWheat_CC, tov_DKPlantNursery_Perm, tov_DKPotato, tov_DKPotatoIndustry, tov_DKPotatoSeed, tov_DKSeedGrassFescue_Spring, tov_DKSeedGrassRye_Spring, tov_DKSetAside, tov_DKSetAside_SummerMow, tov_DKSpringBarley, tov_DKSpringBarley_CC, tov_DKSpringBarley_Green, tov_DKSpringBarleyCloverGrass, tov_DKSpringBarleySilage, tov_DKSpringFodderGrass, tov_DKSpringOats, tov_DKSpringOats_CC, tov_DKSpringWheat, tov_DKSugarBeets, tov_DKUndefined, tov_DKVegSeeds, tov_DKWinterBarley, tov_DKWinterCloverGrassGrazedSown, tov_DKWinterFodderGrass, tov_DKWinterRape, tov_DKWinterRye, tov_DKWinterRye_CC, tov_DKWinterWheat, tov_DKWinterWheat_CC, tov_FIBufferZone, tov_FIBufferZone_Perm, tov_FICaraway1, tov_FICaraway2, tov_FieldPeas, tov_FieldPeasSilage, tov_FieldPeasStrigling, tov_FIFabaBean, tov_FIFeedingGround, tov_FIGrasslandPasturePerennial1, tov_FIGrasslandPasturePerennial2, tov_FIGrasslandSilageAnnual, tov_FIGrasslandSilagePerennial1, tov_FIGrasslandSilagePerennial2, tov_FIGreenFallow_1year, tov_FIGreenFallow_Perm, tov_FINaturalGrassland, tov_FINaturalGrassland_Perm, tov_FIOCaraway1, tov_FIOCaraway2, tov_FIOFabaBean, tov_FIOPotato_North, tov_FIOPotato_South, tov_FIOPotatoIndustry_North, tov_FIOPotatoIndustry_South, tov_FIOSpringBarley_Fodder, tov_FIOSpringBarley_Malt, tov_FIOSpringOats, tov_FIOSpringRape, tov_FIOSpringWheat, tov_FIOStarchPotato_North, tov_FIOStarchPotato_South, tov_FIOTurnipRape, tov_FIOWinterRye, tov_FIOWinterWheat, tov_FIPotato_North, tov_FIPotato_South, tov_FIPotatoIndustry_North, tov_FIPotatoIndustry_South, tov_FISpringBarley_Fodder, tov_FISpringBarley_Malt, tov_FISpringOats, tov_FISpringRape, tov_FISpringWheat, tov_FISprSpringBarley_Fodder, tov_FIStarchPotato_North, tov_FIStarchPotato_South, tov_FISugarBeet, tov_FITurnipRape, tov_FIWinterRye, tov_FIWinterWheat, tov_FlowerStrip1, tov_FlowerStrip2, tov_FlowerStrip3, tov_FodderBeet, tov_FodderGrass, tov_FRGrassland, tov_FRGrassland_Perm, tov_FRMaize, tov_FRMaize_Silage, tov_FRPotatoes, tov_FRSorghum, tov_FRSpringBarley, tov_FRSpringOats, tov_FRSpringWheat, tov_FRSunflower, tov_FRWinterBarley, tov_FRWinterRape, tov_FRWinterTriticale, tov_FRWinterWheat, tov_GenericCatchCrop, tov_Heath, tov_IRGrassland_no_reseed, tov_IRGrassland_reseed, tov_IRSpringBarley, tov_IRSpringOats, tov_IRSpringWheat, tov_IRWinterBarley, tov_IRWinterOats, tov_IRWinterWheat, tov_ITGrassland, tov_ITOOrchard, tov_ITOrchard, tov_Lawn, tov_Maize, tov_MaizeSilage, tov_MaizeStrigling, tov_NaturalGrass, tov_NLBeet, tov_NLBeetSpring, tov_NLCabbage, tov_NLCabbageSpring, tov_NLCarrots, tov_NLCarrotsSpring, tov_NLCatchCropPea, tov_NLGrassGrazed1, tov_NLGrassGrazed1Spring, tov_NLGrassGrazed2, tov_NLGrassGrazedExtensive1, tov_NLGrassGrazedExtensive1Spring, tov_NLGrassGrazedExtensive2, tov_NLGrassGrazedExtensiveLast, tov_NLGrassGrazedLast, tov_NLMaize, tov_NLMaizeSpring, tov_NLOrchardCrop, tov_NLPermanentGrassGrazed, tov_NLPermanentGrassGrazedExtensive, tov_NLPotatoes, tov_NLPotatoesSpring, tov_NLSpringBarley, tov_NLSpringBarleySpring, tov_NLTulips, tov_NLWinterWheat, tov_NoGrowth, tov_None, tov_NorwegianOats, tov_NorwegianPotatoes, tov_NorwegianSpringBarley, tov_Oats, tov_OBarleyPeaCloverGrass, tov_OCarrots, tov_OCloverGrassGrazed1, tov_OCloverGrassGrazed2, tov_OCloverGrassSilage1, tov_OFieldPeas, tov_OFieldPeasSilage, tov_OFirstYearDanger, tov_OFodderBeet, tov_OGrazingPigs, tov_OMaizeSilage, tov_OOats, tov_OPermanentGrassGrazed, tov_OPotatoes, tov_OrchardCrop, tov_OSBarleySilage, tov_OSeedGrass1, tov_OSeedGrass2, tov_OSetAside, tov_OSpringBarley, tov_OSpringBarleyClover, tov_OSpringBarleyExt, tov_OSpringBarleyGrass, tov_OSpringBarleyPigs, tov_OTriticale, tov_OWinterBarley, tov_OWinterBarleyExt, tov_OWinterRape, tov_OWinterRye, tov_OWinterWheat, tov_OWinterWheatUndersown, tov_OWinterWheatUndersownExt, tov_PermanentGrassGrazed, tov_PermanentGrassLowYield, tov_PermanentGrassTussocky, tov_PermanentSetAside, tov_PlantNursery, tov_PLBeans, tov_PLBeet, tov_PLBeetSpr, tov_PLCarrots, tov_PLFodderLucerne1, tov_PLFodderLucerne2, tov_PLMaize, tov_PLMaizeSilage, tov_PLPotatoes, tov_PLSpringBarley, tov_PLSpringBarleySpr, tov_PLSpringWheat, tov_PLWinterBarley, tov_PLWinterRape, tov_PLWinterRye, tov_PLWinterTriticale, tov_PLWinterWheat, tov_PLWinterWheatLate, tov_Potatoes, tov_PotatoesIndustry, tov_PTBeans, tov_PTCabbage, tov_PTCabbage_Hort, tov_PTCloverGrassGrazed1, tov_PTCloverGrassGrazed2, tov_PTCorkOak, tov_PTFodderMix, tov_PTGrassGrazed, tov_PTHorticulture, tov_PTMaize, tov_PTMaize_Hort, tov_PTOats, tov_PTOliveGroveIntensive, tov_PTOliveGroveSuperIntensive, tov_PTOliveGroveTraditional, tov_PTOliveGroveTradOrganic, tov_PTOtherDryBeans, tov_PTPermanentGrassGrazed, tov_PTPotatoes, tov_PTRyegrass, tov_PTSetAside, tov_PTShrubPastures, tov_PTSorghum, tov_PTTriticale, tov_PTTurnipGrazed, tov_PTVineyards, tov_PTWinterBarley, tov_PTWinterRye, tov_PTWinterWheat, tov_PTYellowLupin, tov_SeedGrass1, tov_SeedGrass2, tov_SESpringBarley, tov_SetAside, tov_SEWinterRape_Seed, tov_SEWinterWheat, tov_SpringBarley, tov_SpringBarleyCloverGrass, tov_SpringBarleyCloverGrassStrigling, tov_SpringBarleyGrass, tov_SpringBarleyPeaCloverGrassStrigling, tov_SpringBarleyPTreatment, tov_SpringBarleySeed, tov_SpringBarleySilage, tov_SpringBarleySKManagement, tov_SpringBarleySpr, tov_SpringBarleyStrigling, tov_SpringBarleyStriglingCulm, tov_SpringBarleyStriglingSingle, tov_SpringRape, tov_SpringWheat, tov_SugarBeet, tov_Triticale, tov_UKBeans, tov_UKBeet, tov_UKMaize, tov_UKPermanentGrass, tov_UKPotatoes, tov_UKSpringBarley, tov_UKTempGrass, tov_UKWinterBarley, tov_UKWinterRape, tov_UKWinterWheat, tov_Undefined, tov_Wasteland, tov_WaterBufferZone, tov_WinterBarley, tov_WinterBarleyStrigling, tov_WinterRape, tov_WinterRapeStrigling, tov_WinterRye, tov_WinterRyeStrigling, tov_WinterWheat, tov_WinterWheatShort, tov_WinterWheatStrigling, tov_WinterWheatStriglingCulm, tov_WinterWheatStriglingSingle, tov_WWheatPControl, tov_WWheatPToxicControl, tov_WWheatPTreatment, and tov_YoungForest.

Referenced by Landscape::Landscape().

◆ SetCropData()

void VegElement::SetCropData ( double  a_veg_height,
double  a_LAtotal,
double  a_LAgreen,
TTypesOfVegetation  a_veg,
double  a_cover,
int  a_grazed 
)
virtual

Reimplemented from LE.

2815  {
2816  m_veg_height = a_veg_height;
2817  m_LAtotal = a_LAtotal;
2818  m_LAgreen = a_LAgreen;
2819  m_vege_type = a_veg;
2820  m_veg_cover = a_cover;
2821  m_cattle_grazing = a_grazed;
2822 }

References LE::m_cattle_grazing, m_LAgreen, m_LAtotal, m_veg_cover, m_veg_height, and m_vege_type.

◆ SetCropDataAll()

void VegElement::SetCropDataAll ( double  a_veg_height,
double  a_biomass,
double  a_LAtotal,
double  a_LAgreen,
TTypesOfVegetation  a_veg,
double  a_wb,
double  a_cover,
int  a_grazed,
double  a_ins,
bool  a_patchy,
double  a_dens,
double  a_deadbiomass,
double  a_greenbiomass 
)
virtual

Reimplemented from LE.

2825  {
2826  m_veg_height = a_veg_height;
2827  m_veg_biomass = a_biomass;
2828  m_LAtotal = a_LAtotal;
2829  m_LAgreen = a_LAgreen;
2830  m_vege_type = a_veg;
2831  m_weed_biomass = a_wb;
2832  m_veg_cover = a_cover;
2833  m_cattle_grazing = a_grazed;
2834  m_insect_pop = a_ins;
2835  m_veg_density = (int) a_dens;
2836  m_att_veg_patchy = a_patchy;
2837  m_dead_biomass = a_deadbiomass;
2838  m_green_biomass = a_greenbiomass;
2839  // set the veg attributes
2840  GetLandscape()->Set_TOV_Att(this);
2841 }

References m_att_veg_patchy, LE::m_cattle_grazing, m_dead_biomass, m_green_biomass, m_insect_pop, m_LAgreen, m_LAtotal, m_veg_biomass, m_veg_cover, m_veg_density, m_veg_height, m_vege_type, and m_weed_biomass.

◆ SetCropType()

virtual void VegElement::SetCropType ( TTypesOfCrops  a_type)
inlinevirtual
722  {
723  m_CropType = a_type;
725  switch(a_type){
726  case toc_GrassGrazed1:
727  case toc_GrassGrazed2:
729  case toc_GrassGrazedLast:
736  case toc_FodderGrass:
737  case toc_OFodderGrass:
739  break;
743  break;
747  break;
750  break;
751  default:
752  SetGrazingLevel(0);
753  }
754  }

References cfg_farm_cattle_grazing_lvl_lowyield, cfg_farm_cattle_grazing_lvl_pasture, cfg_farm_cattle_grazing_lvl_rot, cfg_farm_cattle_grazing_lvl_tussocky, LE::m_CropType, SetGrazingLevel(), SetInsectBiomassParametersIndex(), toc_CloverGrassGrazed1, toc_CloverGrassGrazed2, toc_CloverGrassGrazed3, toc_FodderGrass, toc_GrassGrazed1, toc_GrassGrazed2, toc_GrassGrazedExtensive, toc_GrassGrazedLast, toc_OCloverGrassGrazed1, toc_OCloverGrassGrazed2, toc_OCloverGrassGrazed3, toc_OFodderGrass, toc_OPermanentGrassGrazed, toc_OPermanentGrassLowYield, toc_PermanentGrassGrazed, toc_PermanentGrassLowYield, toc_PermanentGrassTussocky, and CfgInt::value().

◆ SetDigestibility()

virtual void VegElement::SetDigestibility ( double  a_digestability)
inlinevirtual

Reimplemented from LE.

815 { m_digestability = a_digestability; }

References m_digestability.

Referenced by PermanentSetaside::PermanentSetaside().

◆ SetGrazingLevel()

virtual void VegElement::SetGrazingLevel ( int  a_grazing)
inlinevirtual

Reimplemented from LE.

816 { m_default_grazing_level = a_grazing; }

References LE::m_default_grazing_level.

Referenced by Field::Field(), and SetCropType().

◆ SetGrowthPhase()

void VegElement::SetGrowthPhase ( int  a_phase)
virtual

If it is the first growth phase of the year then we might cause some unnecessary hops if e.g. our biomass is 0 and we suddenly jump up to 20 cm To stop this happening we check here and if our settings are lower than the targets we do nothing.

Reimplemented from LE.

2375  {
2376 
2377  if (a_phase == sow) {
2378  m_vegddegs = 0.0;
2379  }
2380  else if (a_phase == harvest1) m_vegddegs = -1;
2381  if (a_phase == janfirst) {
2382  m_forced_phase_shift = false;
2387  if (g_crops->StartValid(m_curve_num, a_phase)) {
2388  double temp_veg_height = g_crops->GetStartValue(m_curve_num, a_phase, 2);
2389  if (temp_veg_height < m_veg_height) { // Otherwise we are better off with the numbers we have to start with
2390  // Now with added variability
2391  m_LAgreen = g_crops->GetStartValue(m_curve_num, a_phase, 0);
2392  m_LAtotal = g_crops->GetStartValue(m_curve_num, a_phase, 1);
2394  }
2395  }
2396 
2397  }
2398  else if (g_crops->StartValid(m_curve_num, a_phase)) {
2399  m_LAgreen = g_crops->GetStartValue(m_curve_num, a_phase, 0);
2400  m_LAtotal = g_crops->GetStartValue(m_curve_num, a_phase, 1);
2402  }
2403  else if (!m_force_growth) {
2404  // If we are in forced growth mode (which is very likely),
2405  // then do not choose a new set of starting values, as we have
2406  // already calculated our way to a reasonable set of values.
2407  //RandomVegStartValues( & m_LAtotal, & m_LAgreen, & m_veg_height, & m_weed_biomass ); // **CJT** Testing removal 17/02/2015
2408  }
2409  m_veg_phase = a_phase;
2410  m_yddegs = 0.0;
2412  m_force_growth = false;
2413 
2414  if (m_veg_phase == janfirst) {
2415  // For some growth curves there is no growth in the first
2416  // two months of the year. This will more likely than
2417  // not cause a discontinuous jump in the growth curves
2418  // come March first. ForceGrowthSpringTest() tries
2419  // to avoid that by checking for positive growth values
2420  // for the January growth phase. If none are found, then
2421  // it initializes a forced growth/transition to the March
2422  // 1st starting values.
2423  ForceGrowthSpringTest(); // Removal of this causes continuous increase in vegetation growth year on year for any curve that does not have a hard reset (e.g. harvest).
2424  }
2425 }

References Calendar::Date(), ForceGrowthSpringTest(), g_crops, g_date, g_weather, Weather::GetDDDegs(), PlantGrowthData::GetStartValue(), harvest1, janfirst, m_curve_num, LE::m_ddegs, m_force_growth, m_forced_phase_shift, m_LAgreen, m_LAtotal, m_veg_height, m_veg_phase, LE::m_vegddegs, LE::m_yddegs, sow, and PlantGrowthData::StartValid().

Referenced by FlowerStrip::Cutting(), FieldBoundary::Cutting(), RoadsideVerge::Cutting(), Orchard::Cutting(), MownGrassStrip::Cutting(), FlowerStripWithRotation::DoDevelopment(), ReduceVeg_Extended(), and VegElement().

◆ SetInsectBiomassParametersIndex()

void VegElement::SetInsectBiomassParametersIndex ( TTypesOfCrops  a_type)
1999  {
2000  switch (a_type) {
2001  //spring barley: 1
2002  case toc_OSpringBarley:
2005  case toc_OSpringBarleyPigs:
2008  case toc_OSpringWheat:
2009  case toc_SpringBarley:
2012  case toc_SpringBarleySeed:
2014  case toc_OSBarleySilage:
2015  case toc_Oats:
2017  case toc_OOats:
2019  break;
2020  //winter wheat: 2
2021  case toc_SpringWheat:
2022  case toc_Triticale:
2023  case toc_OTriticale:
2024  case toc_WinterBarley:
2025  case toc_WinterWheat:
2026  case toc_OWinterBarley:
2027  case toc_OWinterWheat:
2030  case toc_WinterTriticale:
2032  break;
2033  //winter rye: 3
2034  case toc_OWinterRye:
2035  case toc_OSpringRye:
2036  case toc_SpringRye:
2037  case toc_WinterRye:
2039  break;
2040  //winter rape: 4
2041  case toc_Beet:
2042  case toc_FodderBeet:
2043  case toc_OSugarBeet:
2044  case toc_Tulips:
2045  case toc_OPotatoes:
2046  case toc_OPotatoesIndustry:
2047  case toc_OPotatoesSeed:
2048  case toc_OStarchPotato:
2049  case toc_OCabbage:
2050  case toc_OCarrots:
2051  case toc_StarchPotato:
2052  case toc_SugarBeet:
2053  case toc_Potatoes:
2054  case toc_PotatoesIndustry:
2055  case toc_PotatoesSeed:
2056  case toc_PotatoesSpring:
2057  case toc_Cabbage:
2058  case toc_CabbageSpring:
2059  case toc_Carrots:
2060  case toc_CarrotsSpring:
2061  case toc_Maize:
2062  case toc_MaizeSilage:
2063  case toc_MaizeSpring:
2064  case toc_MaizeStrigling:
2065  case toc_OMaize:
2066  case toc_OMaizeSilage:
2067  case toc_OSpringRape:
2068  case toc_OWinterRape:
2069  case toc_SpringRape:
2070  case toc_WinterRape:
2072  break;
2073  //Cropped/Grazed Grass: 5
2079  case toc_GrassGrazed1:
2080  case toc_GrassGrazed2:
2082  case toc_GrassGrazedLast:
2091  break;
2092  // Edges and really nice places 6
2093  case toc_PermanentSetAside:
2095  break;
2096  //Setaside etc: 7
2097  case toc_SetAside:
2098  case toc_OSetAside:
2099  case toc_OSetAside_Flower:
2100  case toc_YoungForestCrop:
2101  case toc_Unmanaged:
2103  break;
2104  case toc_FarmForest:
2105  case toc_Sunflower:
2106  case toc_Turnip:
2107  case