橢圓規
Author: 藍邦偉  老師

橢圓規

radius = 6 (slider from 1 to 10, step 1)
α = 0 rad (slider from 0 to 6.283185307179586, step 0.1*°)
A = Intersect(xAxis, yAxis)
r = 1.8 (slider from -3 to 3, step 0.1)
B: (radius, 0)
C = Rotate(B, α, (0, 0))
a = OrthogonalLine(C, xAxis)
b = OrthogonalLine(C, yAxis)
D = Intersect(b, yAxis)
E = Intersect(a, xAxis)
d = Line(D, E)
D' = Dilate(D, r, E)
e = Segment(D', E)
c = Circle(A, radius)
T_1: (x(Corner[1]), 0)
T_2: (x(Corner[2]), 0)
T_3: (0, y(Corner[1]))
T_4: (0, y(Corner[3]))
u = Vector(T_1, T_2)
v = Vector(T_3, T_4)
H_1 = Corner(1)
H_4 = Corner(4)
H_2: (4 * Corner[1] + Corner[2]) / 5
H_3: (4 * Corner[4] + Corner[3]) / 5
多邊形1, h_1, h_2, h_3, h_4 = Polygon(H_1, H_2, H_3, H_4)
f = Segment(H_2, H_3)