[R-sig-dyn-mod] Fwd: Desolve: root/event functions in fortran

Derek van der Kamp derek.vanderkamp at gmail.com
Mon Mar 23 22:29:31 CET 2015


Greetings,

I was wondering if anyone could help me with a question regarding desolve,
or point me to someone who could help.

I would like to keep one of my state variables below a certain value.

To do this I want to use a root function to determine when that theshold
value is reached, and an event function to keep the state variable below
that threshold.

However, I'm using fortran, and I can not find any examples in which a root
function was used in compiled code.

In the package vignette (
http://cran.r-project.org/web/packages/deSolve/vignettes/compiledCode.pdf)
no root function is ever used; the event function is called based on
pre-defined event times.

Is it possible to define and use a root function in fortran?

Thanks for your time,

Derek van der Kamp

	[[alternative HTML version deleted]]



More information about the R-sig-dynamic-models mailing list