How do create a function to plot an output projectile motion wth inputs x0,y0,v0x&v0y? x accleration =0,y accleration,g=9.81. using time vector to denote time and two vectors to denote movement x &y direction?

조회 수: 6 (최근 30일)
angle=[0.4, 0.6, pi/4, 1.0, 1.2]; x0=0; y0=0; v0x=0; v0y=0 g=9.81 t=0:.01:500;
x=V0x*cos(angle); y=V0y*sin(angle)-9.8*t; plot(x,y);

답변 (1개)

Mischa Kim
Mischa Kim 2015년 4월 24일
Yeap, I believe you are trying to do something like
x0 = 0;
y0 = 0;
v0 = 10;
angle0 = pi/3;
g = 9.81;
t = 0:.01:3;
x = x0 + v0*cos(angle0)*t;
y = y0 + v0*sin(angle0)*t - g*t.^2/2;
plot(x,y);
v0x and v0y are determined by v0 and the launch angle.

카테고리

Help CenterFile Exchange에서 General Physics에 대해 자세히 알아보기

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!

Translated by