The question is: Use MATLAB to display in one figure the effects of the angle ? on ? for h0 = 30 and h0 = 40. Assume ? /16<?<7?/16
? =((h0.^(5/2)).*2.*(tan((pi./2)-theta)).^2)./(5*a.^2.*sqrt(2*g)) where ? is time in seconds
h0(cm), a(cm) and g(cm/s^2) are constants, theta is on the x axis and tau is on the y axis. The range is pi/16 to 7pi/16 with increments of pi/16 (so 7 curves)
I would like to plot all 14 curves on the same figure (7 for when h0=30 and 7 for when h0=40) but I am unsure how to do this. Even for one value of h0, the graph is empty when I run the code.
Thank you.
h0=30;a=1;g=9.81*100; for theta=pi/16:pi/16:7.*pi/16 tau=((h0.^(5/2)).*2.*(tan((pi./2)-theta)).^2)./(5*a.^2.*sqrt(2*g)); endplot(theta,tau)
Best Answer