# Trajectory

A trajectory or flight path is the path that an object with mass in motion follows through space as a function of time. In classical mechanics, a trajectory is defined by Hamiltonian mechanics via canonical coordinates; hence, a complete trajectory is defined by position and momentum, simultaneously.
The mass might be a projectile or a satellite. For example, it can be an orbit — the path of a planet, asteroid, or comet as it travels around a central mass.
In control theory, a trajectory is a time-ordered set of states of a dynamical system (see e.g. Poincaré map). In discrete mathematics, a trajectory is a sequence $(f^{k}(x))_{k\in \mathbb {N} }$ of values calculated by the iterated application of a mapping $f$ to an element $x$ of its source.

## Physics of trajectories

A familiar example of a trajectory is the path of a projectile, such as a thrown ball or rock. In a significantly simplified model, the object moves only under the influence of a uniform gravitational force field. This can be a good approximation for a rock that is thrown for short distances, for example at the surface of the Moon. In this simple approximation, the trajectory takes the shape of a parabola. Generally when determining trajectories, it may be necessary to account for nonuniform gravitational forces and air resistance (drag and aerodynamics). This is the focus of the discipline of ballistics.
One of the remarkable achievements of Newtonian mechanics was the derivation of Kepler's laws of planetary motion. In the gravitational field of a point mass or a spherically-symmetrical extended mass (such as the Sun), the trajectory of a moving object is a conic section, usually an ellipse or a hyperbola. This agrees with the observed orbits of planets, comets, and artificial spacecraft to a reasonably good approximation, although if a comet passes close to the Sun, then it is also influenced by other forces such as the solar wind and radiation pressure, which modify the orbit and cause the comet to eject material into space.
Newton's theory later developed into the branch of theoretical physics known as classical mechanics. It employs the mathematics of differential calculus (which was also initiated by Newton in his youth). Over the centuries, countless scientists have contributed to the development of these two disciplines. Classical mechanics became a most prominent demonstration of the power of rational thought, i.e. reason, in science as well as technology. It helps to understand and predict an enormous range of phenomena; trajectories are but one example.
Consider a particle of mass $m$, moving in a potential field $V$. Physically speaking, mass represents inertia, and the field $V$ represents external forces of a particular kind known as "conservative". Given $V$ at every relevant position, there is a way to infer the associated force that would act at that position, say from gravity. Not all forces can be expressed in this way, however.
The motion of the particle is described by the second-order differential equation
    $m{\frac {\mathrm {d} ^{2}{\vec {x}}(t)}{\mathrm {d} t^{2}}}=-\nabla V({\vec {x}}(t)){\text{ with }}{\vec {x}}=(x,y,z).$
On the right-hand side, the force is given in terms of $\nabla V$, the gradient of the potential, taken at positions along the trajectory. This is the mathematical form of Newton's second law of motion: force equals mass times acceleration, for such situations.

## Examples
### Uniform gravity, neither drag nor wind

The ideal case of motion of a projectile in a uniform gravitational field in the absence of other forces (such as air drag) was first investigated by Galileo Galilei. To neglect the action of the atmosphere in shaping a trajectory would have been considered a futile hypothesis by practical-minded investigators all through the Middle Ages in Europe. Nevertheless, by anticipating the existence of the vacuum, later to be demonstrated on Earth by his collaborator Evangelista Torricelli, Galileo was able to initiate the future science of mechanics. In a near vacuum, as it turns out for instance on the Moon, his simplified parabolic trajectory proves essentially correct.
In the analysis that follows, we derive the equation of motion of a projectile as measured from an inertial frame at rest with respect to the ground. Associated with the frame is a right-hand coordinate system with its origin at the point of launch of the projectile. The $x$-axis is tangent to the ground, and the $y$axis is perpendicular to it ( parallel to the gravitational field lines ). Let $g$ be the acceleration of gravity. Relative to the flat terrain, let the initial horizontal speed be $v_{h}=v\cos(\theta )$ and the initial vertical speed be $v_{v}=v\sin(\theta )$. It will also be shown that the range is $2v_{h}v_{v}/g$, and the maximum altitude is $v_{v}^{2}/2g$. The maximum range for a given initial speed $v$ is obtained when $v_{h}=v_{v}$, i.e. the initial angle is 45$^{\circ }$. This range is $v^{2}/g$, and the maximum altitude at the maximum range is $v^{2}/(4g)$.

