File failed to load: https://cdnjs.cloudflare.com/ajax/libs/mathjax/2.7.5/extensions/ams.js
ALMaSS  1.2 (after EcoStack, March 2024)
The Animal, Landscape and Man Simulation System
All Classes Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Pages
FI_OWinterWheat Class Reference

FI_OWinterWheat class
. More...

#include <FI_OWinterWheat.h>

Inheritance diagram for FI_OWinterWheat:
Crop

Public Member Functions

virtual bool Do (Farm *a_farm, LE *a_field, FarmEvent *a_ev)
 The one and only method for a crop management plan. All farm actions go through here. More...
 
 FI_OWinterWheat (TTypesOfVegetation a_tov, TTypesOfCrops a_toc, Landscape *a_L)
 
void SetUpFarmCategoryInformation ()
 
- Public Member Functions inherited from Crop
virtual ~Crop ()
 
 Crop (TTypesOfVegetation a_tov, TTypesOfCrops a_toc, Landscape *a_L)
 
int GetFirstDate (void)
 
void ChooseNextCrop (int a_no_dates)
 Chooses the next crop to grow in a field. More...
 
int GetCropClassification ()
 
void SetCropClassification (int a_classification)
 
void GetCropType (TTypesOfCrops a_toc)
 
TTypesOfCrops GetCropType ()
 
FarmManagementCategory LookUpManagementCategory (int a_todo)
 
bool GetForceSpringOK ()
 

Additional Inherited Members

- Public Attributes inherited from Crop
TTypesOfVegetation m_tov
 
- Protected Member Functions inherited from Crop
void SimpleEvent (long a_date, int a_todo, bool a_lock)
 Adds an event to this crop management. More...
 
void SimpleEvent_ (long a_date, int a_todo, bool a_lock, Farm *a_farm, LE *a_field)
 Adds an event to this crop management without relying on member variables. More...
 
bool StartUpCrop (int a_spring, std::vector< std::vector< int >> a_flexdates, int a_todo)
 
Holds the translation between the farm operation enum for each cropand the farm management category associated with it More...
 
bool AphidDamage (LE *a_field)
 Compares aphid numbers per m2 with a threshold to return true if threshold is exceeded. More...
 
- Protected Attributes inherited from Crop
Farmm_farm
 
LEm_field
 
FarmEventm_ev
 
int m_first_date
 
int m_count
 
int m_last_date
 
int m_ddegstoharvest
 
int m_base_elements_no
 
Landscapem_OurLandscape
 
bool m_forcespringpossible = false
 Used to signal that the crop can be forced to start in spring. More...
 
TTypesOfCrops m_toc
 The Crop type in terms of the TTypesOfCrops list (smaller list than tov, no country designation) More...
 
int m_CropClassification
 Contains information on whether this is a winter crop, spring crop, or catch crop that straddles the year boundary (0,1,2) More...
 
vector< FarmManagementCategorym_ManagementCategories
 Holds the translation between the farm operation enum for each crop and the farm management category associated with it. More...
 
- Static Protected Attributes inherited from Crop
static int m_date_modifier = 0
 Holds a value that shifts test pesticide use by this many days in crops modified to use it. More...
 

Detailed Description

FI_OWinterWheat class
.

See FI_OWinterWheat.h::FI_OWinterWheatToDo for a complete list of all possible events triggered codes by the winter wheat management plan. When triggered these events are handled by Farm and are available as information for other objects such as animal and bird models.

Constructor & Destructor Documentation

◆ FI_OWinterWheat()

FI_OWinterWheat::FI_OWinterWheat ( TTypesOfVegetation  a_tov,
TTypesOfCrops  a_toc,
Landscape a_L 
)
inline
102  : Crop(a_tov, a_toc, a_L)
103  {
104  // When we start it off, the first possible date for a farm operation is 1st October
105  // This information is used by other crops when they decide how much post processing of
106  // the management is allowed after harvest before the next crop starts.
107  m_first_date=g_date->DayInYear( 1,9 );
109  }

