How can i solve a this complex differential equation using ode45?

조회 수: 9 (최근 30일)
Abdou Ramane DIALLO
Abdou Ramane DIALLO 2012년 11월 4일
Good morning.
For my training, i would like to solve this differential equation:
(K1*y')^2 + [K1+(K1^2/K2)]*y' - 1 =0
where K1 = sin(y)/[(1+cos(y))*(2-cos(y))]
K2 = 0.31498*cos(y)*sin(y)/[((1+cos(y))^4/3)*((2-cos(y))^5/3)]
I have already tried to solve it with ode45, but as you see, K1 and K2 are funtions of y and the power 2 complicates the equation.
I have 2 weeks to finish it. Please help me by giving me advices.
Thank you
DIALLO

답변 (1개)

Star Strider
Star Strider 2012년 11월 4일
Interesting problem. I suggest you start by considering it a quadratic expression of y', then solving it as a system of two differential equations in y'. Starting with the Symbolic Math Toolbox:
syms K1 K2 dy
yprime = solve( (K1*dy)^2 + [K1+(K1^2/K2)]*dy - 1 == 0, dy )
yields:
yprime =
-(K1 + K2 + (K1^2 + 2*K1*K2 + 5*K2^2)^(1/2))/(2*K1*K2)
-(K1 + K2 - (K1^2 + 2*K1*K2 + 5*K2^2)^(1/2))/(2*K1*K2)
Now you have a system of two first-order differential equations. When I solved it with ode45 with initial conditions of [1 1], I got two curves asymptotic at about ±1.57.

카테고리

Help CenterFile Exchange에서 Symbolic Math Toolbox에 대해 자세히 알아보기

태그

Community Treasure Hunt

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

Start Hunting!

Translated by