#### Derivation of the equation of motion

Assume the motion of the projectile is being measured from a free fall frame which happens to be at (x,y) = (0,0) at t = 0. The equation of motion of the projectile in this frame (by the equivalence principle) would be $y=x\tan(\theta )$. The co-ordinates of this free-fall frame, with respect to our inertial frame would be $y=-gt^{2}/2$. That is, $y=-g(x/v_{h})^{2}/2$.
Now translating back to the inertial frame the co-ordinates of the projectile becomes $y=x\tan(\theta )-g(x/v_{h})^{2}/2$ That is:
    $y=-{g\sec ^{2}\theta \over 2v_{0}^{2}}x^{2}+x\tan \theta ,$
(where v$_0$ is the initial velocity, $\theta$ is the angle of elevation, and g is the acceleration due to gravity).

#### Range and height

The range, R, is the greatest distance the object travels along the x-axis in the I sector. The initial velocity, v$_i$, is the speed at which said object is launched from the point of origin. The initial angle, θ$_i$, is the angle at which said object is released. The g is the respective gravitational pull on the object within a null-medium.
    $R={v_{i}^{2}\sin 2\theta _{i} \over g}$
The height, h, is the greatest parabolic height said object reaches within its trajectory
    $h={v_{i}^{2}\sin ^{2}\theta _{i} \over 2g}$

#### Angle of elevation

In terms of angle of elevation $\theta$ and initial speed $v$:
    $v_{h}=v\cos \theta ,\quad v_{v}=v\sin \theta \;$
giving the range as
    $R=2v^{2}\cos(\theta )\sin(\theta )/g=v^{2}\sin(2\theta )/g\,.$
This equation can be rearranged to find the angle for a required range
    $\theta ={\frac {1}{2}}\sin ^{-1}\left({\frac {gR}{v^{2}}}\right)$ (Equation II: angle of projectile launch)
Note that the sine function is such that there are two solutions for $\theta$ for a given range $d_{h}$. The angle $\theta$ giving the maximum range can be found by considering the derivative or $R$ with respect to $\theta$ and setting it to zero.
    ${\mathrm {d} R \over \mathrm {d} \theta }={2v^{2} \over g}\cos(2\theta )=0$
which has a nontrivial solution at $2\theta =\pi /2=90^{\circ }$, or $\theta =45^{\circ }$. The maximum range is then $R_{\max }=v^{2}/g\,$. At this angle $\sin(\pi /2)=1$, so the maximum height obtained is ${v^{2} \over 4g}$.
To find the angle giving the maximum height for a given speed calculate the derivative of the maximum height $H=v^{2}\sin ^{2}(\theta )/(2g)$ with respect to $\theta$, that is ${\mathrm {d} H \over \mathrm {d} \theta }=v^{2}2\cos(\theta )\sin(\theta )/(2g)$ which is zero when $\theta =\pi /2=90^{\circ }$. So the maximum height $H_{\mathrm {max} }={v^{2} \over 2g}$ is obtained when the projectile is fired straight up.

### Orbiting objects

If instead of a uniform downwards gravitational force we consider two bodies orbiting with the mutual gravitation between them, we obtain Kepler's laws of planetary motion. The derivation of these was one of the major works of Isaac Newton and provided much of the motivation for the development of differential calculus.

## Catching balls

If a projectile, such as a baseball or cricket ball, travels in a parabolic path, with negligible air resistance, and if a player is positioned so as to catch it as it descends, he sees its angle of elevation increasing continuously throughout its flight. The tangent of the angle of elevation is proportional to the time since the ball was sent into the air, usually by being struck with a bat. Even when the ball is really descending, near the end of its flight, its angle of elevation seen by the player continues to increase. The player therefore sees it as if it were ascending vertically at constant speed. Finding the place from which the ball appears to rise steadily helps the player to position himself correctly to make the catch. If he is too close to the batsman who has hit the ball, it will appear to rise at an accelerating rate. If he is too far from the batsman, it will appear to slow rapidly, and then to descend.