non linear coupled diff equation

dx/dt=-(r+r1)/L1*x - dy/dt*(L12/L1)
dy/dt= -y*r2 - dx/dt*(L12/L2
r=300 r1= 8.1 L1=13.8 L2 =0.012 L12=0.0013
Kindly guide in Matal core for above equation using ode23 as r2 is function of time
thanks in advance
Sarat Kumar Dash

4 comentarios

Jan
Jan el 20 de Jul. de 2021
What is "Matal core"?
Sarat
Sarat el 20 de Jul. de 2021
dear Sir
thanks for your resoinse, but I want both x and y and the code in matlab
let me simplyfy the equation as following
dx/dt= -A*x - B*dy/dt
dy/dt= -y*C - dx/dt*D C alone function of time A B D constant
please gice a code in matlab ode23
regards
Jan
Jan el 20 de Jul. de 2021
As written in my answer:
dx/dt= -A*x - B*dy/dt
dy/dt= -y*C - dx/dt*D
is equivalent to:
dx/dt= -A*x - B * (-y*C + A*x*D) / (1 - B*D)
dy/dt = (-y*C + A*x*D) / (1 - B*D)
This should be easy to be implemented, such that an ODE integrator can handle it. Please try it and ask again, if you have a specfic problem.
Sarat
Sarat el 22 de Jul. de 2021
thanks for your reply

Iniciar sesión para comentar.

 Respuesta aceptada

Jan
Jan el 20 de Jul. de 2021
What about simplifying the equations?
1. dx/dt = -(r+r1)/L1*x - dy/dt * (L12/L1)
2. dy/dt = -y*r2 - dx/dt * (L12/L2)
1. into 2.:
dy/dt = -y*r2 - (-(r+r1) / L1 * x - dy/dt * (L12/L1)) * (L12/L2)
= -y*r2 + ((r+r1) / L1 * x + dy/dt * (L12/L1)) * (L12/L2)
= -y*r2 + (r+r1) / L1 * x * (L12 / L2) + dy/dt * L12^2 / (L1*L2)
dy/dt - dy/dt * L12^2 / (L1*L2) = -y*r2 + (r+r1) / L1 * x * (L12 / L2)
dy/dt (1 - L12^2 / (L1*L2)) = -y*r2 + (r+r1) / L1 * x * (L12 / L2)
dy/dt = (-y*r2 + (r+r1) / L1 * x * (L12 / L2)) / (1 - L12^2 / (L1*L2));
Insert this in 1 again.
Do I oversee a point?

Más respuestas (0)

Categorías

Más información sobre Programming en Centro de ayuda y File Exchange.

Productos

Versión

R2017b

Etiquetas

Preguntada:

el 20 de Jul. de 2021

Comentada:

el 22 de Jul. de 2021

Community Treasure Hunt

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

Start Hunting!

Translated by