MathGroup Archive 2006

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

Search the Archive

StoppingTest options (need help)

  • To: mathgroup at
  • Subject: [mg72400] StoppingTest options (need help)
  • From: Cham <martin465 at>
  • Date: Mon, 25 Dec 2006 04:52:28 -0500 (EST)

I'm using the NDSolve command to find a closed curve (it's a magnetic field line). It works, but I need to end the calculation at a specific point in space, so I don't get a curve with many turns.  I only want a single turn to draw a complete loop.  How can I use the StoppingTest options to tell Mathematica to find a single turn loop ?  The specific code is like this :

x'[t] == Bx[x[t], y[t], z[t]],
y'[t] == By[x[t], y[t], z[t]],
z'[t] == Bz[x[t], y[t], z[t]],
x[0] == 0,
y[0] == 1,
z[0] == 0,
}, {x, y, z}, {t, 0, 100}, StoppingTest -> ( ? ? ? )]

Suppose I want the curve to stop at coordinates {x, y, z} = {1, 2, 3}, or better, I want it to be a complete loop with a single turn (stop when it's back at the initial coordinates).  How can I tell that to Mathematica ?

  • Prev by Date: List Manipulation
  • Next by Date: regularize a function (proof function)
  • Previous by thread: Re: List Manipulation
  • Next by thread: Re: StoppingTest options (need help)