Curve distance equation

Blitz3D Forums/Blitz3D Programming/Curve distance equation

sbout what i came up with :/