Solving ODE45 for a system with x'=-axy, y'=axy-by, z'=by

  • Context: MATLAB 
  • Thread starter Thread starter mooberrymarz
  • Start date Start date
  • Tags Tags
    Ivp Ode45
Join the discussion
Registration is free. Ask a follow-up in this thread, or start your own.
1 reply · 4K views
mooberrymarz
Messages
53
Reaction score
0
Hi! I have :eek: hand in an assigment in like four hours and part of it involves solving a IVP. We have to use the built in function ODE45. the system of equations are as follows.

x'(t)=-axy
y'(t)=axy-by
z'(t)=by

Use step length 1 and solve the ivp numerically for the following values of a,b
a=0.00001, b=0.25
a=0.0002, b=0.10

I know its easy but i can't get it to work. Please help me. :redface:
 
Physics news on Phys.org
Can you post your code so far, please?