Projectile Motion Verification Task
Objective: Verify that your JavaFX projectile motion simulation produces results consistent with manual calculations.
Problem
A cannon is located on the ground (elevation = 0 m). It fires a projectile at an
initial velocity of 50 m/s and an angle of 30° above the horizontal.
Gravity is \( g = 9.80665 \, \mathrm{m/s^2} \) and air resistance is ignored.
Tasks
- Manual calculation:
- Time of flight \(T\) (seconds)
- Maximum altitude \(H_\mathrm{max}\) (meters)
- Range \(R\) (meters)
- Simulation: Set the sliders in the JavaFX app:
- Velocity = 50 m/s
- Angle = 30°
- Elevation = 0 m
Click Fire and record the results.
- Comparison: Compute percentage error using:
\[
\text{Percentage error} = \frac{|\text{Simulation result} - \text{Manual result}|}{\text{Manual result}} \times 100\%
\]
Reference Formulas
Time of flight (starting at elevation \(h = 0\)):
\[
T = \frac{2 v_0 \sin \theta}{g}
\]
Maximum altitude:
\[
H_\mathrm{max} = \frac{(v_0 \sin \theta)^2}{2 g}
\]
Range (starting at elevation \(h = 0\)):
\[
R = \frac{v_0^2 \sin 2\theta}{g}
\]
Where \(v_0\) = initial velocity, \(\theta\) = launch angle, \(g\) = 9.80665 m/s²
Step 1: Manual Solution Example
Given: \(v_0 = 50 \, \mathrm{m/s}, \theta = 30^\circ\)
- Time of flight:
\[
T = \frac{2(50)\sin 30^\circ}{9.80665}
\]
- Maximum altitude:
\[
H_\mathrm{max} = \frac{(50 \cdot 0.5)^2}{2 \cdot 9.80665}
\]
- Range:
\[
R = \frac{50^2 \sin 60^\circ}{9.80665}
\]
Step 2: JavaFX Simulation
Set the sliders according to the problem, click Fire, and record the simulation results:
Step 3: Compare Results
| Quantity |
Manual Calculation |
Simulation Result |
% Error |
| Time (s) |
? |
? |
? |
| Maximum Altitude (m) |
? |
? |
? |
| Range (m) |
? |
? |
? |
Extension Exercises (Submission of manual solution is not needed)
- Vary the cannon elevation above 0 m
- Try different angles: 45°, 60°
- Try different initial velocities: 10–100 m/s
- Verify that simulation values match manual calculations each time