The ITK SAS firm works in agronomy, it proposes decision support system (DSS) for croppers and designs digital models. The DSS proposed in this company rely on mechanistic models representing the physiological processes occurring during the plant growth and development. A fine representation of the different biological processes occurring in the field helps identifying the best suited management options. The model development process at ITK implies two implementation phases leading to an efficiency problem. The first implementation step produces a Matlab® implementation of a crop model proposed by agronomists, but then in a second step, this model is transposed in Java by software engineers for industrial use. This double implementation causes increases in cost production due to rewriting and maintaining both codes while they are still evolving. To avoid such costs, this paper proposes to apply model driven engineering techniques to identify a metamodel for the domain of mechanistic modelling in our agronomic context of crop modelling. The purpose of the metamodel is to optimize the implementation phase at ITK by proposing a mechanistic model factory for agronomists. Proposing a model factory supposes a certain level of genericity by taking into account as much as possible the diversity of mechanistic models in agronomy. Depending on the plant topology described, we can find big leaf models which consider the plant to be one single leaf like the STICS crop model which has been adapted to several plant species (Brisson, Launay, & Beaudoin, 2009), leaf layered models (Lawless, Semenov, & Jamieson, 2005) and functional structural plant models (FSPM). The latter being the most detailed approach with explicit consideration of the plant architecture (Vos, Marcelis, & Evers, 2007). In addition to the plant topology, the way the different biophysical processes are modeled and organized as well as their scale (with regards to space and/or time) is responsible for most of the mechanistic models diversity. This diversity comes from: the aim of the model, the expected accuracy, the lack of knowledge on the plant biology or even the specificities of some plant species like floral initiation or vernalization (a physiological phenomenon linked to the exposure of seedlings to low temperature having an effect on the plant development and flowering) (Barbier, Pinet, & Hill, 2011). To deal with this diversity, the production of the metamodel described in this paper is achieved thanks to legacy applications which cover a wide variety of models and more precisely on wheat, cotton and vine modeling (Jallas, 1998; Jamieson, Semenov, Brooking, & Francis, 1998; Louarn, 2009). The wheat model was derived from the leaf layered model Sirius (Jamieson & Semenov, 2000; Lawless et al., 2005) including specificities on vernalization and floral initiation (Gate, 1995) and a soil tank model. These models we have studied encompass the diversity of crop models with different data structures and processes.
A presentation of the crop modeling domain and of our preliminary work is given in (Barbier et al., 2011). In this paper, we address a metamodel that has been refined to obtain a better match with the targeted specific domain by adding specific constructs for crop modeling. In section one, we propose a short presentation of the main MDE concepts within our domain context, then we present the Domain Specific Modelling approach (section 2). Next, the metamodel representing the Domain Specific Modeling Language for most of the crop modeling domain is given and discussed (section 3). In section 4 we explain how the Model-View-Controller design pattern can be applied to the crop model factory. Using this design pattern, we wish to provide different views of the model being designed as proposed by (Dalle, Ribault, & Himmelspach, 2009). Intelligent behaviors can be added to the DSML using this pattern. Following the whole design approach presented in this paper, the prototype is able to generate operational Java implementation (Barbier, Flusin, Cucchi, Pinet, & Hill, in press).