
Hi Thomas,

Thanks a lot, it worked fine for me!.

Regards,

Mohamed.

> On July 16, 2014 at 7:21 PM Thomas Petzoldt <Thomas.Petzoldt@tu-dresden.de>
> wrote:
>
>
> Hi Mohamed,
>
> the easiest way is to write an event function that can handle both cases:
>
> void eventfun(int *n, double *t, double *y) {
>
> if (*t < 150)
> y[0] = 1.5 * y[0];
> else
> y[1] = 1.001 * y[1];
> }
>
>
>
> There was also a related thread how to do something similar in R:
>
> https://stat.ethz.ch/pipermail/r-sig-dynamic-models/2013q1/000159.html
>
>
> In any case, please think about whether you really need events for this,
> or if forcing functions would be the more appropriate modelling approach.
>
> Hope it helps
>
> Thomas
--------------------------------------------------------------------
Mohamed Omari
PhD Student

Leibniz Centre for Agricultural Landscape Research (ZALF), Müncheberg
Institute of Landscape Hydrology
Eberswalder Straße 84
D-15374 Müncheberg
Germany
	[[alternative HTML version deleted]]

