A = (-5, 3)
pb = -1
pa = -0.3333333333333333
M0d: (x(A) + 1, pa + y(A))
u = Vector(A, M0d)
M0d' = Mirror(M0d, A)
w = Vector(A, M0d')
B = (-2, 1)
v, z = Tangente(B, pb)
C = (0, -3)
pc = 0
a, b = Tangente(C, pc)
a0: ((pa + pb) * (x(A) - x(B)) - 2 * (y(A) - y(B))) / (x(A) - x(B))^(3)
b0: (pa - pb) / (2 * (x(A) - x(B))) - 3 a0 * (x(A) + x(B)) / 2
c0: pa - 3 a0 x(A)^(2) - 2 b0 x(A)
d0: y(A) - a0 x(A)^(3) - b0 x(A)^(2) - c0 x(A)
f = Function(a0 x^(3) + b0 x^(2) + c0 x + d0, x(A), x(B))
g = Spline(B, pb, pc, C)
h = Function(g, x(B), x(C))
D = (2, 0)
pd = 3
c, d = Tangente(D, pd)
f1 = Spline(C, pc, pd, D)
h1 = Function(f1, x(C), x(D))
E = (4, 6)
pe = 5
g1 = Spline(D, pd, pe, E)
h2 = Function(g1, x(D), x(E))

Tool: Tangente
Input: M0, p0
Output: u, w

M0d: (x(M0) + 1, p0 + y(M0))
u = Vector(M0, M0d)
M0d' = Mirror(M0d, M0)
w = Vector(M0, M0d')

Tool: Spline
Input: A, pa, pb, B
Output: f

a0: ((pa + pb) * (x(A) - x(B)) - 2 * (y(A) - y(B))) / (x(A) - x(B))^(3)
b0: (pa - pb) / (2 * (x(A) - x(B))) - 3 a0 * (x(A) + x(B)) / 2
c0: pa - 3 a0 x(A)^(2) - 2 b0 x(A)
d0: y(A) - a0 x(A)^(3) - b0 x(A)^(2) - c0 x(A)
f = Function(a0 x^(3) + b0 x^(2) + c0 x + d0, x(A), x(B))