Take the 2-minute tour ×
Mathematica Stack Exchange is a question and answer site for users of Mathematica. It's 100% free, no registration required.

I'm numerically solving the ODE equation $a = -kv$, i.e. $ x'' = -kx'$.

sol = NDSolve[{y''[x] + 0.1 * y'[x] == 0, y[0] == 0, y'[0] == 10}, y, {x, 0, 100}]

I need to do plots of x versus time, v versus time, and v versus x. I figured out how to do the first two plots, but I'm having problems with plotting v versus x (i.e. y' versus y)

share|improve this question
1  
You can try using ParametricPlot for that. –  Leonid Shifrin Jan 24 '13 at 19:02

1 Answer 1

ParametricPlot[{y[t], y'[t]} /. sol[[1]], {t, 0, 100},  AspectRatio -> 1/2,
            PlotRange->FullAxesLabel -> {y[t], y'[t]}, LabelStyle -> Directive[20]]

Mathematica graphics

share|improve this answer

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.