Calculating parametric coordinates on a curved edge


I wanted to know how to calculate the parametric coordinates of a mesh vertex on a curved geometric edge. Specifically, how are dist1 and dist2 calculated in a .vol file.

I am generating a mesh from an “in2d” file where I specify the two edge points and the points where tangents meet.

I need this because I want to physically introduce new vertices on the curved edge.

Thank you