Updates to SIM_cannon_analytic README
@ -1,48 +1,47 @@
|
||||
#SIM\_cannon\_analytic
|
||||
---
|
||||
This is first of eight Trick-based simulations that one builds in the Trick
|
||||
Tutorial (Section 3). It's purpose is to introduce the fundamentals of building
|
||||
a Trick simulation.
|
||||
Tutorial (Section 3). It's purpose is to introduce some of the fundamentals
|
||||
of building a Trick simulation.
|
||||
|
||||
Here we simulate the flight of a cannon ball, given an initial position, and
|
||||
velocity subject to the following assumptions and limitations:
|
||||
Here we simulate the flight of a cannon ball. We want to know the position and velocity of the cannon ball over time, given an initial position, and
|
||||
velocity, and subject to the following assumptions and limitations:
|
||||
|
||||
* The **only** force acting on the cannon ball is gravity.
|
||||
* The acceleration of gravity (g) is constant and equal to -9.81 meters per
|
||||
second squared.
|
||||
* The surface of the ground is defined as where y=0.
|
||||
|
||||

|
||||

|
||||
|
||||
--
|
||||
### Approach
|
||||
### Solution
|
||||
|
||||
Since this problem has a closed-form solution, that's what we use :
|
||||
This problem has a closed-form solution, so that's what is used.
|
||||
|
||||

|
||||

|
||||
|
||||

|
||||

|
||||
|
||||
The time when the cannon ball impacts the ground is:
|
||||

|
||||
|
||||

|
||||
|
||||

|
||||
|
||||

|
||||
|
||||
The cannon ball will impact the ground, when y(t)=0 at:
|
||||
|
||||

|
||||
|
||||
--
|
||||
### Inputs
|
||||
Variable | Type | Units
|
||||
-----------------------|----------------|-------
|
||||
dyn.cannon.pos0 | double[2] | m
|
||||
dyn.cannon.init\_angle | double | r
|
||||
dyn.cannon.init\_speed | double | m/s
|
||||
|
||||
The initial velocity is :
|
||||
### CANNON Object
|
||||
Model Variable | Simulation Variable | Type | Units
|
||||
--------------------------------------------|---------------------|---------|-------
|
||||
,  | CANNON.pos0[2] |double[2]| m
|
||||
, | CANNON.vel0[2] |double[2]| m/s
|
||||
 | CANNON.init\_angle |double | r
|
||||
 | CANNON.init\_speed |double | m/s
|
||||
 | CANNON.pos[2] |double[2]| m
|
||||
 | CANNON.vel[2] |double[2]| m/s
|
||||
|
||||
,
|
||||

|
||||
|
||||
--
|
||||
### Outputs
|
||||
Variable | Type | Units
|
||||
-----------------------|----------------|--------
|
||||
dyn.cannon.pos | double[2] | m
|
||||
dyn.cannon.vel | double[2] | m/s
|
||||
|
Before Width: | Height: | Size: 45 KiB After Width: | Height: | Size: 45 KiB |
BIN
trick_sims/SIM_cannon_analytic/images/init_v_x_0.png
Normal file
After Width: | Height: | Size: 824 B |
BIN
trick_sims/SIM_cannon_analytic/images/init_v_y_0.png
Normal file
After Width: | Height: | Size: 844 B |
Before Width: | Height: | Size: 1.1 KiB |
Before Width: | Height: | Size: 1.1 KiB |
BIN
trick_sims/SIM_cannon_analytic/images/param_s.png
Normal file
After Width: | Height: | Size: 373 B |
BIN
trick_sims/SIM_cannon_analytic/images/param_theta.png
Normal file
After Width: | Height: | Size: 359 B |
BIN
trick_sims/SIM_cannon_analytic/images/solution_vx.png
Normal file
After Width: | Height: | Size: 712 B |
BIN
trick_sims/SIM_cannon_analytic/images/solution_vy.png
Normal file
After Width: | Height: | Size: 1.1 KiB |
Before Width: | Height: | Size: 846 B After Width: | Height: | Size: 873 B |
Before Width: | Height: | Size: 1.2 KiB After Width: | Height: | Size: 925 B |
Before Width: | Height: | Size: 1.5 KiB After Width: | Height: | Size: 1.8 KiB |
BIN
trick_sims/SIM_cannon_analytic/images/v_x.png
Normal file
After Width: | Height: | Size: 569 B |
BIN
trick_sims/SIM_cannon_analytic/images/v_x_0.png
Normal file
After Width: | Height: | Size: 433 B |
BIN
trick_sims/SIM_cannon_analytic/images/v_y.png
Normal file
After Width: | Height: | Size: 586 B |
BIN
trick_sims/SIM_cannon_analytic/images/v_y_0.png
Normal file
After Width: | Height: | Size: 464 B |
BIN
trick_sims/SIM_cannon_analytic/images/vector_v.png
Normal file
After Width: | Height: | Size: 366 B |
BIN
trick_sims/SIM_cannon_analytic/images/vector_x.png
Normal file
After Width: | Height: | Size: 372 B |
BIN
trick_sims/SIM_cannon_analytic/images/x_0.png
Normal file
After Width: | Height: | Size: 406 B |
BIN
trick_sims/SIM_cannon_analytic/images/y_0.png
Normal file
After Width: | Height: | Size: 409 B |