Distance Scales
Parallax and Trigonometric Methods
tan λ = Vt/Vr = μd/Vr
So then d = Vr tanλ/4.74μ [pc]
Where velocities are in km/s and proper motion
μ is in arcseconds per year.
Should be something you can derive (it would
be a good problem to work in your free time)