projetil 3d

22
CANADIAN APPLIED MATHEMATICS QUARTERLY Volume 19, Number 1, Spring 2011 OPTIMIZATION OF PROJECTILE MOTION IN THREE DIMENSIONS ROBERT KANTROWITZ AND MICHAEL M. NEUMANN ABSTRACT. This article addresses the motion of a projec- tile that is launched from the top of a tower and lands on a given surface in space. The goal is to determine explicit and manageable formulas for the direction of launch in space that allows the projectile to travel as far as possible. While the clas- sical critical point method fails to produce a solution formula even in the special case of shooting to a slanted plane, here we develop a different general approach that leads to remarkably simple equations and solution formulas. Our method is in the spirit of Lagrange multipliers and tailored to motion in three dimensions. Essentially, the optimization problem is reduced to the solution of three equations of geometric type. One of these conditions just means that the Jacobian determinant for the position function of the projectile has to vanish at an optimal solution. It turns out that the theory works well even in the more general setting of launch from a moving vehicle. Appli- cations are given to the case of motion without air resistance and also to the case when the retarding force is proportional to the velocity of the projectile. In particular, surprisingly simple explicit solution formulas are derived for the case of shooting to a slanted plane. 1 Introduction and motivation As an introductory example, we consider the following classical model for the motion of a projectile in space. Given a tower of height h> 0, we suppose that the projectile is launched at time t = 0 with initial position (0, 0,h), muzzle speed s> 0, angle of inclination θ with respect to the plane z = h, and polar angle ϕ with respect to the xy-plane. Ignoring, for now, air resistance and other possible forces, we assume that the motion of the projectile is governed only by constant acceleration of magnitude g> 0 due to gravity in the direction of the negative z -axis. The position vector hx(t),y(t),z (t)i of the projectile at time t 0 is then provided by the standard parametric AMS subject classification: Primary 49K99; secondary 70B05. Keywords: Lagrange multipliers, projectile ballistics, Lambert W function. Copyright c Applied Mathematics Institute, University of Alberta. 43

Upload: yonymmilla

Post on 20-Jul-2016

28 views

Category:

Documents


0 download

TRANSCRIPT

Page 1: projetil 3D

CANADIAN APPLIED

MATHEMATICS QUARTERLY

Volume 19, Number 1, Spring 2011

OPTIMIZATION OF PROJECTILE MOTION

IN THREE DIMENSIONS

ROBERT KANTROWITZ AND MICHAEL M. NEUMANN

ABSTRACT. This article addresses the motion of a projec-tile that is launched from the top of a tower and lands on agiven surface in space. The goal is to determine explicit andmanageable formulas for the direction of launch in space thatallows the projectile to travel as far as possible. While the clas-sical critical point method fails to produce a solution formulaeven in the special case of shooting to a slanted plane, here wedevelop a different general approach that leads to remarkablysimple equations and solution formulas. Our method is in thespirit of Lagrange multipliers and tailored to motion in threedimensions. Essentially, the optimization problem is reduced tothe solution of three equations of geometric type. One of theseconditions just means that the Jacobian determinant for theposition function of the projectile has to vanish at an optimalsolution. It turns out that the theory works well even in themore general setting of launch from a moving vehicle. Appli-cations are given to the case of motion without air resistanceand also to the case when the retarding force is proportional tothe velocity of the projectile. In particular, surprisingly simpleexplicit solution formulas are derived for the case of shootingto a slanted plane.

1 Introduction and motivation As an introductory example, weconsider the following classical model for the motion of a projectile inspace. Given a tower of height h > 0, we suppose that the projectile islaunched at time t = 0 with initial position (0, 0, h), muzzle speed s > 0,angle of inclination θ with respect to the plane z = h, and polar angle ϕwith respect to the xy-plane. Ignoring, for now, air resistance and otherpossible forces, we assume that the motion of the projectile is governedonly by constant acceleration of magnitude g > 0 due to gravity in thedirection of the negative z-axis. The position vector 〈x(t), y(t), z(t)〉 ofthe projectile at time t ≥ 0 is then provided by the standard parametric

AMS subject classification: Primary 49K99; secondary 70B05.Keywords: Lagrange multipliers, projectile ballistics, Lambert W function.

Copyright c©Applied Mathematics Institute, University of Alberta.

43

Page 2: projetil 3D

44 R. KANTROWITZ AND M. M. NEUMANN

equations

x(t) = s cos θ cosϕ·t, y(t) = s cos θ sinϕ·t, z(t) = h+s sin θ ·t−1

2gt2,

valid for all t ≥ 0 for which the projectile stays in the air until it hitsa surface represented here by the graph of a function z = f(x, y) or,more generally, a level surface of the form ψ(x, y, z) = 0. To emphasizethe dependence on the two launch angles θ and ϕ, we write r(t, θ, ϕ) =〈x(t, θ, ϕ), y(t, θ, ϕ), z(t, θ, ϕ)〉 for the position of the projectile at time twhen launched with θ and ϕ.

Now suppose that the task is to find angles θ and ϕ that allow theprojectile to travel as far as possible in a given direction that, after asuitable choice of the coordinate system, may be taken to be the directionof the positive x-axis. Thus we are interested in the maximization ofx(t, θ, ϕ) subject to the constraint ψ (r(t, θ, ϕ)) = 0. Of course, whenψ(x, y, z) = z, and also in other simple cases, it is obvious that theoptimal launch occurs for ϕ = 0, which reduces the setting to motion inthe xz-plane and the task to finding only the optimal angle of elevationθ. However, in general, both θ and ϕ need to be determined.

A typical example is the case of shooting to a slanted plane with anequation of the form z = βx + γy for given real constants β and γ. Anatural approach to the corresponding optimization problem is to firstsolve the impact condition

z(t, θ, ϕ) = βx(t, θ, ϕ) + γy(t, θ, ϕ)

for t > 0 in terms of θ and ϕ. An elementary solution of this quadraticequation results in an explicit formula for the unique impact time t =t(θ, ϕ) > 0 that also depends on the five parameters g, h, s, β and γ.We are thus led to the problem of maximizing

d(θ, ϕ) = x(t(θ, ϕ), θ, ϕ).

