## 5 Example of CAS Development
### Ontology Conceptualization
#### 5.2.2 Function getDailyAggregatedMoisture Model  
The goal of this subsection is to model the result of the function getDailyAggregatedMoisture(p,d). This function computes the daily average of all the measurements provided by one tensiometer. IRRIG defines several classes and instances used for modeling the daily average of tensiometer measurements:  
* \(\text{irrig:observationProperty\_soil30 cmDepth\_dailyAverageMoisture}\): this individual represents the daily average of the moisture property related to the soil layer at a 30 cm depth. It is an instance of the class **irrig:MoistureProperty**. This individual is linked to the individual **irrig:featureOfInterest_soil30 cmDepth** (see Figure 12). * \(\text{irrig:Soil30 cmDepth\_DailyAverageMoistureObservation}\): this class is a subclass of **casc:Observation**. It is a defined class that represents the act of carrying out a procedure (observation) to calculate the average per day of the moisture property. This specific property is represented by the individual **irrig:observableProperty_soil30 cmDepth_dailyAverageMoisture**. Two necessary and sufficient conditions are defined: (1) All instances of the class **irrig:Soil30 cmDepthDailyAverageMoistureObservation** are linked to the individual **irrig:observableProperty_soil30 cmDepth_dailyAverageMoisture** via the **sosa:observedProperty** object property; (2) All instances of **irrig:Soil30 cmDepthDailyAverageMoistureObservation** are linked to the individual **irrig:featureOfInterest_soil30 cmDepth** via the **sosa:hasFeatureOfInterest** object property. Each instance of **irrig:Soil30 cmDepthDailyAverageMoistureObservation** is linked to a sensor to describe which agent made the observation and how. Figure 12 presents an example of the getDailyAggregatedMoisture(p,d) result. The instance of the class **irrig:Soil30 cmDepthDailyAverageMoistureObservation** represents the computation of the daily average of all measurements provided by one tensiometer, as shown in Figure 12. By definition, individuals of **irrig:Soil30 cmDepthMoistureObservation** are linked to the individual irrig:observedProperty_soil30 cmDepth_dailyAverageMoisture, an instance of the class **irrig:MoistureProperty**, and to the individual irrig:featureOfInterest_soil30 cmDepth. The observation individual is linked to the sensor that produces the result, i.e., a software program that computes the daily average of several measurements. We do not have information on the agent that produces this computation in the Arvalis dataset. It is possible that the same software, located on a server, computes the average for all the measurements. Alternatively, the IRRINOV station may contain two different processing devices. Each device can compute the average for all the tensiometers located at the same depth. To avoid errors, we create a software agent for each tensiometer based on the tensiometer name: **arvalis:aggregator_getDailyAggregatedMoisture_1**. The individual that  
Figure 12: Example of the computation of getDailyAggregatedMoisture(p,d). represents the software is an instance of the class **sosa:Sensor**. The observation individual is linked to the software agent via the sosa:madeBySensor object property, as shown in Figure 12.  
The software program produces the result once per day at a precise time. In the Arvalis dataset, there is no information about the hour, minute and second of the computation. For synchronization purposes, we fix it to the time of the deduction computation [d+1 06:00:00]. At this time, all the tensiometer measurements were available for the computation of the average. To store the time of the computation, we use the _sosa:resultTime_ datatype property to links the observation individual to the xsd:dateTime corresponding to the precise time [d+1 06:00:00]. This is presented in Figure 12.  
The computation calculates the daily average. Figure 12 presents the average for the 14/08/2013. We represent the day as a period of 24 h: [d 00:00:00, d+1 00:00:00[.