References Calendar::DayInYear(), g_date, Crop::m_first_date, and SetUpFarmCategoryInformation().

Member Function Documentation

◆ Do()

bool FI_OWinterWheat::Do ( Farm a_farm,
LE a_field,
FarmEvent a_ev 
)
virtual

The one and only method for a crop management plan. All farm actions go through here.

Called every time something is done to the crop by the farmer in the first instance it is always called with a_ev->todo set to start, but susequently will be called whenever the farmer wants to carry out a new operation.
This method details all the management and relationships between operations necessary to grow and ALMaSS crop - in this case conventional winter wheat.

Reimplemented from Crop.

90 {
91  m_field = a_field; // this is needed because of possible calls to other methods and currently we do not pass parameters.
92  m_farm = a_farm; // this is needed because of possible calls to other methods and currently we do not pass parameters.
93  bool done = false; // The boolean value done indicates when we are totally finished with this plan (i.e. it is set to true).
94  int d1 = 0;
95  // Depending what event has occured jump to the correct bit of code e.g. for ww_start jump to line 67 below
96  switch (a_ev->m_todo)
97  {
98  case fi_oww_start:
99  {
100  // This is just to hold a local variable in scope and prevent compiler errors
101  // ww_start just sets up all the starting conditions and reference dates that are needed to start a ww
102  // crop off
103  FI_OWW_AUTUMN_PLOUGH = false;
106 
107  a_field->ClearManagementActionSum();
108 
109  // Record whether skylark scrapes are present and adjust flag accordingly
111  a_field->m_skylarkscrapes = true;
112  }
113  else {
114  a_field->m_skylarkscrapes = false;
115  }
116  // Set up the date management stuff
117  // The next bit of code just allows for altering dates after harvest if it is necessary
118  // to allow for a crop which starts its management early.
119 
120  // 3 start and stop dates for all events after harvest for this crop
121  int noDates = 2;
122  a_field->SetMDates(0, 0, g_date->DayInYear(25, 8)); // last possible day of harvest
123  a_field->SetMDates(1, 0, g_date->DayInYear(29, 8)); // last possible day of straw chopping
124  a_field->SetMDates(0, 1, 0); // start day of hay bailing (not used as it depend on previous treatment)
125  a_field->SetMDates(1, 1, g_date->DayInYear(29, 8)); // end day of hay bailing
126  // Can be up to 10 of these. If the shortening code is triggered
127  // then these will be reduced in value to 0
128 
129  a_field->SetMConstants(0, 1);
130 
131  // Check the next crop for early start, unless it is a spring crop
132  // in which case we ASSUME that no checking is necessary!!!!
133  // So DO NOT implement a crop that runs over the year boundary (i.e. from spring to spring!), at least not without fixing this.
134 
135  //new if: do the check only for non-optimising farms and if year>0. (030713 - m_rotation used only in the hidden year, so I modified the condition from >7 to >0)
136  int d1;
137  if (!(a_farm->GetType() == tof_OptimisingFarm && g_date->GetYearNumber() > 0)) {
138 
139  if (a_ev->m_startday > g_date->DayInYear(1, 7)) {
140  if (a_field->GetMDates(0, 0) >= a_ev->m_startday)
141  {
142  g_msg->Warn(WARN_BUG, "FI_OWinterWheat::Do(): ", "Harvest too late for the next crop to start!!!");
143  int almassnum = a_field->GetLandscape()->BackTranslateVegTypes(a_ev->m_next_tov);
144  g_msg->Warn("Next Crop ", (double)almassnum); // this causes exit
145  }
146  // Now fix any late finishing problems
147  for (int i = 0; i < noDates; i++) {
148  if (a_field->GetMDates(0, i) >= a_ev->m_startday) {
149  a_field->SetMDates(0, i, a_ev->m_startday - 1); //move the starting date
150  }
151  if (a_field->GetMDates(1, i) >= a_ev->m_startday) {
152  a_field->SetMConstants(i, 0); //change the default value of the MConst (=1) to 0 (necessary to correctly execute farm events in case the finishing date (MDate) was moved)
153  a_field->SetMDates(1, i, a_ev->m_startday - 1); //move the finishing date
154  }
155  }
156  }
157  // Now no operations can be timed after the start of the next crop.
158 
159  if (!a_ev->m_first_year) {
160  // Are we before July 1st?
161  d1 = g_date->OldDays() + g_date->DayInYear(1, 7);
162  if (g_date->Date() < d1) {
163  // Yes, too early. We assumme this is because the last crop was late
164  printf("Poly: %d\n", a_field->GetPoly());
165  g_msg->Warn(WARN_BUG, "FI_OWinterWheat::Do(): ", "Crop start attempt between 1st Jan & 1st July");
166  int prev = a_field->GetLandscape()->BackTranslateVegTypes(a_field->GetOwner()->GetPreviousTov(a_field->GetRotIndex()));
167  g_msg->Warn(WARN_BUG, "Previous Crop ", prev);
168  int almassnum = a_field->GetLandscape()->BackTranslateVegTypes(a_ev->m_next_tov);
169  g_msg->Warn("Next Crop ", (double)almassnum); // this causes exit
170  }
171  else {
172  d1 = g_date->OldDays() + m_first_date; // Add 365 for spring crop
173  if (g_date->Date() > d1) {
174  // Yes too late - should not happen - raise an error
175  g_msg->Warn(WARN_BUG, "FI_OWinterWheat::Do(): ", "Crop start attempt after last possible start date");
176  g_msg->Warn(WARN_BUG, "Previous Crop ", "");
177  a_field->GetOwner()->GetPreviousTov(a_field->GetRotIndex());
178  int almassnum = a_field->GetLandscape()->BackTranslateVegTypes(a_ev->m_next_tov);
179  g_msg->Warn("Next Crop ", (double)almassnum); // this causes exit
180  }
181  }
182  }
183  else {
184  // Is the first year
185  // Some special code to cope with that first start-up year in ALMaSS - ignore for all practical purposes (start with the first event on the after winter time)
187  break;
188  }
189  }//if
190 
191  // End single block date checking code. Please see next line comment as well.
192  // Reinit d1 to first possible starting date.
193  d1 = g_date->OldDays() + g_date->DayInYear(1, 8);
194  // OK, let's go.
195  // LKM: Here we queue up the first event -
196  //
197  SimpleEvent(d1, fi_oww_slurry, false);
198  }
199  break;
200  // This is the first real farm operation - LKM: done if there is time between 1-20th of August - if after 20th of August, go straight to fertilizer
201  case fi_oww_slurry:
202  if (a_ev->m_lock || a_farm->DoIt(20)) {
203  if (!a_farm->FP_Slurry(a_field, 0.0, g_date->DayInYear(20, 8) - g_date->DayInYear())) {
204  SimpleEvent(g_date->Date() + 1, fi_oww_slurry, true);
205  break;
206  }
207  }
209  break;
210  case fi_oww_shallow_plough: // shallow plough is coded as autumn plough - may need new function?
211  d1 = g_date->Date();
212  if (d1 > g_date->OldDays() + g_date->DayInYear(20, 8)) {
214  //
215  break;
216  } // 5% do the shallow plough followed by harrowing
217  else if (a_ev->m_lock || a_farm->DoIt(5)) {
218  if (!a_farm->AutumnPlough(a_field, 0.0, g_date->DayInYear(19, 8) - g_date->DayInYear())) {
219  // If we don't succeed on the first try, then try and try again (until 19/8 when we will succeed)
221  break;
222  }
223  // Queue up the next event - in this case harrowing
224  SimpleEvent(g_date->Date() + 1, fi_oww_harrow1, false);
225  break;
226  } // 20% do the stubble cultivator
227  else if (a_ev->m_lock || a_farm->DoIt(20)) {
229  break;
230  }
231  // otherwise do fertilizer
233  break;
234  case fi_oww_harrow1:
235  if (!a_farm->AutumnHarrow(a_field, 0.0, g_date->DayInYear(20, 8) - g_date->DayInYear())) {
236  // If we don't succeed on the first try, then try and try again (until 20/8 when we will succeed)
237  SimpleEvent(g_date->Date() + 1, fi_oww_harrow1, true);
238  break;
239  }
240  // Queue up the next event - in this case harrowing again 1-2 days after
241  SimpleEvent(g_date->Date() + 1, fi_oww_harrow2, false);
242  break;
243  case fi_oww_harrow2:
244  if (!a_farm->AutumnHarrow(a_field, 0.0, g_date->DayInYear(22, 8) - g_date->DayInYear())) {
245  // If we don't succeed on the first try, then try and try again (until 22/8 when we will succeed)
246  SimpleEvent(g_date->Date() + 1, fi_oww_harrow2, true);
247  break;
248  }
249  // Queue up the next event - in this case slurry
251  break;
253  if (!a_farm->StubbleCultivatorHeavy(a_field, 0.0, g_date->DayInYear(20, 8) - g_date->DayInYear())) {
254  // If we don't succeed on the first try, then try and try again (until 20/8 when we will succeed)
256  break;
257  }
258  // Queue up the next event - in this case stubble cultivator again a week after
260  break;
262  if (!a_farm->StubbleCultivatorHeavy(a_field, 0.0, g_date->DayInYear(28, 8) - g_date->DayInYear())) {
263  // If we don't succeed on the first try, then try and try again (until 28/8 when we will succeed)
265  break;
266  }
267  // Queue up the next event - in this case fertilizer
269  break;
270  case fi_oww_fertilizer1:
271  if (a_ev->m_lock || a_farm->DoIt(80)) {
272  if (!a_farm->FP_NPKS(a_field, 0.0, g_date->DayInYear(11, 9) - g_date->DayInYear())) {
273  SimpleEvent(g_date->Date() + 1, fi_oww_fertilizer1, true);
274  break;
275  }
276  }
277  // Queue up the next event - in this case stubble cultivator again
279  break;
281  if (a_ev->m_lock || a_farm->DoIt_prob(.20)) { // 20% do stubble cultivator3
282  if (!a_farm->StubbleCultivatorHeavy(a_field, 0.0, g_date->DayInYear(15, 9) - g_date->DayInYear())) {
284  break;
285  }
286  SimpleEvent(g_date->Date(), fi_oww_sow, false);
287  break;
288  }
289  else if (a_ev->m_lock || a_farm->DoIt_prob(.30 / .80)) {
291  break;
292  }
293  else if (a_ev->m_lock || a_farm->DoIt_prob(.30 / .50)) {
295  break;
296  }
297  else SimpleEvent(g_date->Date(), fi_oww_sow, false);
298  break;
299 
301  if (!a_farm->PreseedingCultivator(a_field, 0.0,
302  g_date->DayInYear(13, 9) - g_date->DayInYear())) {
304  break;
305  }
306  // Queue up the next event - in this case sow
307  SimpleEvent(g_date->Date(), fi_oww_sow, false);
308  break;
310  if (!a_farm->PreseedingCultivatorSow(a_field, 0.0,
311  g_date->DayInYear(15, 9) - g_date->DayInYear())) {
313  break;
314  }
315  SimpleEvent(g_date->Date() + 1, fi_oww_harrow3, false);
316  break;
317  case fi_oww_sow:
318  if (!a_farm->AutumnSow(m_field, 0.0, g_date->DayInYear(15, 9) - g_date->DayInYear())) {
319  SimpleEvent(g_date->Date() + 1, fi_oww_sow, true);
320  break;
321  }
322  SimpleEvent(g_date->Date() + 1, fi_oww_harrow3, false);
323  break;
324  case fi_oww_harrow3: // Don't know the % here
325  if (!a_farm->AutumnHarrow(a_field, 0.0,
326  g_date->DayInYear(22, 9) - g_date->DayInYear())) {
327  SimpleEvent(g_date->Date() + 1, fi_oww_harrow3, true);
328  break;
329  }
330  //Winter time!
331  //Queue up next event (next year) - in this case fertilizer2:
332  SimpleEvent(g_date->OldDays() + g_date->DayInYear(20, 5) + 365, fi_oww_fertilizer2, false);
333  break;
334 case fi_oww_fertilizer2:
335  if (a_ev->m_lock || a_farm->DoIt(60)) { //60% do a foliar fertilizer with microelements
336  if (!a_farm->FP_NPKS(a_field, 0.0,
337  g_date->DayInYear(25, 5) - g_date->DayInYear())) {
338  SimpleEvent(g_date->Date() + 1, fi_oww_fertilizer2, true);
339  break;
340  }
341  }
342  SimpleEvent(g_date->OldDays() + g_date->DayInYear(15, 8), fi_oww_harvest, false);
343  break;
344  case fi_oww_harvest:
345  // We don't move harvest days
346  if (!a_farm->Harvest(a_field, 0.0,
347  g_date->DayInYear(25, 8) - g_date->DayInYear())) {
348  SimpleEvent(g_date->Date() + 1, fi_oww_harvest, true);
349  break;
350  }
351  // 100% of farmers will do straw chopping
353  break;
355  if (a_field->GetMConstants(0) == 0) {
356  if (!a_farm->StrawChopping(a_field, 0.0, -1)) { // raise an error
357  g_msg->Warn(WARN_BUG, "FI_OWinterWheat::Do(): failure in 'StrawChopping' execution", "");
358  exit(1);
359  }
360  }
362  break;
363  case fi_oww_hay_bailing:
364  if (a_ev->m_lock || a_farm->DoIt(5)) { //5% do hay bailing
365  if (a_field->GetMConstants(1) == 0) {
366  if (!a_farm->HayBailing(a_field, 0.0, -1)) { // raise an error
367  g_msg->Warn(WARN_BUG, "FI_OWinterWheat::Do(): failure in 'HayBailing' execution", "");
368  exit(1);
369  }
370  }
371  }
372  else {
373  done = true;
374  }
375  done = true;
376  // So we are done, and somewhere else the farmer will queue up the start event of the next crop
377  // END OF MAIN THREAD
378  break;
379  default:
380  g_msg->Warn(WARN_BUG, "FI_OWinterWheat::Do(): "
381  "Unknown event type! ", "");
382  exit(1);
383  }
384  return done;
385 }

