Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]


Groups > comp.soft-sys.math.mathematica > #4642

NDSolve solution does not fulfill boundary condition ??

From Alex <axel.kowald@gmail.com>
Newsgroups comp.soft-sys.math.mathematica
Subject NDSolve solution does not fulfill boundary condition ??
Date 2011-08-29 07:48 +0000
Organization Steven M. Christensen and Associates, Inc and MathTensor, Inc.
Message-ID <j3fg96$fb4$1@smc.vnet.net> (permalink)

Show all headers | View raw


Hello everybody,

I use Mathematica 7 and try to solve and plot a 2nd order ODE like this:

sol = NDSolve[{0 == 4800*O2''[x] + 1500*Exp[-(100*x)^2] - 2000*O2[x],
O2'[-0.5] == 0, O2'[0.5] == 0}, O2, {x, -1, 1}]
Plot[O2[x] /. sol, {x, -1, 1}, PlotRange -> All]

The solution looks ok, i.e. the slope of the solution is 0 at 0.5 and
-0.5, as required by the boundary conditions. But if I slightly change
the parameter values from 1500 to 1000 like this:

sol = NDSolve[{0 == 4800*O2''[x] + 1000*Exp[-(100*x)^2] - 2000*O2[x],
O2'[-0.5] == 0, O2'[0.5] == 0}, O2, {x, -1, 1}]

I get a solution with slope=0 at -0.5, but with a positive slope at
0.5 !!??

How can this be ?  What am I doing wrong ?

Many thanks,

axel

Back to comp.soft-sys.math.mathematica | Previous | Next — Next in thread | Find similar | Unroll thread


Thread

NDSolve solution does not fulfill boundary condition ?? Alex <axel.kowald@gmail.com> - 2011-08-29 07:48 +0000
  Re: NDSolve solution does not fulfill boundary condition ?? Peter Pein <petsie@dordos.net> - 2011-08-29 11:44 +0000
  Re: NDSolve solution does not fulfill boundary condition ?? "Kevin J. McCann" <kjm@KevinMcCann.com> - 2011-08-30 00:01 +0000

csiph-web