Mathematics Stack Exchange is a question and answer site for people studying math at any level and professionals in related fields. Join them; it only takes a minute:

Sign up
Here's how it works:
  1. Anybody can ask a question
  2. Anybody can answer
  3. The best answers are voted up and rise to the top

My problem, which I proposed to myself months ago is based on the simple optimization problem

in which you find the best path for a lifeguard to rescue a drowning victim. Obviously the

shortest path is a straight line, but the catch is he swims more slowly than he runs. I

solved the problem and then attempted with 3 different speeds (beach, water, and weeds, or

something of the sort). The difficulty didn't set in until I allowed the difficulty of

traversing a point in the plane vary continuously. How do I find an optimal path?

share|cite|improve this question
A related question that occurred to me is if the lifeguard is working against (or with) a vector field, in which case I suppose you would use variational calculus to minimize the line integral from point a to b... Or is that incorrect? – Platonix Apr 13 '13 at 7:47
Think of the diffraction of light at the surface between air and water, and about the law that is valid there. – Christian Blatter Apr 13 '13 at 8:25
I'm afraid I was never much good at physics, how could I set up a differential equation for this? Also, isn't there a big difference b/w one change in medium and continuous variation? – Platonix Apr 13 '13 at 8:36
up vote 3 down vote accepted

Unfortunately you didn't supply a figure. I take it that you have the following in mind:

At time $t=0$ the life guard is at $(0,0)$ in the $(x,y)$-plane, and the drowning swimmer is at the point $(a,b)$ in the first quadrant. The speed of the life guard is a given function $x\mapsto v(x)$ $\ (0\leq x\leq a)$ of $x$ alone.

Then one can set up the following variational problem with a constraint: Denote by $p(x)$ the slope of the life guard's orbit when his abscissa is $x$. Then $dt$ and $dx$ are related by $$dt={ds\over v(x)} ={\sqrt{1+p^2(x)}\over v(x)}\ dx\ .$$ Therefore we should minimize $$T:=\int_0^a {\sqrt{1+p^2(x)}\over v(x)}\ dx$$ under the constraint $$\int_0^a p(x)\ dx=b\ .$$ This is a standard variational problem. The constraint is dealt with using a Lagrange multiplier.

For the discontinuous version of this, meaning $v(x)=v_1$ for $0\leq x\leq c$ and $v(x)=v_2$ for $c\leq x\leq a$, see Snell's law at Wikipedia.

share|cite|improve this answer

Your Answer


By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.