Unfortunately, the critical point equations dθ(θ, ϕ) = 0 and dϕ(θ, ϕ) = 0for this unconstrained optimization problem are much too hard for apaper-and-pencil approach and even for computer algebra systems: itturns out that both Mathematica and Maple run out of memory whentrying to solve this pair of equations.

In fact, as already observed in [5, 6, 7], the critical point approachis unsatisfactory even for the two-dimensional version of this optimiza-tion problem where there is no dependence on the polar angle ϕ. More

Page 3: projetil 3D

OPTIMIZATION OF PROJECTILE MOTION 45

precisely, if the goal is to maximize x(t, θ, 0) subject to the constraintz(t, θ, 0) = βx(t, θ, 0), then computer algebra systems do provide solu-tions to the corresponding critical point equation in this one-variablespecial case. For example, after suitable simplification, version 6.0 ofMathematica yields eight solutions of the critical point equation for θ,namely,(1)

± arccos

0

s

2g2h2 + 3ghs2 + (1 + β2) s4 ±

p

β2s6 (2gh+ (1 + β2) s2)

2 (g2h2 + 2ghs2 + (1 + β2) s4)

1

A

together with the disclaimer that some solutions may not have beenfound. However, such a solution formula for the optimal angle θ isextremely complicated, and the unspecified ± signs make it almost im-possible to understand how each of the parameters g, h, s, and β affectsθ when all the other parameters are kept constant. For instance, onemight expect θ to be a decreasing function of h, but this is hard to inferfrom (1).

In this article, we develop a different approach to optimization prob-lems of this type for general projectile motion in space. Our method isin the spirit of Lagrange multipliers and may be viewed as an extensionof the two-dimensional theory from our recent article [5]. For classicalaccounts, we refer to [1, 2, 9].

In order to be able to handle a variety of examples, we consider anarbitrary function ρ(x, y, z) that plays the role of a generalized distancefunction. Typical choices for ρ(x, y, z) are

x, z, x2 + y2, x2 + y2 + z2 and x2 + y2 + (z − h)2,

as well as the square roots of the last three expressions.We are then interested in the optimization of ρ (r(t, θ, ϕ)) subject to

the constraint ψ (r(t, θ, ϕ)) = 0, where r(t, θ, ϕ) represents the motionof an arbitrary projectile, thus including, for example, the possibility ofair resistance. From the Lagrange multiplier theorem we derive, in The-orem 2, two necessary conditions for the solutions of this optimizationproblem. One of these conditions simply means that the Jacobian deter-minant for the position function r has to vanish at an optimal solution(t, θ, ϕ). Not only for motion without air resistance, but also for the casewhen air resistance is proportional to the velocity of the projectile, theJacobian condition leads to a remarkably simple equation with a strikinggeometric interpretation. The other condition involves certain cross anddot products for the gradients of ρ, ψ, and r and is again of geometrictype.

Page 4: projetil 3D

46 R. KANTROWITZ AND M. M. NEUMANN

Our applications will illustrate that, in many cases, these two condi-tions allow us to express both the optimal polar angle ϕ and the impacttime t for optimal launch in terms of the optimal angle of elevation θ.The optimization problem is therefore reduced to the solution of an im-pact equation for the one remaining variable θ. In fact, our approachextends to a more general setting where the projectile is launched froma moving vehicle such as a car or a hot air balloon.

In particular, we obtain, in Theorem 3, amazingly simple explicitsolution formulas for the above-mentioned case of launching to a slantedplane, where the critical point approach fails miserably. This will alsoshed new light on the solution formula (1) for the two-dimensional case.Moreover, our approach leads to a surprisingly short expression for themaximal distance that the projectile is able to travel.

2 General principles Although the emphasis of this article is onoptimization in three dimensions, we begin with a brief discussion of theconceptually much simpler case of two dimensions. This case will serveas a motivation for our approach in three dimensions and is, of course,of independent interest.

In the following result, we consider open subsets Γ and Ω of R2 and

continuously differentiable real-valued functions ρ and ψ on Ω. Also, letr : Γ → Ω be a transformation from Γ into Ω with continuously differen-tiable component functions x and y on Γ, so that r(t, θ) = 〈x(t, θ), y(t, θ)〉for all (t, θ) ∈ Γ.

In this general setting, we are interested in the optimization ofρ (r(t, θ)) over all points (t, θ) ∈ Γ that satisfy the condition ψ (r(t, θ)) =0. Such an optimization problem may be addressed by the method ofLagrange multipliers. Here our goal is to rewrite the classical Lagrangeequations for the compositions ρr and ψ r directly in terms of certainJacobian determinants for the single functions ρ, ψ, and r.

Theorem 1. Suppose that the point (t, θ) ∈ Γ provides a local extremum

of the composition ρ r subject to the constraint ψ (r(t, θ)) = 0. Then

ρx(r(t, θ)) ρy(r(t, θ))

ψx(r(t, θ)) ψy(r(t, θ))

= 0 or

xt(t, θ) xθ(t, θ)

yt(t, θ) yθ(t, θ)

= 0.

Proof. An application of the Lagrange multiplier theorem to the com-positions u = ρ r and v = ψ r on Γ shows that either ∇v(t, θ) isthe zero vector or that ∇u(t, θ) = λ∇v(t, θ) for some λ ∈ R. This means

Page 5: projetil 3D

OPTIMIZATION OF PROJECTILE MOTION 47

that the list of vectors (∇u(t, θ),∇v(t, θ)) is linearly dependent and thussatisfies

ut(t, θ) uθ(t, θ)

vt(t, θ) vθ(t, θ)

= 0.

On the other hand, the multivariate chain rule guarantees that

"

ut(t, θ) uθ(t, θ)

vt(t, θ) vθ(t, θ)

#

=

"

ρx(r(t, θ)) ρy(r(t, θ))

ψx(r(t, θ)) ψy(r(t, θ))

# "

xt(t, θ) xθ(t, θ)

yt(t, θ) yθ(t, θ)

#

.

Since the determinant of the product of two matrices is equal to theproduct of their determinants, we conclude that the determinant of atleast one of the last two matrices is zero, as desired.

Of particular interest is the case when the constraint function ψ isinduced by the graph of a function of one variable, in the sense thatψ(x, y) = y − f(x) for some continuously differentiable function f. Inthis case, for arbitrary (t, θ) for which y(t, θ) = f(x(t, θ)), we have

