Physics homework help

The problem deals with the problem called Strong Frechet Distance. The input contains two polygonal lines P = {p1 . . . pn} and Q = {q1 . . . qn} and a maximum length L of a leash. The person and the dog starts at location p1 and q1, respectively, and they end when they reach locations pn, qn, respectively. Assume that at a certain time, they are at locations pi , qj . At each time-stamp, (a) The person could move to pi?1, stay at pi , or move to pi+1. And at the same time stamp (b) The dog could move to qj?1, stay at qj , or move to qj+1. Suggest an algorithm that determines in O(n 2 log n) time whether there is a sequence of jumps for which the distance person-dog (that is, the length of the leash), is always smaller than 17.For clarification: We measure the length of the leash between jumps, when the person-dog are at rest and are preparing for the next jump