필터 지우기
필터 지우기

Am I doing this correctly? Projectile code

조회 수: 1 (최근 30일)
Aaron Zorzi
Aaron Zorzi 2016년 2월 9일
Hi, I just was hoping to double check these results I'm getting, because I'm worried they may be off. These are the formulas/variables I was meant to use:
And then, using symbolic toolbox, I created a code to solve for V and Theta:
f1 = sym('1600 = -1/2*9.81*10^2 + V*sin(Theta)*10 + 0')
f2 = sym('1200 = V*cos(Theta)*10 + 0')
result = solve(f1,f2,'V','Theta')
V = result.V
Theta = result.Theta
Valid Initial Velocity, Vo = 241.04336 (m/s)
Valid Launch Angle, θ = 1.04969
I was then meant to check my results by plotting them with vectors. This is the part I am worried about, as I don't know much about physics, so I don't know if this looks right. Any and all help appreciated, thank you.
time = 0:1:10;
y = -1/2*9.81*time.^2 + 241.04336*sin(1.04969)*time - 1600;
x = 241.04336*cos(1.04969)*time - 1200;
plot(x,y)
title('Projectile')
ylabel('Projectile Height (m)')
xlabel('Projectile Range (m)')

답변 (0개)

카테고리

Help CenterFile Exchange에서 Symbolic Math Toolbox에 대해 자세히 알아보기

Community Treasure Hunt

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

Start Hunting!

Translated by