MathGroup Archive 2003

[Date Index] [Thread Index] [Author Index]

Search the Archive

Re: Using error message output

  • To: mathgroup at smc.vnet.net
  • Subject: [mg43406] Re: Using error message output
  • From: Eric Peterson <ericp at lanl.gov>
  • Date: Tue, 16 Sep 2003 04:35:59 -0400 (EDT)
  • Sender: owner-wri-mathgroup at wolfram.com

Well I was actually able to answer my own question by using an NDSolve
StateData object and the CurrentTime method.  But I am still wondering if
there is a way to have a *notebook* do something with error messages
automatically, something like throwing and catching exception.  Any ideas?

Eric




On 8/27/03 9:02 AM, "Eric Peterson" <ericp at lanl.gov> wrote:

> I am using NDSolve and sometimes the integrator hits a snag as it's
> calculating.  I'll get an error message like:
> 
> NDSolve::ndsz :
> At t == 4.198615826788436`, step size is effectively zero; singularity or
> stiff system suspected.
> 
> Now as it turns out that's just fine; by the time the integrator fails I have
> all the results I need.  But I would really like to be able to extract the
> value of the variable t at which the integrator stopped so that I can use it
> when I plot the results.
> 
> I'd rather not kluge something in to parse it out of the error message.  Is
> there an elegant way to do this?
> 
> Eric


  • Prev by Date: Defining a function
  • Next by Date: maxsteps, startingstepsize in NDSolve.
  • Previous by thread: Using error message output
  • Next by thread: nonlinearfit