Xiao gang after school ....

Let Xiaogang's speed be v 1, the car's speed be v2, and the departure interval be t.

Incoming: a * (v1+v2) = v2t ... [1]

Catch up later: b*(v2-v 1)=v2t.

So there is: a(v 1+v2)=b(v2-v 1).

(a+b)v 1=(b-a)v2

Namely: v 1=(b-a)v2/(a+b)

Substitute the above formula into [1] to get: t.

a[(b-a)v2/(a+b)+v2]=v2t

t = a[(b-a)/(a+b)+ 1]= 2ab/(a+b)