Skip to content
Prev 180439 / 398506 Next

ode first step

Have you looked at the vignette in the deSolve package? 


           (deS <- vignette('compiledCode')) # opens a "pdf" file
           Stangle(deS$file) # writes an R script file to "getwd()" 


      In spite of the name, this vignette includes an example entirely 
in R.  By comparing it with your code, I see that you do NOT provide a 
connection between y, parms, K1, C0, m, V, K2 and q.  Something like the 
following might work: 

kinetic.model<-function(t,y,parms){
	dq.dt = parms['K1']*y['C0'] - (parms['K1']*y['m']/y['V']+ parms['K2'])*y['q']
	list(dq.dt)
	}


      This may not be correct, but I hope the changes will help you see 
how to make it work. 


      Bon Chance. 
      Spencer Graves
Benoit Boulinguiez wrote: