Drawn is the starting position and velocity of the particles.
Let t {\displaystyle t} be time in seconds. The position of the first particle is given by ( 0 , y ) {\displaystyle (0,y)} where y = 6 − 2 t {\displaystyle y=6-2t} The position of the second particle is ( x , 0 ) {\displaystyle (x,0)} with x = t {\displaystyle x=t} The squared-distance between the particles is therefore
d 2 = ( d i f f e r e n c e i n x ) 2 + ( d i f f e r e n c e i n y ) 2 = t 2 + ( 6 − 2 t ) 2 = 5 t 2 − 24 t + 36 d = 5 t 2 − 24 t + 36 {\displaystyle {\begin{aligned}d^{2}&=(\mathrm {difference\ in\ } x)^{2}+(\mathrm {difference\ in\ } y)^{2}\\&=t^{2}+(6-2t)^{2}\\&=5t^{2}-24t+36\\d&={\sqrt {5t^{2}-24t+36}}\end{aligned}}}