Mathematica 9 is now available
Student Support Forum
-----
Student Support Forum: 'Piecewise Equations' topicStudent Support Forum > General > "Piecewise Equations"

Help | Reply To Topic
Author Comment/Response
Sejabs
04/29/11 03:12am

I have faced a Differential Equations with Piecewise conditions as follows:
NDSolve[{x'[t] == x[t] + 1, y'[t] == \[Piecewise] {
{y[t], x[2] > 5},
{1, x[2] <= 5}
}, x[0] == 1, y[0] == 1}, {x, y}, {t, 0, 5},
]

But Mathematica could not handle "x[2] > 5" and "x[2] <= 5" conditions. How to solve this problem?

URL: ,
Help | Reply To Topic