I made this 2D animation of a projectile motion:
clcclear allh=input('Set high: ');v0=input('Set initial speed: ');N=input('Set angle: ');hold on;syms tg = 9.80665;rad=N*pi/180; V0x=v0.*cos(rad); V0y=v0.*sin(rad);Y=h+(V0y*t)-(g/2*(t^2));E=solve(Y,t);t=0:0.008:double(E(2));y=h+(V0y*t)-(g/2*(t.^2)); x=(V0x*t);axis([x(1) x(end) min(y) max(y)]) for i=1:length(t)-1comet(x(i:i+1),y(i:i+1))pause(.05)grid onend
I need to transform the animation of this projectile motion into a 3D animation. What's the best way to do it? Thanks for your help.
Best Answer