non linear differential equation

Réponses (1)

Azzi Abdelmalek
Azzi Abdelmalek le 30 Nov 2012
Modifié(e) : Azzi Abdelmalek le 30 Nov 2012

0 votes

function dq=myeq(t,q,t1,u1,a1,b1)
u=interp1(t1,u1,t)
dq=-q+a1+b1+1/u^2;
%Then call myeq
a1=1;
b1=2;
q0=0;
t1=1:0.1:10; % vector time
u1=t1.^2 % your vector u
[t q]=ode45(@(t,q) myeq(t,q,t1,u1,a1,b1),t1,q0)
plot(t,q)

Catégories

En savoir plus sur Numerical Integration and Differential Equations dans Centre d'aide et File Exchange

Produits

Question posée :

le 30 Nov 2012

Community Treasure Hunt

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

Start Hunting!

Translated by