空間中的距離(2)
Author: 藍邦偉  老師

x

y

z

顯示座標平面

顯示單位向量

顯示座標軸

1

3

2

空間中的距離(2)

A: (x((Corner[3.0] + 39.0 * Corner[4.0]) / 40.0), y((Corner[1.0] + 9.0 * Corner[4.0]) / 10.0))
B: (x((4.0 * Corner[3.0] + 16.0 * Corner[4.0]) / 20.0), y((Corner[1.0] + 9.0 * Corner[4.0]) / 10.0))
a = Segment(A, B)
C: (3.0 * A + B) / 4.0
D: (3.0 * B + A) / 4.0
E = Point(a)
c = Circle(C, E)
c' = Translate(c, Vector[Vector[C, D]])
A' = Rotate(A, 270.0*°, C)
B' = Rotate(B, 270.0*°, C)
a' = Segment(A', B')
c'' = Rotate(c', 270.0*°, C)
D' = Rotate(D, 270.0*°, C)
E' = Rotate(Translate[E, Vector[C, D]], 90.0*°, D)
E'' = Rotate(E', 270.0*°, C)
F = Point(c'')
G = Point(c')
α = Angle(E'', D', F)
b = Segment(D', F)
d = Segment(D, G)
β = Angle(G, D, E')
I: C + (b * cos(α), b * sin(α) * sin(β))
J: C + (b * cos(α + 90.0°), b * sin(α + 90.0°) * sin(β))
K: C + (0.0, b * cos(β))
e = Segment(C, K)
f = Segment(C, I)
g = Segment(C, J)
O = (-0.12346453325015641, -3.2837626921846317)
I' = Translate(I, Vector[Vector[C, O]])
J' = Translate(J, Vector[Vector[C, O]])
K' = Translate(K, Vector[Vector[C, O]])
L = 12 (slider from 1 to 12, step 1)
I'' = Dilate(I', L, O)
J'' = Dilate(J', L, O)
K'' = Dilate(K', L, O)
I''' = Dilate(I'', -1.0, O)
J''' = Dilate(J'', -1.0, O)
K''' = Dilate(K'', -1.0, O)
u' = Vector(I''', I'')
v' = Vector(J''', J'')
w' = Vector(K''', K'')
h = Segment(D', E'')
i = Segment(D, E')
軌跡1 = Locus(I, F)
L_{axis}: L
j = true
w = Vector(O, K')
u = Vector(O, I')
v = Vector(O, J')
k = false
l = false
list1 = Sequence(CurveCartesian[x(O + t * u + s * v), y(O + t * u + s * v), t, -(L), L], s, -(L), L, 1.0)
list2 = Sequence(CurveCartesian[x(O + t * u + s * v), y(O + t * u + s * v), s, -(L), L], t, -(L), L, 1.0)
C_a: C + (b * cos(α + 10.0°), b * sin(α + 10.0°) * sin(β))
C_b: C + (b * cos(α + 20.0°), b * sin(α + 20.0°) * sin(β))
C_c: C + (b * cos(α + 30.0°), b * sin(α + 30.0°) * sin(β))
C_d: C + (b * cos(α + 40.0°), b * sin(α + 40.0°) * sin(β))
C_e: C + (b * cos(α + 50.0°), b * sin(α + 50.0°) * sin(β))
p = Conic(C_a, C_b, C_c, C_d, C_e)
W_1: O + L * u + L * v
W_2: O + L * u
W_3: O + L * v
W_4: O + L * u + L * w
W_5: O + L * v + L * w
W_6: O + L * w
多邊形1, o, w_2, w_1, w_3 = Polygon(O, W_2, W_1, W_3)
多邊形2, o_1, w_6, w_5, w_4 = Polygon(O, W_6, W_5, W_3)
多邊形3, o_2, w_7, w_8, w_9 = Polygon(O, W_2, W_4, W_6)
x_1 = 2 (slider from 0 to 5, step 1)
x_2 = 9 (slider from 6 to 10, step 1)
y_1 = 2 (slider from 0 to 5, step 1)
z_1 = 2 (slider from 0 to 5, step 1)
y_2 = 8 (slider from 6 to 10, step 1)
z_2 = 9 (slider from 6 to 10, step 1)
P_1: O + x_1 * u + y_1 * v + z_1 * w
P_2: O + x_2 * u + y_2 * v + z_2 * w
m = Segment(P_1, P_2)
P_3: O + x_1 * u + y_1 * v
P_4: O + x_2 * u + y_2 * v
n = Segment(P_3, P_4)
q = Segment(P_2, P_4)
r = Segment(P_1, P_3)
P_5: O + x_1 * u + z_1 * w
P_6: O + x_2 * u + z_2 * w
s = Segment(P_6, P_5)
t = Segment(P_6, P_2)
a_1 = Segment(P_5, P_1)
P_7: O + y_1 * v + z_1 * w
P_8: O + y_2 * v + z_2 * w
b_1 = Segment(P_7, P_8)
c_1 = Segment(P_2, P_8)
d_1 = Segment(P_7, P_1)
e_1 = Line(P_1, n)
H = Intersect(e_1, q)
f_1 = Line(P_1, s)
M = Intersect(f_1, t)
g_1 = Segment(P_1, H)
h_1 = Segment(P_1, M)
i_1 = Line(P_1, b_1)
N = Intersect(i_1, c_1)
j_1 = Segment(N, P_1)
P_a: O + x_1 * u
P_b: O + x_2 * u
P_c: P_b + P_3 - P_a
k_1 = Segment(P_4, P_b)
l_1 = Segment(P_3, P_a)
m_1 = Segment(P_3, P_c)
z = false
n_1 = Segment(P_6, P_b)
p_1 = Segment(P_5, P_a)
P_d: P_b + P_5 - P_a
q_1 = Segment(P_d, P_5)
r_1 = false
P_e: O + y_1 * v
P_f: O + y_2 * v
P_g: P_7 + P_f - P_e
s_1 = Segment(P_8, P_f)
t_1 = Segment(P_7, P_e)
a_2 = Segment(P_7, P_g)
u_1 = false