˛

˛

˛

˛

˛

ρx(r(t, θ)) ρy(r(t, θ))

ψx(r(t, θ)) ψy(r(t, θ))

˛

˛

˛

˛

˛

= ρx(r(t, θ)) + ρy(r(t, θ))f ′(x(t, θ)) = σ′(x(t, θ)),

where the function σ is given by σ(x) = ρ(x, f(x)). Thus, in the settingof Theorem 1, we conclude that either x(t, θ) is a critical point of σ orthat

xt(t, θ)yθ(t, θ) = xθ(t, θ)yt(t, θ).

This special case of Theorem 1 was recently obtained in Theorem 1 of [5]with a somewhat different approach. The result turned out to be quiteuseful for the optimization theory of projectile motion in two dimensions.In particular, Section 4.2 of [5] provides an example to illustrate thatit is essential to include the critical points of σ in this context. Thisshows that, in general, the first alternative in the conclusion of Theorem1 cannot be excluded.

To establish a certain counterpart of the preceding result in threedimensions, we now consider a pair of open subsets Γ and Ω of R

3. Also,let ρ and ψ denote continuously differentiable real-valued functions on Ω,and let r : Γ → Ω be a transformation from Γ into Ω with continuouslydifferentiable component functions x, y, and z on Γ, so that

r(t, θ, ϕ) = 〈x(t, θ, ϕ), y(t, θ, ϕ), z(t, θ, ϕ)〉

Page 6: projetil 3D

48 R. KANTROWITZ AND M. M. NEUMANN

for all (t, θ, ϕ) ∈ Γ. As usual,

J =

xt xθ xϕ

yt yθ yϕ

zt zθ zϕ

stands for the Jacobian determinant of the transformation r. In thissetting, we obtain the following main general result of this article.

Theorem 2. Suppose that the point (t, θ, ϕ) ∈ Γ provides a local ex-

tremum of the composition ρr subject to the constraint ψ (r(t, θ, ϕ)) = 0.Then the identities

(2)

(rt × rθ) · [(∇ρ×∇ψ) r] = 0,

(rθ × rϕ) · [(∇ρ×∇ψ) r] = 0,

(rϕ × rt) · [(∇ρ×∇ψ) r] = 0,

hold at the point (t, θ, ϕ). Moreover, we have either

(∇ρ×∇ψ) (r(t, θ, ϕ)) = 0 or J(t, θ, ϕ) = 0.

Finally, if (rθ × rϕ) (t, θ, ϕ) is nonzero, then the three equations in (2)are satisfied at the point (t, θ, ϕ) precisely when either

(∇ρ×∇ψ) (r(t, θ, ϕ)) = 0

or the two identities

J = 0 and (rθ × rϕ) · [(∇ρ×∇ψ) r] = 0

hold at the point (t, θ, ϕ). A similar characterization obtains when either

(rt × rθ) (t, θ, ϕ) or (rϕ × rt) (t, θ, ϕ) is nonzero.

The proof of this theorem will be given in the next section. As illus-trated by Theorems 3 and 5 below and also by the additional examplesat the end of Section 4, it turns out that, in many important cases, bothcross products rθ ×rϕ and ∇ρ×∇ψ are nonzero at all points of interest.To maximize ρ (r(t, θ, ϕ)) subject to the constraint ψ (r(t, θ, ϕ)) = 0, itthen suffices, by Theorem 2, to solve the three equations

(3)

J(t, θ, ϕ) = 0,

(rθ × rϕ) (t, θ, ϕ) · (∇ρ×∇ψ) (r(t, θ, ϕ)) = 0,

ψ (r(t, θ, ϕ)) = 0,

Page 7: projetil 3D

OPTIMIZATION OF PROJECTILE MOTION 49

for (t, θ, ϕ) ∈ Γ. In our applications to optimization problems for themotion of projectiles, we will see that the first and second of these equa-tions are amazingly simple, not only for motion without air resistance,but also for the case when air resistance is proportional to the velocity ofthe projectile. This will allow us to eliminate both t and ϕ and thus toreduce the three-dimensional constrained optimization problem to thesolution of just one impact equation for the single variable θ.

As in the case of two dimensions, of special interest is the case of aconstraint function of the form ψ(x, y, z) = z − f(x, y) for some contin-uously differentiable function f. If (t, θ, ϕ) is a point that satisfies bothz(t, θ, ϕ) = f(x(t, θ, ϕ), y(t, θ, ϕ)) and (∇ρ×∇ψ) (r(t, θ, ϕ)) = 0, then itis easily seen that (x(t, θ, ϕ), y(t, θ, ϕ)) is a critical point of the functionσ given by

σ(x, y) = ρ (x, y, f(x, y)) .

Thus, in the setting of Theorem 2, we obtain that either (x(t, θ, ϕ),y(t, θ, ϕ)) is a critical point of σ or that J(t, θ, ϕ) = 0.

3 Proof of the main result We first collect a few tools from linearalgebra. Throughout this discussion, let p and q be two column vectorsin R

3, and let A denote a real 3 × 3 matrix with row vectors a, b, andc. We will repeatedly use the fact that the cross product and the dotproduct in R

3 are related by the formula

(4) (a× b) · (p× q) =

a · p b · pa · q b · q

,

which may be verified by a routine computation. Moreover, the list(p, q) is linearly dependent precisely when p× q is the zero vector. Herewe are interested in certain geometric conditions on A, p, and q thatcharacterize the linear dependence of the list (Ap,Aq).

Lemma 1. The list (Ap,Aq) is linearly dependent precisely when the

following conditions are fulfilled:

(5)

(a× b) · (p× q) = 0,

(b× c) · (p× q) = 0,

(c× a) · (p× q) = 0.

Proof. Suppose first that (Ap,Aq) is linearly dependent. If both Apand Aq are nonzero, then there exists a nonzero scalar λ ∈ R for which

Page 8: projetil 3D

50 R. KANTROWITZ AND M. M. NEUMANN

Aq = λAp and therefore,

a · q = λa · p, b · q = λb · p and c · q = λc · p.

Pairwise cross-multiplication of these three equations followed by can-cellation of λ yields the system:

