Services & Resources / Wolfram Forums
MathGroup Archive
*Archive Index
*Ask about this page
*Print this page
*Give us feedback
*Sign up for the Wolfram Insider

MathGroup Archive 2001

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

Search the Archive

Re: right StoppingTest

  • To: mathgroup at
  • Subject: [mg31766] Re: right StoppingTest
  • From: atelesforos at (Orestis Vantzos)
  • Date: Sat, 1 Dec 2001 02:45:03 -0500 (EST)
  • References: <9tvgln$fql$> <9u20bm$ipa$> <9u4h3q$lpl$>
  • Sender: owner-wri-mathgroup at

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