# Trying to to solve the ‘dog chasing rabbit’ problem with DSolve

When I type the following into Mathematica, it just returns it back to me unchanged:

DSolve[{y'[t] == (y[t] - v t) x'[t]/x[t], y'[t]^2 + x'[t]^2 == u^2}, {x[t], y[t]}, t]

x[t] and y[t] are coordinates of the dog whose speed is u and whose velocity is always directed at the rabbit whose position is v*t on the y-axis.

How can I get Mathematica to solve this?

• Do you need symbolic or numerical solution ? Is it "Pursuit Curve" problem that you are looking for ? Commented Feb 6, 2019 at 22:40
• This paper (using Maple) suggests that the problem will have to be solved by numerical methods.
– gwr
Commented Feb 7, 2019 at 7:21

I think this problem must be solved numerically. Here is how I did it.

{xF, yF} =
With[{u = 1, v = 8/10, ϵ = 1/10},
NDSolveValue[
{y'[t] == (y[t] - v t) x'[t]/x[t], (y'[t])^2 + (x'[t])^2 == u^2,
x[0] == 5, y[0] == 0, WhenEvent[Abs[y[t] - v t] < ϵ, "StopIntegration"]},
{x, y}, {t, 0, ∞}]];

With[{tmax = xF["Domain"][[1, 2]]},
ParametricPlot[{xF[t], yF[t]}, {t, 0, tmax}]]

The quantity ϵ is taken to be the distance along the y-axis between dog and the rabbit at which the dog is close enough to catch the rabbit.