(6)

(a · p) (b · q) = (a · q) (b · p) ,

(b · p) (c · q) = (b · q) (c · p) ,

(c · p) (a · q) = (c · q) (a · p) .

Evidently, the preceding identities remain valid if one of the vectors Apor Aq is the zero vector, since this happens precisely when a · p = b · p =c · p = 0 or a · q = b · q = c · q = 0. Consequently, in either case, formula(4) allows us to conclude from (6) that the three identities in (5) are allsatisfied.

Conversely, suppose that (5) holds. Then, again by (4), we infer that(6) is fulfilled. To show that (Ap,Aq) is linearly dependent, it sufficesto consider the case when Ap is nonzero. Without loss of generality,we may assume that a · p 6= 0. With the choice λ = (a · q) / (a · p) weconclude from (6) that Aq = λAp, as desired.

If the list (p, q) happens to be linearly dependent or if the span ofthe list (a, b, c) is at most one dimensional, then it is easily seen thatall the conditions of Lemma 1 are fulfilled. Hence, the result is of realinterest only when (p, q) is linearly independent and the dimension ofthe span of (a, b, c) is at least two. In the latter case, we obtain a usefulcharacterization that involves the determinant of A.

Lemma 2. If the list (Ap,Aq) is linearly dependent, then either

p× q = 0 or |A| = 0.

Moreover, if a×b is not the zero vector, then the list (Ap,Aq) is linearly

dependent if and only if either p× q = 0 or we have both

|A| = 0 and (a× b) · (p× q) = 0.

Proof. Suppose first that the list (Ap,Aq) is linearly dependent. If p×qis nonzero, then the list (p, q) is linearly independent, and it follows that

Page 9: projetil 3D

OPTIMIZATION OF PROJECTILE MOTION 51

A fails to be invertible. Thus |A| = 0, and the identity (a× b) · (p× q) =0 is immediate from Lemma 1.

Conversely, if p× q = 0, then the list (p, q) is linearly dependent, andtherefore so is (Ap,Aq). On the other hand, if |A| = 0, then the list(a, b, c) is linearly dependent. But the list (a, b) is linearly independentprovided that a × b is nonzero. Consequently, in this case, we obtainthe representation c = λa+µb for suitable λ, µ ∈ R. Hence, the identity(a× b) · (p× q) = 0 implies that

(b× c) · (p× q) = λ(b× a) · (p× q) + µ(b× b) · (p× q) = 0

and similarly (c×a) · (p× q) = 0. Again by Lemma 1, it follows that thelist (Ap,Aq) is linearly dependent.

Obviously, if either (b, c) or (c, a) is linearly independent, then Lemma2 remains valid once its last identity is replaced by (b× c) · (p×q) = 0 or(c×a) · (p× q) = 0, respectively. To compare the determinant condition|A| = 0 with the system of equations in (5), we note that |A| = 0precisely when

(a× b) · c = (b× c) · a = (c× a) · b = 0.

This observation is immediate from the definition of the determinant.

Proof of Theorem 2. Consider the compositions u = ρr and v = ψr onΓ. Since (t, θ, ϕ) provides a local extremum for u subject to the constraintv(t, θ, ϕ) = 0, we conclude from the Lagrange multiplier theorem thateither ∇v(t, θ, ϕ) is the zero vector or that ∇u(t, θ, ϕ) = λ∇v(t, θ, ϕ) forsome λ ∈ R. This means precisely that the list (∇u(t, θ, ϕ),∇v(t, θ, ϕ))is linearly dependent. We now introduce the two column vectors

p = ∇ρ (r(t, θ, ϕ)) and q = ∇ψ (r(t, θ, ϕ))

in R3 as well as the matrix

A =

xt(t, θ, ϕ) yt(t, θ, ϕ) zt(t, θ, ϕ)

xθ(t, θ, ϕ) yθ(t, θ, ϕ) zθ(t, θ, ϕ)

xϕ(t, θ, ϕ) yϕ(t, θ, ϕ) zϕ(t, θ, ϕ)

=

rt(t, θ, ϕ)

rθ(t, θ, ϕ)

rϕ(t, θ, ϕ)

.

Since the multivariate chain rule ensures that Ap = ∇u(t, θ, ϕ) andAq = ∇v(t, θ, ϕ), we infer that the list (Ap,Aq) is linearly dependent.The assertions are then immediate from Lemmas 1 and 2.

Page 10: projetil 3D

52 R. KANTROWITZ AND M. M. NEUMANN

4 Projectile motion without air resistance Throughout thissection, we consider the motion of a projectile with parametric equations

(7)

x(t, θ, ϕ) = (u+ s cos θ cosϕ)t,

y(t, θ, ϕ) = (v + s cos θ sinϕ)t,

z(t, θ, ϕ) = h+ (w + s sin θ)t− 12gt2,

where g, h, s > 0 and u, v, w ∈ R are given constants. An obviousinterpretation of the additional parameters u, v and w is that here theprojectile is launched at time t = 0 from a vehicle that moves withvelocity vector 〈u, v, w〉 and is at the location (0, 0, h) at time t = 0.

To apply Theorem 2 to this case, we need to compute the correspond-ing Jacobian determinant J and the cross products involving rt, rθ, andrϕ at an arbitrary point (t, θ, ϕ) in R

3. All this can easily be done withthe aid of a computer algebra system, but computations using only paperand pencil also work nicely in this setting.

First, the Jacobian determinant for (7) is given by

J(t, θ, ϕ) = −s2t2 cos θ(s+ u cos θ cosϕ

+ v cos θ sinϕ+ w sin θ − gt sin θ).

With the notation

δ(θ, ϕ) = 〈cos θ cosϕ, cos θ sinϕ, sin θ〉

for the unit vector in R3 that provides the direction given by the an-

gles θ and ϕ, we obtain the following characterization of the Jacobiancondition.

Proposition 3. Let t > 0, −π/2 < θ < π/2, and −π ≤ ϕ ≤ π. Then,

in the setting of (7), the identity J(t, θ, ϕ) = 0 holds if and only if

tg sin θ = s+ u cos θ cosϕ+ v cos θ sinϕ+ w sin θ,

