MathGroup Archive 2008

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

Search the Archive

How do I reformulate my NDSolve program

  • To: mathgroup at
  • Subject: [mg86173] How do I reformulate my NDSolve program
  • From: Alex Cloninger <acloninger at>
  • Date: Tue, 4 Mar 2008 02:10:19 -0500 (EST)

So I am trying to run plots of the following coupled differential equations, specifically for epsilon=1/2:

solution = NDSolve[{x'[t] == 2p[t], x[0] == 0,
p'[t] == i*(2 + ϵ)(i*x[t])^(1 + ϵ), p[0] == 1}, {x, p}, {t,0,10}, WorkingPrecision -> 40, MaxSteps ->Infinity][[1]];

I then want to plot the p[t] in the complex plane: 

ParametricPlot[{Re[p[t]] /. solution, Im[p[t]] /. solution}, Evaluate[time],PlotRange -> {{-2, 2}, {-2, 2}}]

The problem with this is that my plot has a sharp change in slope at (1,0) (t=5.6 or so).  What should happen is that the line continues past p=1 and extends out into a small loop before coming back, crossing over itself, and continuing along the larger loop.  I know that the reason the graph isn't appearing correct has to do with the fact that I'm raising x[t] to a fractional power (epsilon=1/2).  Mathematica isn't realizing that it has hit a branch cut and is taking the wrong root.

I have two questions.  1) How would I be able to identify these points of discontinuities in slope on a more complicated graph (I want to be able to do this for any positive rational epsilon)?  2) How would I go about fixing the problem so that Mathematica takes the correct root and continues in the correct direction?

Thanks for your help,

PS. I have version 5.2, but I have access to a better version if there's something in it that would help me.

  • Prev by Date: Re: Drawing Tools in 6.0.2
  • Next by Date: Re: Drawing Tools in 6.0.2
  • Previous by thread: Re: Hi, please help to resolve this time delay problem. thanks in
  • Next by thread: Re: How do I reformulate my NDSolve program