Solving non linear ODE ?

3 ビュー (過去 30 日間)
Dan Matthews
Dan Matthews 2015 年 2 月 25 日
回答済み: Torsten 2015 年 2 月 25 日
I am trying to solve a non-linear ODE
(y'')^2- y^2*(1+y'^2)^(3/2)=0
with boundary conditions: at x=0, y'=0 at x=1, y'= 1
How should I use ode45 or bvp4c to solve this problem ? Thanks

採用された回答

Torsten
Torsten 2015 年 2 月 25 日
function nlinbvp4c
solinit = bvpinit(linspace(0,1,5),[0 0]);
sol = bvp4c(@twoode,@twobc,solinit);
function dydx = twoode(x,y)
dydx = [ y(2); abs(y(1))*(1+y(2)^2)^0.75 ];
function res = twobc(ya,yb)
res = [ ya(2); yb(2) - 1 ];
Not sure, but when solving for y'', you may also take the negative square root of the right-hand side:
y''=-abs(y(1))*(1+y(2)^2)^0.75
Thus there might be two solutions for your problem.
Best wishes
Torsten.

その他の回答 (0 件)

カテゴリ

Help Center および File ExchangeOrdinary Differential Equations についてさらに検索

タグ

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!

Translated by