and this happens precisely when the vectors δ(θ, ϕ) and rt(t, θ, ϕ) are

perpendicular. In particular, if u = v = w = 0, then J(t, θ, ϕ) = 0exactly when 0 < θ < π/2 and

t =s

g sin θ,

and this happens if and only if the tangent lines to the trajectory of the

projectile at the positions (0, 0, h) and r(t, θ, ϕ) are perpendicular.

Page 11: projetil 3D

OPTIMIZATION OF PROJECTILE MOTION 53

Proof. Since (7) entails that rt(t, θ, ϕ) = s δ(θ, ϕ) + 〈u, v, w − gt〉 , weobtain

rt(t, θ, ϕ) · δ(θ, ϕ) = s+ u cos θ cosϕ+ v cos θ sinϕ+ w sin θ − tg sin θ.

Hence, the result is immediate from the preceding formula for J(t, θ, ϕ).

Thus, in applications of Theorem 2 to projectile motion governed by(7), the Jacobian condition allows us to eliminate t by a simple for-mula that, quite remarkably, is independent of both ρ and ψ. The onlyexception occurs when

rt(0, θ, ϕ) · δ(θ, ϕ) = s+ u cos θ cosϕ+ v cos θ sinϕ+ w sin θ = 0.

Note that, by the Cauchy-Schwarz inequality, this possibility is pre-cluded provided that |〈u, v, w〉| < s. Indeed, if rt(0, θ, ϕ) · δ(θ, ϕ) = 0,then 〈u, v, w〉 · δ(θ, ϕ) = −s and therefore, s = |〈u, v, w〉 · δ(θ, ϕ)| ≤|〈u, v, w〉| .

For classical projectile motion in two dimensions, it was already ob-served earlier, for instance in [3], that, in the case of optimal launchto a horizontal line, the tangent lines to the trajectory of the projectileat the points of launch and impact have to be perpendicular. A moregeneral result of this type was recently obtained in Theorem 4 of [6].The archetypical case is, of course, given by shooting from h = 0 toground level, where it has been known at least since Galileo that theoptimal angle of elevation is θ = π/4 and that the two tangent lines forthis launch are perpendicular.

It turns out that the vector δ(θ, ϕ) continues to play a central role inthis context. In fact, another simple computation shows that

(rθ × rϕ) (t, θ, ϕ) = −s2t2 cos θ δ(θ, ϕ).

In particular, (rθ × rϕ) (t, θ, ϕ) is nonzero whenever t > 0 and −π/2 <θ < π/2. For the other two cross products, we obtain more complicatedresults, namely,

(rt × rθ) (t, θ, ϕ) = st 〈v cos θ + (s+ (w − gt) sin θ) sinϕ,

− u cos θ − (s+ (w − gt) sin θ) cosϕ,

sin θ (v cosϕ− u sinϕ)〉 ,

Page 12: projetil 3D

54 R. KANTROWITZ AND M. M. NEUMANN

and similarly

(rϕ × rt) (t, θ, ϕ) = st cos θ 〈cosϕ (w − gt+ s sin θ) ,

sinϕ (w − gt+ s sin θ) ,

−s cos θ − u cosϕ− v sinϕ〉 .

However, under the condition J(t, θ, ϕ) = 0, these formulas may besimplified to

(rt × rθ) (t, θ, ϕ) = st (v cosϕ− u sinϕ) δ(θ, ϕ)

and

(rϕ × rt) (t, θ, ϕ) = −st cot θ (s cos θ + u cosϕ+ v sinϕ) δ(θ, ϕ).

Thus, in the case J(t, θ, ϕ) = 0, the three cross products are all multiplesof δ(θ, ϕ), but the best choice for our purpose is rθ × rϕ. Incidentally,if u = v = 0, then rt × rθ vanishes at all points (t, θ, ϕ) for whichJ(t, θ, ϕ) = 0 and thus is of no use to us.

In the following, we consider the natural domain for our optimizationproblems, namely the set D consisting of all (t, θ, ϕ) for which t ≥ 0,−π/2 ≤ θ ≤ π/2, and −π ≤ ϕ ≤ π. Also, as one might expect from thedimensionless analysis in the classical theory of projectile motion, thequantity

κ = 1 +2gh

s2

will be useful; see Section 1.8 of [1] for details.

Theorem 3. Consider the projectile motion given by (7) for the case

u = v = w = 0. Then, for arbitrary real constants β and γ, there exists

exactly one point (t, θ, ϕ) in D that maximizes x(t, θ, ϕ) subject to the

constraint

z(t, θ, ϕ) = βx(t, θ, ϕ) + γy(t, θ, ϕ),

namely the point given by

θ = arccot

κ+ 2β2 + 2γ2 − 2β√

κ+ β2 + γ2 ,

t =s

g sin θ=s

g

1 + κ+ 2β2 + 2γ2 − 2β√

κ+ β2 + γ2 ,

ϕ = arcsin(−γ tan θ) = arctan

(

γ

β −√

κ+ β2 + γ2

)

.

Page 13: projetil 3D

OPTIMIZATION OF PROJECTILE MOTION 55

Moreover, the maximal displacement is

x(t, θ, ϕ) =s2

g

(

−β +√

κ+ β2 + γ2

)

.

Proof. For given θ ∈ [−π/2, π/2] and ϕ ∈ [−π, π], an elementary solu-tion of the relevant quadratic equation shows that there exists exactlyone time t = t(θ, ϕ) > 0 for which the impact z(t, θ, ϕ) = βx(t, θ, ϕ) +γy(t, θ, ϕ) occurs. Moreover, it is easily verified that the distance func-tion d given by d(θ, ϕ) = x(t(θ, ϕ), θ, ϕ) is continuous on the compactrectangle [−π/2, π/2]× [−π, π]. Thus, by the extreme value theorem, ouroptimization problem certainly has a solution. Hence, given an arbitrarypoint (t, θ, ϕ) ∈ D that maximizes x(t, θ, ϕ) subject to the constraint un-der consideration, it remains to show that all the stipulated identitiesare fulfilled.

We apply Theorem 2 to the sets Γ = Ω = R3 and the functions

ρ and ψ given by ρ(x, y, z) = x and ψ(x, y, z) = z − βx − γy. Then∇ρ×∇ψ = 〈0,−1,−γ〉 and

