I think that a parcel (a field) needs to be a static fact, perhaps not maintaining a single state but two states, previous and current. Events are state changes and sensor readings.

Now, if sensor readings are dangerous for state A and if the last state change is not much distant from the sensor readings you can still raise an alarm. I also think that a "state change" in a field is not a single point in time; states overlap in a (large) field, as one part may be sunnier or drier or... as other parts. Clearly, this complicates rules, but I think that the whole problem cannot be handled in an absolutely discrete manner.

-W


On 15 November 2010 13:56, Anais Martinez <amartinez@iti.upv.es> wrote:


The system is receiving readings from real sensors of humidity, temperature,
etc.. There are a lot of rules for deciding if a specific plague or illness
affects (or can affect) to the plants or not: One condition of those rules
is the plants' status, because the illnesses affect to the plant depending
on its status. I have defined Status, Reading and Risk as events.

Well. Supose than the system has just passed from status "A" to status "B",
and after that, it has received several readings from sensors whose values
are a risk for an illness in the status "A" but not in "B".  Then, the
system has not activated the Risk, because it thinks that the current status
is "B". Therefore, if the farmer inserts an status "B" after those readings,
the system has not activated the Risk but that readings are dangerous. In
that case, how do i say that there is a Risk?

Thanks again.
--
View this message in context: http://drools-java-rules-engine.46999.n3.nabble.com/Reasoning-with-past-events-tp1903815p1904201.html
Sent from the Drools - User mailing list archive at Nabble.com.
_______________________________________________
rules-users mailing list
rules-users@lists.jboss.org
https://lists.jboss.org/mailman/listinfo/rules-users