Question: I belive the problem is asking to solve a system of 3 differential equations using the runge kutta method and simulink method. From what i

I belive the problem is asking to solve a system of 3 differential equations using the runge kutta method and simulink method. From what i see the 3 equations are: dy1/dt = y2 * y3 * t ; dy2/dt = -y1 * y3 ; dy3/dt = -0.51 * y1 * y2
The initial conditions appear to be: y1(0) = 0 ; y2(0) = 1 ; y3(0) = 1
Even just the runge kutta method would be helpful.. Thanks!
Solve Example 6.2 on page 111 of textbook, using (1) the 4h order Runge Kutta method and (2) Simulink method, respectively. Please submit your m file and slx file only to Canvas You can use the results from the code attached below (from the textbook by ODE45 solver) as a reference Example 6.2 % ode45 ex.m % This program solves a system of 3 differential equations % by using ode45 function % y1 (0)so, y2 (0)=1.0, y3 (0)=1.0 clear; clc; initials(0 . 0 1 . 0 1.0] ; tspan-0.0:0.1:10.0 options odeset ('RelTol',1.0e-6, 'AbsTol, [1.0e-6 t, Y] ode45 (@dydt3,tspan,initial,options) 1.0e-6 1.0e-6]) disp (P) y1=P ( : , 2 ) ; y2-P(:,3) y3-P(:,4) fide fopen ( output . txt , , , w, ) ; fprintf (fid,' y (2) y(3) In') i=1:2:101 fprintf (fid,' for 6.2f %10.2f %10.2f #20.2 \ n'. end fclose (fid)i plot (t1,Y(:,1) , t 1 , Y ( : , 2 ) , ,-.,,t1,y(:,3),'--'), x1abel('t'), ylabel (Y(1),Y (2),Y(3)),title ('Y vs.t') grid, text (6.o, -1.2, 'y(1)),text (7.7, -0.25,'y(2), text (4.2,0.85,'y(3)) % dydt3.m % functions for example problem function Yprime-dydt3 (t,y) Yprime-zeros (3,1) Yprime (1)-Y (2) Y (3) Yprime (2)Y(1)Y (3) Yprime (3)-0.51*Y (1)Y (2)
Step by Step Solution
There are 3 Steps involved in it
Get step-by-step solutions from verified subject matter experts