(rθ × rϕ) (t, θ, ϕ) = −s2t2 cos θ δ(θ, ϕ).

Since clearly t > 0 and −π/2 < θ < π/2, we conclude that both crossproducts are nonzero. Thus Theorem 2 ensures that (t, θ, ϕ) satisfies thethree conditions listed in (3). By Proposition 3, the Jacobian conditionJ(t, θ, ϕ) = 0 yields θ > 0 and t = s/(g sin θ) = (s/g) csc θ. Moreover,the cross product condition

(rθ × rϕ) (t, θ, ϕ) · (∇ρ×∇ψ) (r(t, θ, ϕ)) = 0

implies that δ(θ, ϕ) · 〈0,−1,−γ〉 = 0 and therefore, sinϕ = −γ tan θ.Also, since x(t, θ, ϕ) = st cos θ cosϕ > 0, we obtain cosϕ > 0 and hence,

cosϕ =

1 − sin2 ϕ =

1 − γ2 tan2 θ .

Elimination of t and ϕ in the impact condition ψ (r(t, θ, ϕ)) = 0 nowleads to

h+s2

g−s2

2gcsc2 θ =

s2

gcot θ (β cosϕ+ γ sinϕ)

and consequently,

2gh

s2+ 2 − csc2 θ = 2β cot θ

1 − γ2 tan2 θ − 2γ2.

Page 14: projetil 3D

56 R. KANTROWITZ AND M. M. NEUMANN

It may be tempting to employ a computer algebra system to solve thepreceding equation for θ, but, perhaps somewhat surprisingly, neitherMathematica nor Maple is helpful here, even when assisted by a suitablesubstitution. Nevertheless, the desired formula for θ may be found in afew steps. Indeed, using the definition of κ and the fact that csc2 θ =1 + cot2 θ, we may rewrite the last identity in the form

κ+ 2γ2 − cot2 θ = 2β

cot2 θ − γ2.

With the notation c = κ+ 2γ2, we conclude that µ = cot2 θ satisfies theequation

(8) c− µ = 2β√

µ− γ2,

hence c2 − 2cµ+ µ2 = 4β2(µ− γ2), and therefore,

µ2 − 2(

c+ 2β2)

µ+ c2 + 4β2γ2 = 0.

The solutions of this quadratic equation for µ are

µ± = c+ 2β2 ±

(c+ 2β2)2 − c2 − 4β2γ2

= c+ 2β2 ± 2 |β|√

c+ β2 − γ2.

A glance at these two formulas for µ± reveals that both solutions arereal and, in fact, non-negative. Moreover, because

c+ β2 − γ2 = κ+ β2 + γ2 > β2,

the last formula for µ± shows that µ− < c < µ+ whenever β 6= 0.Consequently, only one of these solutions satisfies the original equation(8). Indeed, if β > 0, then (8) ensures that µ ≤ c and thus µ = µ−,while the case β < 0 leads to c ≤ µ and therefore µ = µ+. We concludethat the identities

µ = c+ 2β2 − 2β√

c+ β2 − γ2 = κ+ 2β2 + 2γ2 − 2β√

κ+ β2 + γ2

hold for arbitrary real β, which establishes the claim concerning θ. Inci-dentally, we note that the delicate issue of the ± sign in this context is

Page 15: projetil 3D

OPTIMIZATION OF PROJECTILE MOTION 57

probably the reason why computer algebra systems fail to produce thepreceding formula for µ. Moreover, the identity csc2 θ = 1+cot2 θ yields

t =s

gcsc θ =

s

g

1 + cot2 θ

=s

g

1 + κ+ 2β2 + 2γ2 − 2β√

κ+ β2 + γ2,

as desired. Finally, because

cot2 θ − γ2 = κ+ β2 + γ2 − 2β√

κ+ β2 + γ2 + β2

=(

−β +√

κ+ β2 + γ2

)2

,

we arrive at

tanϕ =sinϕ

cosϕ=

−γ tan θ√

1 − γ2 tan2 θ=

−γ√

cot2 θ − γ2

β −√

κ+ β2 + γ2,

and similarly

x(t, θ, ϕ) = st cos θ cosϕ =s2

gcot θ

1 − γ2 tan2 θ

=s2

g

(

−β +√

κ+ β2 + γ2

)

.

This establishes all the remaining claims.

For the data g = 9.81 m/sec2, h = 50 m, s = 80 m/sec, β = 0.2, and

γ = 0.1, the preceding result leads to the optimal angles θopt = 0.84 andϕopt = −0.11, while the maximal distance is 585.16 m. These resultsare confirmed by the following graphics for the distance as a function ofthe two variables θ and ϕ.

Page 16: projetil 3D

58 R. KANTROWITZ AND M. M. NEUMANN

It is interesting to note that, in the special case γ = 0, the formula forthe optimal angle of elevation in Theorem 3 assumes the simple form

θ = arccot(

−β +√

κ+ β2

)

.

In particular, we see that the solution formula (1) from the critical pointapproach to the two-dimensional counterpart of our optimization prob-lem admits a stunning simplification. The preceding formula for θ waspreviously obtained in Section 4.1 of [5], also based on Lagrange multi-pliers, while an alternative elementary proof was recently developed inTheorem 2 of [6].

In the context of Theorem 3, it is natural to wonder what happenswhen 〈u, v, w〉 is not the zero vector. After all, also in this case, Propo-sition 3 allows us to eliminate t, while the condition on the cross prod-ucts leads, exactly as in the proof of Theorem 3, to the simple for-mula sinϕ = −γ tan θ. Thus, as above, Theorem 2 reduces this opti-mization problem to the solution of a certain impact equation for θ,but it turns out that, in general, this equation provides a formidablechallenge. In fact, computer algebra systems run out of memory whenattempting to solve this equation.

In the following result, we restrict ourselves to a certain manageablespecial case. In particular, here we assume that h = 0, which requires asmall adjustment of the natural domain for this optimization problem.Given s, v, w, and γ, let D∗ consist of all (t, θ, ϕ) ∈ D that satisfy thecondition w + s sin θ ≥ γ (v + s cos θ sinϕ) .

Theorem 4. Consider the projectile motion given by (7) for the case

