[R] odesolve/lsoda differences on Windows and Mac

Setzer.Woodrow@epamail.epa.gov Setzer.Woodrow at epamail.epa.gov
Thu Jul 28 15:30:43 CEST 2005


I will have added most of the solvers from the ode package odepack by
Alan Hindmarsh, LLNL, to odesolve this year.  These are all solvers in
the lsode family.
I would also like to add solver(s) for DAEs, like daskr (Brown,
Hindmarsh, Petzold), but that may take a bit longer.
If other folks are planning to contribute solvers, I would be happy to
discuss including them in odesolve, so there would be a single main
package for solving ODEs.

R. Woodrow Setzer, Jr.
National Center for Computational Toxicology
US Environmental Protection Agency
Mail Drop B305-03/US EPA/RTP, NC 27711
Ph: (919) 541-0128    Fax: (919) 541-4284


                                                                        
             Thomas Petzoldt                                            
             <petzoldt at rcs.ur                                           
             z.tu-dresden.de>                                        To 
                                      Peter Dalgaard                    
             07/28/2005 05:05         <p.dalgaard at biostat.ku.dk>        
             AM                                                      cc 
                                      "Martin Henry H. Stevens"         
                                      <HStevens at muohio.edu>, "'R-Help'" 
                                      <r-help at stat.math.ethz.ch>,       
                                      Woodrow Setzer/RTP/USEPA/US at EPA,  
                                      Thomas Petzoldt                   
                                      <petzoldt at rcs.urz.tu-dresden.de>  
                                                                Subject 
                                      Re: [R] odesolve/lsoda            
                                      differences on Windows and Mac    
                                                                        
                                                                        
                                                                        
                                                                        
                                                                        
                                                                        




On 27 Jul 2005, Peter Dalgaard wrote:

> One thought: Integrating across input pulses is a known source of
> "turbulence" in lsoda. You might have better luck integrating over
> intervals in which the input function is continuous.
>
> Tweaking the lsoda tolerances is another thing to try.

Yes, that's also our experience. Where I am usually succesful
when playing with the tolerances or the interpolation rule of external
pulses, some of our students use the fixed step rk4 algorithm and some
others wrote their own integrators in R.

I have heared that several people had plans to provide alternative ODE
integrators for R but I currently do not know about the state of these
projects. It wold be nice if they might post this to the list in order
to
avoid double work.

>
> I haven't seen lsoda fail like that, but it's not too surprising that
> marginal cases show platform dependency (i.e. the integrator just
> fails on Mac and barely succeeds on PC).
>

Aha, I see. It should be regarded carefully when publishing examples
that
result in "marginal cases" as the common user would expect that R is
platform independent.

Thomas P.




More information about the R-help mailing list