Help solving differential equations
Mostrar comentarios más antiguos
Hello,
I need helping a differential equation using ode45().
I have the following statements and need to find tmax:
A(t) = dA/dt = -k0*A
A(0) = A0
B(t) = dB/dt = k0*A - k1*B
B(0) = 0
E(t) = dE/dt = k1*B
E(0) = 0
k0 = 0.01
k1 = 0.035
2 comentarios
Stephan
el 6 de Mayo de 2022
Please provide the code you have so far.
Juan Lara Alcaraz
el 6 de Mayo de 2022
Respuesta aceptada
Más respuestas (1)
Torsten
el 6 de Mayo de 2022
syms k0 k1 A0 A(t) B(t) E(t)
eqns = [diff(A,t)==-k0*A,diff(B,t)==k0*A-k1*B,diff(E,t)==k1*B];
conds = [A(0)==A0,B(0)==0,E(0)==0]
[Asol(t),Bsol(t),Esol(t)]=dsolve(eqns,conds)
2 comentarios
Juan Lara Alcaraz
el 7 de Mayo de 2022
Torsten
el 7 de Mayo de 2022
Yes. The equations are that easy that they can be solved using pencil and paper.
Categorías
Más información sobre Programming en Centro de ayuda y File Exchange.
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!