h = 0, u = 0, and v, w ∈ R. Then, for arbitrary real γ for which w+ s >

Page 17: projetil 3D

OPTIMIZATION OF PROJECTILE MOTION 59

γv, there exists exactly one point (t, θ, ϕ) ∈ D∗ that maximizes x(t, θ, ϕ)subject to the constraint

z(t, θ, ϕ) = γy(t, θ, ϕ),

namely the point given by

θ = arcsin

(

γv − w +√

(γv − w)2 + 8s2(1 + γ2)

4s(1 + γ2)

)

,

ϕ = arcsin(−γ tan θ) and t =s+ v cos θ sinϕ+ w sin θ

g sin θ.

Proof. If the angles θ ∈ [−π/2, π/2] and ϕ ∈ [−π, π] satisfy the condi-tion

w + s sin θ ≥ γ (v + s cos θ sinϕ) ,

then either the quadratic equation z(t, θ, ϕ) = γy(t, θ, ϕ) has t = 0 asa double root or there exists a unique time t = t(θ, ϕ) > 0 for whichz(t, θ, ϕ) = γy(t, θ, ϕ). Moreover, the inequality w + s > γv guaran-tees that D∗ is non-empty. As in the derivation of Theorem 3, a routineapplication of the extreme value theorem now ensures that the optimiza-tion problem at hand has a solution, so it remains to be seen that anysolution (t, θ, ϕ) is of the desired form. This will follow from Theorem 2.Clearly, the condition w + s > γv implies that t > 0 and θ 6= ±π/2.Moreover, we have θ ≥ 0, since otherwise the angles |θ| and ϕ would beadmissible and satisfy

z(τ, |θ| , ϕ) > z(τ, θ, ϕ) for all τ > 0,

hence t(|θ| , ϕ) > t(θ, ϕ), and therefore x(t(|θ| , ϕ), |θ| , ϕ) > x(t, θ, ϕ),which is impossible. Also, the first two conditions of (3) lead to tg sin θ =s+v cos θ sinϕ+w sin θ and sinϕ = −γ tan θ. Hence the impact conditionz(t, θ, ϕ) = γy(t, θ, ϕ) may be rewritten in the form

2s(1 + γ2) sin2 θ + (w − γv) sin θ − s = 0,

as the patient reader will easily check. The solution of this quadraticequation for sin θ ≥ 0 is straightforward and leads to the desired conclu-sion.

Page 18: projetil 3D

60 R. KANTROWITZ AND M. M. NEUMANN

We close this section with a few additional examples to illustrate thesignificance and power of the cross product condition

(9) (rθ × rϕ) (t, θ, ϕ) · (∇ρ×∇ψ) (r(t, θ, ϕ)) = 0,

here in the setting of (7) and for the case t > 0 and θ 6= ±π/2.First, if ρ(x, y, z) = x2 + y2 and ψ(x, y, z) = z, then ∇ρ × ∇ψ =

2 〈y,−x, 0〉 , and (9) turns into the condition u sinϕ = v cosϕ.Also, if the goal is to shoot as high as possible to a certain cylindrical

wall, then ρ(x, y, z) = z, ψ(x, y, z) = βx2 + γy2 − 1, and ∇ρ × ∇ψ =2 〈−γy, βx, 0〉 , so that condition (9) assumes the form

β sinϕ (u+ s cos θ cosϕ) = γ cosϕ (v + s cos θ sinϕ) .

In the special case β = γ > 0, this simplifies again to u sinϕ = v cosϕ.Finally, for the choice ρ(x, y, z) = x2 + y2 and ψ(x, y, z) = x2 + y2 +

z2 − 1, we obtain ∇ρ × ∇ψ = 4z 〈y,−x, 0〉 . Evidently, ρ(x, y, z) willbe minimal for x = y = 0 and maximal for z = 0, but the conditionz(t, θ, ϕ) = 0 may not be feasible. For z(t, θ, ϕ) 6= 0, condition (9) leadsto u sinϕ = v cosϕ.

5 Projectile motion with linear air resistance As in [1, 4, 5,

8] for the two-dimensional setting, we now turn to the case of projectilemotion in space when the retarding force is proportional to the velocityvector with a negative constant factor. This leads to the second-orderinitial value problem

x′′(t) = −αx′(t), x′(0) = u+ s cos θ cosϕ, x(0) = 0,

y′′(t) = −αy′(t), y′(0) = v + s cos θ sinϕ, y(0) = 0,

z′′(t) = −g − α z′(t), z′(0) = w + s sin θ, z(0) = h,

where α > 0 is the air resistance coefficient. It is not hard to verify thatthe solution of this uncoupled system of ordinary differential equationsis given by

(10)

x(t, θ, ϕ) =u+ s cos θ cosϕ

α(1 − e−αt) ,

y(t, θ, ϕ) =v + s cos θ sinϕ

α(1 − e−αt) ,

z(t, θ, ϕ) = h−g

αt+

g + α (w + s sin θ)

α2(1 − e−αt) .

Page 19: projetil 3D

OPTIMIZATION OF PROJECTILE MOTION 61

For the corresponding Jacobian determinant J(t, θ, ϕ), a slightly tediouscomputation leads to

−(1 − e−αt)

2s2 cos θ

eαtα3

(

αs+(

g − eαtg + αw)

sin θ

+ α cos θ (u cosϕ+ v sinϕ))

.

Complicated as this formula may be, we obtain the following counterpartof Proposition 3.

Proposition 4. Let t > 0, −π/2 < θ < π/2, and −π ≤ ϕ ≤ π be given,

and suppose that rt(0, θ, ϕ) ·δ(θ, ϕ) 6= 0. Then, in the setting of (10), the

identity J(t, θ, ϕ) = 0 holds if and only if θ 6= 0 and

t =1

αln

(

1 +α (s+ u cos θ cosϕ+ v cos θ sinϕ+ w sin θ)

g sin θ

)

,

and this happens exactly when the vectors δ(θ, ϕ) and rt(t, θ, ϕ) are per-

pendicular. In particular, if u = v = w = 0, then J(t, θ, ϕ) = 0 precisely

when 0 < θ < π/2 and

t =1

αln

(

1 +αs

g sin θ

)

,

