Message Boards Message Boards

0
|
2917 Views
|
1 Reply
|
0 Total Likes
View groups...
Share
Share this post:
GROUPS:

how to graph the result of an ODE

Posted 9 years ago
m = y[t]
NDSolve[{x'[t] == -m - x[t]^2, y'[t] == 2 x[t] - m^3,  x[0] == y[0] == 1}, {x, y}, {t, 20}]

The result show two small curves. How can I graph it on the XOT and YOT plane?

Thanks a lot.

POSTED BY: steve ma

As the manual says

Clear[m, s]
m = y[t];
s = NDSolve[{x'[t] == -m - x[t]^2, y'[t] == 2 x[t] - m^3, x[0] == y[0] == 1}, {x, y}, {t, 20}];
ParametricPlot[{x[t], y[t]} /. s, {t, 0, 20}, AxesLabel -> {"x[t]", "y[t]"}]

with other words

enter image description here

POSTED BY: Udo Krause
Reply to this discussion
Community posts can be styled and formatted using the Markdown syntax.
Reply Preview
Attachments
Remove
or Discard

Group Abstract Group Abstract