References Farm::AutumnHarrow(), Farm::AutumnPlough(), Farm::AutumnSow(), cfg_FI_OWinterWheat_SkScrapes, LE::ClearManagementActionSum(), Calendar::Date(), Calendar::DayInYear(), Farm::DoIt(), Farm::DoIt_prob(), FI_OWW_AUTUMN_PLOUGH, fi_oww_cultivation_seeding, FI_OWW_DECIDE_TO_FI, FI_OWW_DECIDE_TO_HERB, fi_oww_fertilizer1, fi_oww_fertilizer2, fi_oww_harrow1, fi_oww_harrow2, fi_oww_harrow3, fi_oww_harvest, fi_oww_hay_bailing, fi_oww_preseeding_cultivator, fi_oww_shallow_plough, fi_oww_slurry, fi_oww_sow, fi_oww_start, fi_oww_straw_chopping, fi_oww_stubble_cultivator1, fi_oww_stubble_cultivator2, fi_oww_stubble_cultivator3, Farm::FP_NPKS(), Farm::FP_Slurry(), g_date, g_msg, LE::GetMConstants(), LE::GetMDates(), LE::GetOwner(), LE::GetPoly(), Farm::GetPreviousTov(), LE::GetRotIndex(), Farm::GetType(), Calendar::GetYearNumber(), Farm::Harvest(), Farm::HayBailing(), Crop::m_farm, Crop::m_field, Crop::m_first_date, FarmEvent::m_first_year, FarmEvent::m_lock, FarmEvent::m_next_tov, LE::m_skylarkscrapes, FarmEvent::m_startday, FarmEvent::m_todo, Calendar::OldDays(), Farm::PreseedingCultivator(), Farm::PreseedingCultivatorSow(), LE::SetMConstants(), LE::SetMDates(), Crop::SimpleEvent(), Farm::StrawChopping(), Farm::StubbleCultivatorHeavy(), tof_OptimisingFarm, CfgBool::value(), MapErrorMsg::Warn(), and WARN_BUG.

