3D 座標架的製作
Author: 藍邦偉  老師

長方體

單位向量

單位點

座標軸

xy平面

x

y

z

A

B

C

D

E

H

G

α = 0.6981317007977318 rad (slider from 0*° to 6.283185307179586, step 0.1*°)
β = 4.4505895925855405 rad (slider from 0 to 6.283185307179586, step 0.1*°)
L = 8 (slider from 1 to 10, step 1)
A_6 = (33.35847434102816, 2.5130990457138207)
X_{unit}: A_6 + (cos(α), sin(α) * cos(β))
Y_{unit}: A_6 + (-sin(α), cos(α) * cos(β))
Z_{unit}: A_6 + (0, -sin(β))
u = Vector(A_6, X_{unit})
v = Vector(A_6, Y_{unit})
w = Vector(A_6, Z_{unit})
x_{Axis} = Vector(A_6 - L * u, A_6 + L * u)
y_{Axis} = Vector(A_6 - L * v, A_6 + L * v)
z_{Axis} = Vector(A_6 - L * w, A_6 + L * w)
多邊形1, d, e, f, g = Polygon(A_6 + L * u + L * v, A_6 - L * u + L * v, A_6 - L * u - L * v, A_6 + L * u - L * v)
h = false
i = false
j = false
k = false
a_1 = 1 (slider from 1 to 5, step 0.1)
a = 4.68 (slider from 0 to 6, step 0.01)
b = 3.35 (slider from 0 to 5, step 0.01)
c = 3.65 (slider from 0 to 5, step 0.01)
A_1: A_6 + a * u + c * w
A_2: A_6 + c * w
m = Segment(A_1, A_2)
A_3: A_6 + b * v + c * w
n = Segment(A_2, A_3)
A_4: A_6 + a * u + b * v + c * w
p = Segment(A_1, A_4)
q = Segment(A_3, A_4)
A_5: A_1 - c * w
r = Segment(A_1, A_5)
A_8: A_4 - c * w
s = Segment(A_4, A_8)
A_7: A_3 - c * w
t = Segment(A_6, A_5)
b_1 = Segment(A_6, A_7)
c_1 = Segment(A_3, A_7)
d_1 = Segment(A_7, A_8)
e_1 = Segment(A_8, A_5)
poly1, a_2, a_3, a_4, a_5 = Polygon(A_1, A_2, A_3, A_4)
poly2, o, a_6, a_8, a_7 = Polygon(A_6, A_5, A_8, A_7)
poly3, o_1, a_9, a_{10}, a_{11} = Polygon(A_6, A_2, A_1, A_5)
poly4, a_{12}, a_{13}, a_{14}, a_{15} = Polygon(A_3, A_4, A_8, A_7)
poly5, a_{16}, a_{17}, a_{18}, a_{19} = Polygon(A_1, A_4, A_8, A_5)
poly6, a_{20}, o_2, a_{21}, a_{22} = Polygon(A_2, A_6, A_7, A_3)
f_1 = Segment(A_5, A_6)