- #1
python
- 7
- 0
Homework Statement
I'm currently in computer programming class, and I've finished a project and want to improve on it. We had to figure out how to calculate the gravitational acceleration and time traveled of a projectile to hit a target. I'd like to add horizontal variables in my code, like wind resistance left and right. What would the formula be for something like this? The user inputs the initial velocity and also the launch angle.
v = velocity
r = launch angle in radians
g = gravitational acceleration
Homework Equations
time of travel = 2 * v * sin(r) / 32
distance = velocity * cos(r) * time
The Attempt at a Solution
No attempt, don't know the correct equation.