Problem with discontinuity in NDSolve[]
- To: mathgroup at smc.vnet.net
- Subject: [mg4301] Problem with discontinuity in NDSolve[]
- From: a_kowald at chemie.fu-berlin.de (Axel Kowald)
- Date: Tue, 9 Jul 1996 00:46:47 -0400
- Organization: Kristallographic Institute FU Berlin
- Sender: owner-wri-mathgroup at wolfram.com
Hi everybody,
I have a problem with NDSolve if my equation contains a discontinuity.
If I try
NDSolve[{y'[t] == 10 - y[t] * If[y[t]-15 <= 0, 0, 1],
y[0] == 0}, y, {t,0,20}]
I always get the error: Maximum number of steps reached.
The solution should be a linear increase until y = 15 followed by an
exponential decay until a steady state is reached by y = 10
Funny enough if I try
NDSolve[{y'[t] == 10 - y[t] * If[t-15 <= 0, 0, 1],
y[0] == 0}, y, {t,0,20}]
causing the discontinuity to be at t = 15 instead of y = 15 NDSolve has no
problems at all. (But of course this is not what I want.)
ANY SOLUTIONS ??? ANY IDEAS ???
Many thanks
Axel Kowald
P.S. I'm using Mma 2.2 on a Mac with 7.5.3 and 24 MB RAM
==== [MESSAGE SEPARATOR] ====