正四面體中的正八面體
Author: 藍邦偉  老師

x

y

z

單位向量

座標軸

Reset

Step1

Step 2

Step3

Step4

α = 4.4505895925855405 rad (slider from 0 to 6.283185307179586, step 0.017)
β = 1.3962634015954636 rad (slider from 0 to 6.283185307179586, step 0.017)
O = (8.539785140970745, 0.40429941927170926)
X_{unit}: O + (cos(α), sin(α) * cos(β))
Y_{unit}: O + (-1 * sin(α), cos(α) * cos(β))
Z_{unit}: O + (0, sin(β))
u = Vector(O, X_{unit})
v = Vector(O, Y_{unit})
w = Vector(O, Z_{unit})
L = 6 (slider from 1 to 10, step 1)
a = Vector(O - L * v, O + L * v)
b = Vector(O - L * w, O + L * w)
z = Vector(O - L * u, O + L * u)
A_1: O + L * u
B_1: O + L * v
Z: O + L * w
c = false
d = false
Q_2: 0.2 * Corner[2] + 0.8 * Corner[1]
Q_3: (x(Q_2), y(Corner[3]))
多邊形1, e, q_2, q_3, f = Polygon(Corner[1], Q_2, Q_3, Corner[4])
g = Segment(Q_2, Q_3)
A1: O + 4 * u
A2: O - 2 * u + 2 * sqrt(3) * v
A3: O - 2 * u - 2 * sqrt(3) * v
A4: O + 4 * sqrt(2) * w
d1 = 0 (slider from 0 to 3, step 0.01)
M1 = Midpoint(A3, A1)
M2 = Midpoint(A3, A2)
M3 = Midpoint(A1, A2)
M4 = Midpoint(A3, A4)
M5 = Midpoint(A1, A4)
M6 = Midpoint(A2, A4)
G1: 1 / 3 * (A1 + A2 + A3)
P1: A1 + d1 * u
P2: M1 + d1 * u
P3: M3 + d1 * u
P5: M5 + d1 * u
q, r = SDLine(P5, P3, P1, P2)
s, t = SDLine(P5, P2, P3, P1)
c_1, d_1 = SDLine(P1, P2, P5, P3)
e_1, f_1 = SDLine(P1, P3, P2, P5)
d2 = 0 (slider from 0 to 3, step 0.01)
C4: A4 + d2 * w
C5: M5 + d2 * w
C6: M6 + d2 * w
C0: M4 + d2 * w
g_1, h_1 = SDLine(C4, C5, C0, C6)
i_1, j_1 = SDLine(C4, C6, C5, C0)
k_1, l_1 = SDLine(C4, C0, C6, C5)
m_1, n_1 = SDLine(C5, C0, C4, C6)
p_1, q_1 = SDLine(C5, C6, C0, C4)
r_1, s_1 = SDLine(C0, C6, C4, C5)
d3 = 0 (slider from 0 to 3, step 0.01)
d4 = 0 (slider from 0 to 3, step 0.01)
D2: A2 + d3 * v
D6: M6 + d3 * v
D3: M3 + d3 * v
D0: M2 + d3 * v
t_1, a_2 = SDLine(D6, D3, D0, D2)
d_2, e_2 = SDLine(D6, D0, D2, D3)
f_2, g_2 = SDLine(D3, D2, D0, D6)
h_2, i_2 = SDLine(D3, D0, D6, D2)
j_2, k_2 = SDLine(D0, D2, D6, D3)
n, p = SDLine(P5, P1, P2, P3)
E3: A3 - d4 * v
E1: M1 - d4 * v
E4: M4 - d4 * v
E2: M2 - d4 * v
l_2, m_2 = SDLine(E4, E1, E3, E2)
n_2, p_2 = SDLine(E4, E3, E2, E1)
r_2, s_2 = SDLine(E4, E2, E1, E3)
t_2, a_3 = SDLine(E1, E3, E4, E2)
b_3, c_3 = SDLine(E3, E2, E4, E1)
d_3, e_3 = SDLine(E2, E1, E4, E3)
a_1, b_1 = SDLine(P2, P3, P5, P1)
h, i = SDLine(D6, D2, D3, D0)
b_2, c_2 = SDLine(M4, M5, M1, M6)
b_4, c_4 = SDLine(M5, M1, M4, M3)
d_4, e_4 = SDLine(M4, M1, M2, M5)
j_3, k_3 = SDLine(M6, M2, M3, M4)
l_3, m_3 = SDLine(M6, M3, M5, M1)
t_3, a_4 = SDLine(M2, M3, M6, M1)
l, m = SDLine(M6, M5, M4, M3)
n_3, p_3 = SDLine(M5, M3, M1, M6)
f_3, g_3 = SDLine(M4, M2, M6, M1)
j, k = SDLine(M1, M2, M4, M3)
h_3, i_3 = SDLine(M1, M3, M2, M5)
r_3, s_3 = SDLine(M4, M6, M5, M2)

Tool: SDLine
Input: A, B, C, D
Output: g, h

b: sgn(sin(Angle[D, B, A]))
a: sgn(sin(Angle[A, B, C]))
c: sgn(a + b + 0.5)
d: sqrt(c)
e: sqrt(-c)
E = Midpoint(A, B)
A' = Dilate(A, d, E)
B' = Dilate(B, d, E)
g = Segment(A', B')
A'_1 = Dilate(A, e, E)
B'_1 = Dilate(B, e, E)
h = Segment(A'_1, B'_1)