and this happens if and only if the tangent lines to the trajectory of the

projectile at the positions (0, 0, h) and r(t, θ, ϕ) are perpendicular.

Proof. From (10) we conclude that

rt(t, θ, ϕ) = (s δ(θ, ϕ) + 〈u, v, w〉) e−αt +⟨

0, 0,g

α

(

e−αt − 1)

.

Taking the preceding formula for J(t, θ, ϕ) into account, we arrive at

(

−(1− e−αt)2s2 cos θ

α2

)

rt(t, θ, ϕ) · δ(θ, ϕ) = J(t, θ, ϕ).

Thus, J(t, θ, ϕ) = 0 if and only if δ(θ, ϕ) and rt(t, θ, ϕ) are perpendicu-lar. Moreover, another glance at the formula for J(t, θ, ϕ) reveals thatJ(t, θ, ϕ) = 0 precisely when

g sin θ(

eαt − 1)

= α (s+ u cos θ cosϕ+ v cos θ sinϕ+ w sin θ) .

Page 20: projetil 3D

62 R. KANTROWITZ AND M. M. NEUMANN

Since the condition rt(0, θ, ϕ) · δ(θ, ϕ) 6= 0 ensures that the right-handside of the preceding identity is nonzero, we infer that the conditionJ(t, θ, ϕ) = 0 entails that θ is nonzero. All the assertions are now im-mediate.

We mention in passing that the formulas of the preceding result con-verge to the corresponding expressions in Proposition 3 as α approaches0. This may be verified by a straightforward application of l’Hospital’srule.

Moreover, it is not hard to see that

(rθ × rϕ) (t, θ, ϕ) = −(1 − e−αt)2s2 cos θ

α2δ(θ, ϕ).

In particular, (rθ × rϕ) (t, θ, ϕ) is nonzero whenever t > 0 and θ 6= ±π/2.As one might expect from the case of motion without air resistance, theformulas for rt×rθ and rϕ×rt are much more involved, but it turns outthat at any point (t, θ, ϕ) for which J(t, θ, ϕ) = 0 all three cross productsare multiples of δ(θ, ϕ). We leave the verification to the interested reader.

Thus, somewhat surprisingly, it follows that the cross product condi-tion (9) for the case of linear air resistance leads to the same formula asin the case without air resistance and therefore yields the same relation-ship between the optimal angles θ and ϕ. In particular, we obtain thefollowing partial counterpart of Theorem 3.

Theorem 5. Consider the projectile motion given by (10) for the case

u = v = w = 0, let β and γ be real constants, and suppose that (t, θ, ϕ)maximizes x(t, θ, ϕ) subject to the constraint

z(t, θ, ϕ) = βx(t, θ, ϕ) + γy(t, θ, ϕ).

Then 0 < θ < π/2, and we have

t =1

αln

(

1 +αs

g sin θ

)

and ϕ = arcsin(−γ tan θ).

Moreover, θ satisfies the equation

(11) h−g

α2ln

(

1 +αs

g sin θ

)

+

sg + αs2(

(

1 + γ2)

sin θ − β√

1 − (1 + γ2) sin2 θ

)

α (αs+ g sin θ)= 0.

Page 21: projetil 3D

OPTIMIZATION OF PROJECTILE MOTION 63

Proof. This is another consequence of Theorem 2. Indeed, the as-sertions for t and θ result from Proposition 4 and the cross productcondition (9), while (11) is nothing but the impact condition evaluatedat the indicated choice of t and ϕ.

In the special case β = γ = 0, an explicit solution formula for (11)was provided in Theorem 5 of [5]. This formula involves the LambertW function which, as explained in [8], is a powerful tool in this context.We do not know a solution formula for the general case, but, for specificdata, it is not difficult to see that (11) has a unique solution which canthen be determined numerically.

For instance, if g = 9.81 m/sec2, h = 50 m, s = 80 m/sec, α = 0.2

sec−1, β = 0.2, and γ = 0.1, then the left-hand side of (11) defines astrictly increasing function of the parameter p = sin θ, and the Find-

Root command of Mathematica leads to the unique root p = 0.528.Thus Theorem 5 yields the optimal solution θ = arcsin p = 0.557,ϕ = −0.062, t = 7.04 sec, and x(t, θ, ϕ) = 256 m.

0

200

x

-200

200y

0

200

z

0 125 250

125

250

The preceding graphics displays a few typical trajectories for thisexample as well as the optimal trajectory in the vertical plane induced bythe polar angle ϕ. Evidently, the tangent lines to this curve at the pointsof launch and impact are perpendicular, as predicted by Proposition 4.

REFERENCES

1. N. de Mestre, The Mathematics of Projectiles in Sport, Cambridge UniversityPress, Cambridge, 1990.

Page 22: projetil 3D

64 R. KANTROWITZ AND M. M. NEUMANN

2. C. W. Groetsch, Inverse Problems, Math. Assoc. of America, Washington, DC,1999.

3. C. W. Groetsch, Geometrical aspects of an optimal trajectory, Pi Mu Epsilon J.11 (2003), 487–490.

4. C. W. Groetsch and B. Cipra, Halley’s comment–projectiles with linear resis-tance, Math. Magazine 70 (1997), 273–280.

5. R. Kantrowitz and M. M. Neumann, Optimal angles for launching projectiles:Lagrange vs. CAS, Canad. Appl. Math. Quart. 16 (2008), 279–299.

6. R. Kantrowitz and M. M. Neumann, Let’s do launch: more musings on projectilemotion, Pi Mu Epsilon J. 13 (2011), 219–228.

7. M. M. Neumann and T. L. Miller, Mathematica Projects for Vector Calculus,Kendall-Hunt Publishing Company, Dubuque, IA, 1996.

8. E. W. Packel and D. S. Yuen, Projectile motion with resistance and the LambertW function, College Math. J. 35 (2004), 337–350.

9. M. S. Townend, Mathematics in Sport, Ellis Horwood Publishers, Chichester,1984.

Department of Mathematics, Hamilton College, Clinton, NY 13323, USA

E-mail address: [email protected]

Corresponding author: Michael M. Neumann,

Department of Mathematics and Statistics,

Mississippi State University, Mississippi state, MS 39762, USA

E-mail address: [email protected]