◆ SetUpFarmCategoryInformation()

void FI_OWinterWheat::SetUpFarmCategoryInformation ( )
inline
110  {
111  const int elements = 2 + (fi_oww_foobar - FI_OWW_BASE);
113 
114  FarmManagementCategory catlist[elements] =
115  {
116  fmc_Others, // zero element unused but must be here
117  fmc_Others, // fi_oww_start = 1, // Compulsory, must always be 1 (one).
118  fmc_Others, // fi_oww_sleep_all_day = FI_OWW_BASE,
119  fmc_Cultivation, // fi_oww_shallow_plough,
120  fmc_Cultivation, // fi_oww_stubble_cultivator1,
121  fmc_Cultivation, // fi_oww_stubble_cultivator2,
122  fmc_Cultivation, // fi_oww_harrow1,
123  fmc_Cultivation, // fi_oww_harrow2,
124  fmc_Fertilizer, // fi_oww_slurry,
125  fmc_Fertilizer, // fi_oww_fertilizer1,
126  fmc_Cultivation, // fi_oww_stubble_cultivator3,
127  fmc_Cultivation, // fi_oww_preseeding_cultivator,
128  fmc_Cultivation, // fi_oww_cultivation_seeding,
129  fmc_Others, // fi_oww_sow,
130  fmc_Cultivation, // fi_oww_harrow3,
131  fmc_Fertilizer, // fi_oww_fertilizer2,
132  fmc_Harvest, // fi_oww_harvest,
133  fmc_Others, // fi_oww_straw_chopping,
134  fmc_Others // fi_oww_hay_bailing,
135 
136 
137  // no foobar entry
138 
139  };
140  // Iterate over the catlist elements and copy them to vector
141  copy(begin(catlist), end(catlist), back_inserter(m_ManagementCategories));
142 
143  }

