Hello,
I have a three differnetial equations with 8 parameters in total of which 1 parameter p7 actually changes with time (p7=a*b^y*c^z – given for representative purpose, but i have a similar equation for that). How do i solve this with ode45? When i tried i got the following error: Unable to perform assignment because the left and right sides have a different number of elements. This is because the p7 has several values wheras other parametrs have only 1. Can someone help me how to solve ode with changing parameters.
CODE:
dx = zeros(3,1); p7=a*b^y*c^z; dx(1)=((p1.*((x(2)/(x(2)+p2)).*(x(3)/(x(3)+p3)))).*x(1)); dx(2)=((-((1/p4).*(p1.*((x(2)/(x(2)+p2)).*(x(3)/(x(3)+p3)))))+p5).*x(1)); dx(3)=(((-((1/p6).*(p1.*((x(2)/(x(2)+p2)).*(x(3)/(x(3)+p3)))))+p5).*x(1))+(p7.*(p8-x(3))));
Best Answer