/home/nivoliev/Taf/Cours/ENSImg/Processing/curvature_3d

P(x, y) = x^(2) + (x * y) - y^(2)
A = PointIn(P)
tx = Vector((1, 0, (2 * x(A)) + y(A)))
lx = Line(A, tx)
ty = Vector((0, 1, x(A) - (2 * y(A))))
ly = Line(A, ty)
tangentPlane = Plane(ly, lx)
normal = OrthogonalLine(A, tangentPlane)
tangentHandleCurve = Circle(A, 1, normal)
tangentHandle = Point(tangentHandleCurve)
tangentDirection = Segment(A, tangentHandle)
tiltHandleCurve = Circle(A, 1, tangentDirection)
tiltHandle = Point(tiltHandleCurve)
eq2: x^(2) + (x * y) - y^(2) - z = 0
radius = 0.01 (slider from 0 to 1, step 0.01)
epsilon = Sphere(A, radius)
tiltedPlane = Plane(tangentHandle, A, tiltHandle)
tiltedCurve = IntersectPath(tiltedPlane, eq2)
tiltedEps1, tiltedEps2, J, K = Intersect(tiltedCurve, epsilon)
normalPlane = Plane(tangentHandle, normal)
normalCurve = IntersectPath(normalPlane, eq2)
normalEps1, normalEps2 = Intersect(normalCurve, epsilon)
eq1 = IntersectPath(normalPlane, P)
normalCircle = Circle(normalEps1, A, normalEps2)
j = OrthogonalLine(tiltedEps1, normalPlane)
k = OrthogonalLine(tiltedEps2, normalPlane)
projectedEps1 = Intersect(k, normalPlane)
projectedEps2 = Intersect(j, normalPlane)
projectedCircle = Circle(projectedEps2, A, projectedEps1)
tiltedProjection1 = Segment(tiltedEps2, projectedEps1)
tiltedProjection2 = Segment(tiltedEps1, projectedEps2)
tiltedPoint = Point(tiltedCurve)
f = OrthogonalLine(tiltedPoint, normalPlane)
projectedPoint = Intersect(f, normalPlane)
projectedCurve = Locus(projectedPoint, tiltedPoint)