CropSyst: A Collection of Object-Oriented Simulation Models of Agricultural Systems
- F. K. Van Evert * and
- G. S. Campbell
Simulation of whole agricultural systems is now widely used in agronomy. Construction and maintenance of the large simulation models quired for agricultural systems may benefit from the application of mo ern programming methods. In particular, object-oriented programming (OOP) methods claim several advantages over conventional procedural methods. We sought a programming approach that would allow (i) interchanging of component models within and between whole-system models, (ii) incremental model building without rewriting existing code, (iii) maintenance of more than one model of a component, and (iv) construction of a user-friendly interface from which all parameters can be assigned and component models run. Here we report results of an experiment in which we used OOP to construct a cropping system model called CropSyst. An OOP analysis of cropping systems led to the abstraction of component systems (objects) with minimal and well-defined interfaces. Examples of components, or objects, used in CropSyst are Time, Weather, Crop, Soil, Crop residue, Tillage, Erosion, Aphid population, Aphid immigration, Pesticide application, Planting, Crop rotation, and Output. Different versions of CropSyst were implemented and used to simulate production and erosion for cropping systems in eastern Washington, and to simulate yield loss and pesticide dynamics associated with Russian Wheat Aphid infestation. These were constructed from existing objects. Different versions of the Crop object simulated the different crops in a rotation cycle. Parameters were assigned and models we run from a commercially supplied user interface, which was also proggrammed using OOP. We were able to meet our objectives using OOP, and found it useful for construction and maintenance of agricultural systems models.
Copyright © .