fix problem in distance3D(gA:Point,gB:Triangle)
add regression test for distance (taken from PostGIS)