Services & Resources / Wolfram Forums
-----
 /
MathGroup Archive
2007
*January
*February
*March
*April
*May
*June
*July
*August
*September
*October
*Archive Index
*Ask about this page
*Print this page
*Give us feedback
*Sign up for the Wolfram Insider

MathGroup Archive 2007

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

Search the Archive

NDSolve EventLocator Method question about the Event option

  • To: mathgroup at smc.vnet.net
  • Subject: [mg72570] NDSolve EventLocator Method question about the Event option
  • From: "Chris Chiasson" <chris at chiasson.name>
  • Date: Wed, 10 Jan 2007 02:26:53 -0500 (EST)

I have a complicated NDSolve command, which I can produce for you if
you want, that does not seem to "hit" the event I am looking for when
I use subtraction, but hits the event just fine when I use Less.

Here are the two options:

doesn't work very well (produces NDSolve::evnf):

"Event"->Abs@y@x-height[i[x]]/2

works:

"Event"->Abs@y@x<height[i[x]]/2

height[i[x]] is always a positive number, as is Abs@y@x

Does anyone have any ideas about why this might happen?

P.S. Here is the full (working) Method option:

Method->{"EventLocator","Event"->Abs@y@x<height[i[x]]/2,"EventAction":>Throw[Null,"StopIntegration"]}

-- 
http://chris.chiasson.name/


  • Prev by Date: Re: Replacements in NonCommutativeMultiply
  • Next by Date: Re: How to export txt files with variable name &
  • Previous by thread: Re: Call-by-reference from inside a function
  • Next by thread: Re: NDSolve EventLocator Method question about the Event option