MathGroup Archive 2001

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

Search the Archive

Re: right StoppingTest

It's a better-safe-than-dead thing, in this case.
Generaly, you don't want the test to be evaluated BEFORE the solution
gets going (as would be the case with an 'ordinary' ->), but only
within the NDSolve code, so we use :> (RuleDelayed).
For instance:
NDSolve[.....,StoppingTest->(Print[t];False)] would return something
like this:
Out[13]:= -InterpolatingFunction-
which is not what you want!
If you use the same command with a :> instead of ->, you will get all
the t's, that are used as intermediate steps, printed and the
interpolating function returned as desired.

  • Prev by Date: Finding determinants of nxn matrices
  • Next by Date: Re: Compiling functions
  • Previous by thread: Re: Finding determinants of nxn matrices
  • Next by thread: Re: Compiling functions