Feynmani kolmnurga ülesande üldistus

Kui kolmnurga ABC küljed jagada p osaks ning seejärel ühendada kolmnurga tipud
vastupäeva vastaskülje sellise punktiga, mis jaotab vastaskülje suhtes 1:(p-1), siis
tekkiva kolmnurga GHI ja kolmnurga ABC pindalade suhe on

\frac{S_G_H_I}{S_A_B_C}=\frac{(p-2)^2}{p^2-p+1}.

n = 5 (slider from 1 to 5, step 1)
p = 3 (slider from 2 to 10, step 1)
A = (-3.320018908426425, -0.06645780832087805)
B = (0.8896251906179082, 3.5915812748015794)
C = (2.9536837450396902, -2.020448002409312)
t1, c, a, b = Polygon(A, B, C)
d = Circle(A, c / p)
e = Circle(B, a / p)
f = Circle(C, b / p)
F = Intersect(d, c)
D = Intersect(e, a)
E = Intersect(f, b)
g = Segment(B, E)
h = Segment(D, A)
i = Segment(F, C)
G = Intersect(h, i)
H = Intersect(h, g)
I = Intersect(g, i)
t2, i_1, g_1, h_1 = Polygon(G, H, I)
Punktt2 = PointIn(t2)
tekst1: "S_A_B_C=" + (LaTeX[t1]) + ""
tekst2: "S_G_H_I=" + (LaTeX[t2]) + ""
lug: (p - 2)^(2)
nim: p^(2) - p + 1
lug1: lug / GCD[lug, nim]
nim1: nim / GCD[lug, nim]
tekst6: "\frac{S_G_H_I}{S_A_B_C}=\frac{(" + (LaTeX[p]) + "-2)^2}{" + (LaTeX[p]) + "^2-" + (LaTeX[p]) + "+1}=\frac{" + (LaTeX[lug1]) + "}{" + (LaTeX[nim1]) + "}."
Suhe: t2 / t1
tekst7: "\frac{S_G_H_I}{S_A_B_C}=\frac{" + (LaTeX[t2]) + "}{" + (LaTeX[t1]) + "}≈" + (LaTeX[Suhe]) + "≈\frac{" + (LaTeX[lug1]) + "}{" + (LaTeX[nim1]) + "}"