References FI_OWW_BASE, fi_oww_foobar, fmc_Cultivation, fmc_Fertilizer, fmc_Harvest, fmc_Others, Crop::m_base_elements_no, and Crop::m_ManagementCategories.

Referenced by FI_OWinterWheat().


The documentation for this class was generated from the following files:
LE::GetMDates
int GetMDates(int a, int b)
Definition: Elements.h:405
Farm::PreseedingCultivator
virtual bool PreseedingCultivator(LE *a_field, double a_user, int a_days)
Carry out preseeding cultivation on a_field (tilling set including cultivator and string roller to co...
Definition: FarmFuncs.cpp:312
LE::SetMDates
void SetMDates(int a, int b, int c)
Definition: Elements.h:406
Farm::Harvest
virtual bool Harvest(LE *a_field, double a_user, int a_days)
Carry out a harvest on a_field.
Definition: FarmFuncs.cpp:1364
FarmEvent::m_lock
bool m_lock
Definition: Farm.h:384
Farm::StubbleCultivatorHeavy
virtual bool StubbleCultivatorHeavy(LE *a_field, double a_user, int a_days)
Carry out a stubble cultivation event on a_field. This is non-inversion type of cultivation which can...
Definition: FarmFuncs.cpp:245
LE::GetMConstants
int GetMConstants(int a)
Definition: Elements.h:407
LE::ClearManagementActionSum
void ClearManagementActionSum()
clears the management action counters
Definition: Elements.h:247
FI_OWW_AUTUMN_PLOUGH
#define FI_OWW_AUTUMN_PLOUGH
A flag used to indicate autumn ploughing status.
Definition: FI_OWinterWheat.h:57
Farm::DoIt
bool DoIt(double a_probability)
Return chance out of 0 to 100.
Definition: Farm.cpp:856
Calendar::GetYearNumber
int GetYearNumber(void)
Definition: Calendar.h:72
FarmEvent::m_first_year
bool m_first_year
Definition: Farm.h:386
LE::GetPoly
int GetPoly(void)
Returns the polyref number for this polygon.
Definition: Elements.h:238
fi_oww_start
Definition: FI_OWinterWheat.h:68
Farm::DoIt_prob
bool DoIt_prob(double a_probability)
Return chance out of 0 to 1.
Definition: Farm.cpp:864
g_date
class Calendar * g_date
Definition: Calendar.cpp:37
fi_oww_stubble_cultivator2
Definition: FI_OWinterWheat.h:72
Farm::GetPreviousTov
TTypesOfVegetation GetPreviousTov(int a_index)
Definition: Farm.h:966
fi_oww_fertilizer2
Definition: FI_OWinterWheat.h:82
Farm::GetType
TTypesOfFarm GetType(void)
Definition: Farm.h:956
Crop::m_base_elements_no
int m_base_elements_no
Definition: Farm.h:505
Crop::m_first_date
int m_first_date
Definition: Farm.h:501
FarmEvent::m_startday
int m_startday
Definition: Farm.h:385
FI_OWW_BASE
#define FI_OWW_BASE
Definition: FI_OWinterWheat.h:53
Crop::SimpleEvent
void SimpleEvent(long a_date, int a_todo, bool a_lock)
Adds an event to this crop management.
Definition: Farm.cpp:747
fi_oww_foobar
Definition: FI_OWinterWheat.h:86
CfgBool::value
bool value() const
Definition: Configurator.h:164
fi_oww_stubble_cultivator3
Definition: FI_OWinterWheat.h:77
FI_OWinterWheat::SetUpFarmCategoryInformation
void SetUpFarmCategoryInformation()
Definition: FI_OWinterWheat.h:110
fmc_Fertilizer
Definition: LandscapeFarmingEnums.h:1004
LE::m_skylarkscrapes
bool m_skylarkscrapes
For management testing of skylark scrapes.
Definition: Elements.h:95
Calendar::Date
long Date(void)
Definition: Calendar.h:57
fmc_Cultivation
Definition: LandscapeFarmingEnums.h:1008
Farm::HayBailing
virtual bool HayBailing(LE *a_field, double a_user, int a_days)
Carry out hay bailing on a_field.
Definition: FarmFuncs.cpp:1507
fi_oww_hay_bailing
Definition: FI_OWinterWheat.h:85
fmc_Others
Definition: LandscapeFarmingEnums.h:1003
Farm::StrawChopping
virtual bool StrawChopping(LE *a_field, double a_user, int a_days)
Carry out straw chopping on a_field.
Definition: FarmFuncs.cpp:1475
fi_oww_harrow1
Definition: FI_OWinterWheat.h:73
Calendar::OldDays
long OldDays(void)
Definition: Calendar.h:60
fi_oww_sow
Definition: FI_OWinterWheat.h:80
fi_oww_fertilizer1
Definition: FI_OWinterWheat.h:76
cfg_FI_OWinterWheat_SkScrapes
CfgBool cfg_FI_OWinterWheat_SkScrapes("FI_CROP_OWW_SK_SCRAPES", CFG_CUSTOM, false)
MapErrorMsg::Warn
void Warn(MapErrorState a_level, std::string a_msg1, std::string a_msg2)
Definition: MapErrorMsg.cpp:69
FI_OWW_DECIDE_TO_FI
#define FI_OWW_DECIDE_TO_FI
Definition: FI_OWinterWheat.h:59
LE::GetRotIndex
int GetRotIndex(void)
Definition: Elements.h:373
fi_oww_shallow_plough
Definition: FI_OWinterWheat.h:70
fi_oww_slurry
Definition: FI_OWinterWheat.h:75
fi_oww_cultivation_seeding
Definition: FI_OWinterWheat.h:79
FarmEvent::m_next_tov
TTypesOfVegetation m_next_tov
Definition: Farm.h:390
fi_oww_harrow3
Definition: FI_OWinterWheat.h:81
Crop::m_farm
Farm * m_farm
Definition: Farm.h:498
Crop::m_field
LE * m_field
Definition: Farm.h:499
Crop::m_ManagementCategories
vector< FarmManagementCategory > m_ManagementCategories
Holds the translation between the farm operation enum for each crop and the farm management category ...
Definition: Farm.h:530
Farm::PreseedingCultivatorSow
virtual bool PreseedingCultivatorSow(LE *a_field, double a_user, int a_days, double a_seed_coating_amount=-1, PlantProtectionProducts a_ppp=ppp_foobar)
Carry out preseeding cultivation together with sow on a_field (tilling and sowing set including culti...
Definition: FarmFuncs.cpp:325
FarmEvent::m_todo
int m_todo
Definition: Farm.h:388
Farm::FP_Slurry
virtual bool FP_Slurry(LE *a_field, double a_user, int a_days)
Apply slurry to a_field owned by an arable farmer.
Definition: FarmFuncs.cpp:823
FI_OWW_DECIDE_TO_HERB
#define FI_OWW_DECIDE_TO_HERB
Definition: FI_OWinterWheat.h:58
tof_OptimisingFarm
Definition: LandscapeFarmingEnums.h:696
Farm::AutumnPlough
virtual bool AutumnPlough(LE *a_field, double a_user, int a_days)
Carry out a ploughing event in the autumn on a_field.
Definition: FarmFuncs.cpp:212
g_msg
MapErrorMsg * g_msg
Definition: MapErrorMsg.cpp:41
Farm::AutumnHarrow
virtual bool AutumnHarrow(LE *a_field, double a_user, int a_days)
Carry out a harrow event in the autumn on a_field.
Definition: FarmFuncs.cpp:285
fi_oww_preseeding_cultivator
Definition: FI_OWinterWheat.h:78
Farm::AutumnSow
virtual bool AutumnSow(LE *a_field, double a_user, int a_days, double a_seed_coating_amount=-1, PlantProtectionProducts a_ppp=ppp_foobar)
Carry out a sowing event in the autumn on a_field.
Definition: FarmFuncs.cpp:360
fmc_Harvest
Definition: LandscapeFarmingEnums.h:1012
LE::GetOwner
Farm * GetOwner(void)
Definition: Elements.h:256
Calendar::DayInYear
int DayInYear(void)
Definition: Calendar.h:58
fi_oww_harvest
Definition: FI_OWinterWheat.h:83
Crop::Crop
Crop(TTypesOfVegetation a_tov, TTypesOfCrops a_toc, Landscape *a_L)
Definition: Farm.cpp:733
LE::SetMConstants
void SetMConstants(int a, int c)
Definition: Elements.h:408
fi_oww_straw_chopping
Definition: FI_OWinterWheat.h:84
fi_oww_stubble_cultivator1
Definition: FI_OWinterWheat.h:71
WARN_BUG
Definition: MapErrorMsg.h:34
fi_oww_harrow2
Definition: FI_OWinterWheat.h:74
FarmManagementCategory
FarmManagementCategory
Definition: LandscapeFarmingEnums.h:1001
Farm::FP_NPKS
virtual bool FP_NPKS(LE *a_field, double a_user, int a_days)
Apply NPKS fertilizer, on a_field owned by an arable farmer.
Definition: FarmFuncs.cpp:630