E = Point(xAxis)
h = Ray(E, E + (1, 0))
F = Point(h)
J: E + (4 * (F - E) / 5)
l = OrthogonalLine(J, xAxis)
I: E + (3 * (F - E) / 5)
k = OrthogonalLine(I, xAxis)
H: E + (2 * (F - E) / 5)
j = OrthogonalLine(H, xAxis)
G: E + (F - E) / 5
i = OrthogonalLine(G, xAxis)
A = Point(i)
B = Point(j)
D = Point(l)
C = Point(k)
g = Polynomial({A, B, C, D})
f(x) = If[x(E) ≤ x ≤ x(F), g(x)]
dominio = Segment(E, F)
K, L = Extremum(f)
max1 = Max(RemoveUndefined[{f(E), f(K), f(L), f(F)}])
min1 = Min(RemoveUndefined[{f(E), f(K), f(L), f(F)}])
max2 = If(max1 ≟ f(E), E, If[max1 ≟ f(K), K, If[max1 ≟ f(L), L, F]])
min2 = If(min1 ≟ f(E), E, If[min1 ≟ f(K), K, If[min1 ≟ f(L), L, F]])
recorrido = Segment((0, f(x(min2))), (0, f(x(max2))))
M = Point(dominio)
N: (x(M), f(x(M)))
m = Segment(M, N)
O: (0, y(N))
n = Segment(O, N)