$\Large隐藏无关对象$

主视图

左视图

俯视图

原视图

初始化

l1 = Flatten(Sequence[Sequence[Polygon[(u, v), (u + 1, v), 4], u, 0, 4], v, 0, 4])
A1: 1
A2: 2
A3 = 3
A4 = 4
A5 = 5
A6 = 6
A7 = 7
A8 = 8
A9 = 9
A10 = 10
A11 = 11
A12 = 12
A13 = 13
A14 = 14
A15 = 15
A16 = 16
A17 = 17
A18 = 18
A19 = 19
A20 = 20
A21 = 21
A22 = 22
A23 = 23
A24 = 24
A25 = 25
B1 = Element(l1, A1)
n1: -1
n2: -1
n3: -1
n4: -1
n5: -1
n6: -1
n7 = 0
n8 = 1
n9: -1
n10: -1
n11: -1
n12: -1
n13 = 2
n14: -1
n15: -1
n16: -1
n17: -1
n18: -1
n19: -1
n20: -1
n21: -1
n22: -1
n23: -1
n24: -1
n25: -1
B2 = Element(l1, A2)
B3 = Element(l1, A3)
B4 = Element(l1, A4)
B5 = Element(l1, A5)
B6 = Element(l1, A6)
B7 = Element(l1, A7)
B8 = Element(l1, A8)
B9 = Element(l1, A9)
B10 = Element(l1, A10)
B11 = Element(l1, A11)
B12 = Element(l1, A12)
B13 = Element(l1, A13)
B14 = Element(l1, A14)
B15 = Element(l1, A15)
B16 = Element(l1, A16)
B17 = Element(l1, A17)
B18 = Element(l1, A18)
B19 = Element(l1, A19)
B20 = Element(l1, A20)
B21 = Element(l1, A21)
B22 = Element(l1, A22)
B23 = Element(l1, A23)
B24 = Element(l1, A24)
B25 = Element(l1, A25)
c1 = Sequence(Cube[Translate[B1, Vector[(0, 0, v)]], true], v, 0, n1)
c2 = Sequence(Cube[Translate[B2, Vector[(0, 0, v)]], true], v, 0, n2)
c3 = Sequence(Cube[Translate[B3, Vector[(0, 0, v)]], true], v, 0, n3)
c4 = Sequence(Cube[Translate[B4, Vector[(0, 0, v)]], true], v, 0, n4)
c5 = Sequence(Cube[Translate[B5, Vector[(0, 0, v)]], true], v, 0, n5)
c6 = Sequence(Cube[Translate[B6, Vector[(0, 0, v)]], true], v, 0, n6)
c7 = Sequence(Cube[Translate[B7, Vector[(0, 0, v)]], true], v, 0, n7)
c8 = Sequence(Cube[Translate[B8, Vector[(0, 0, v)]], true], v, 0, n8)
c9 = Sequence(Cube[Translate[B9, Vector[(0, 0, v)]], true], v, 0, n9)
c10 = Sequence(Cube[Translate[B10, Vector[(0, 0, v)]], true], v, 0, n10)
c11 = Sequence(Cube[Translate[B11, Vector[(0, 0, v)]], true], v, 0, n11)
c12 = Sequence(Cube[Translate[B12, Vector[(0, 0, v)]], true], v, 0, n12)
c13 = Sequence(Cube[Translate[B13, Vector[(0, 0, v)]], true], v, 0, n13)
c14 = Sequence(Cube[Translate[B14, Vector[(0, 0, v)]], true], v, 0, n14)
c15 = Sequence(Cube[Translate[B15, Vector[(0, 0, v)]], true], v, 0, n15)
c16 = Sequence(Cube[Translate[B16, Vector[(0, 0, v)]], true], v, 0, n16)
c17 = Sequence(Cube[Translate[B17, Vector[(0, 0, v)]], true], v, 0, n17)
c18 = Sequence(Cube[Translate[B18, Vector[(0, 0, v)]], true], v, 0, n18)
c19 = Sequence(Cube[Translate[B19, Vector[(0, 0, v)]], true], v, 0, n19)
c20 = Sequence(Cube[Translate[B20, Vector[(0, 0, v)]], true], v, 0, n20)
c21 = Sequence(Cube[Translate[B21, Vector[(0, 0, v)]], true], v, 0, n21)
c22 = Sequence(Cube[Translate[B22, Vector[(0, 0, v)]], true], v, 0, n22)
c23 = Sequence(Cube[Translate[B23, Vector[(0, 0, v)]], true], v, 0, n23)
c24 = Sequence(Cube[Translate[B24, Vector[(0, 0, v)]], true], v, 0, n24)
c25 = Sequence(Cube[Translate[B25, Vector[(0, 0, v)]], true], v, 0, n25)
text1 = Text(n1 + 1, Centroid[B1] + (-0.12, -0.21))
text2 = Text(n2 + 1, Centroid[B2] + (-0.12, -0.21))
text3 = Text(n3 + 1, Centroid[B3] + (-0.12, -0.21))
text4 = Text(n4 + 1, Centroid[B4] + (-0.12, -0.21))
text5 = Text(n5 + 1, Centroid[B5] + (-0.12, -0.21))
text6 = Text(n6 + 1, Centroid[B6] + (-0.12, -0.21))
text7 = Text(n7 + 1, Centroid[B7] + (-0.12, -0.21))
text8 = Text(n8 + 1, Centroid[B8] + (-0.12, -0.21))
text9 = Text(n9 + 1, Centroid[B9] + (-0.12, -0.21))
text10 = Text(n10 + 1, Centroid[B10] + (-0.12, -0.21))
text11 = Text(n11 + 1, Centroid[B11] + (-0.12, -0.21))
text12 = Text(n12 + 1, Centroid[B12] + (-0.12, -0.21))
text13 = Text(n13 + 1, Centroid[B13] + (-0.12, -0.21))
text14 = Text(n14 + 1, Centroid[B14] + (-0.12, -0.21))
text15 = Text(n15 + 1, Centroid[B15] + (-0.12, -0.21))
text16 = Text(n16 + 1, Centroid[B16] + (-0.12, -0.21))
text17 = Text(n17 + 1, Centroid[B17] + (-0.12, -0.21))
text18 = Text(n18 + 1, Centroid[B18] + (-0.12, -0.21))
text19 = Text(n19 + 1, Centroid[B19] + (-0.12, -0.21))
text20 = Text(n20 + 1, Centroid[B20] + (-0.12, -0.21))
text21 = Text(n21 + 1, Centroid[B21] + (-0.12, -0.21))
text22 = Text(n22 + 1, Centroid[B22] + (-0.12, -0.21))
text23 = Text(n23 + 1, Centroid[B23] + (-0.12, -0.21))
text24 = Text(n24 + 1, Centroid[B24] + (-0.12, -0.21))
text25 = Text(n25 + 1, Centroid[B25] + (-0.12, -0.21))
a: false
b = false
text26 = LaTeX("请点击小格子,\textcolor{red}{" + (If[b, "增加", "减少"]) + "}小立方体")
n0: -1
A = (5.042007493939051, -0.48202897005339235)
B = (7.404351111287346, -0.48202897005339235)

Tool: 坐标系
x最小、最大，y最小、最大，0.23
Input: m, n, q, p, a
Output: A, B, O, l1, l2, list3, list4, list5, list6, u, v

$\huge\textcolor{}{x}$

$\huge\textcolor{}{y}$

$\Large{O}$

u = Vector((m - 1, 0), (n + 1, 0))
l1 = Sequence(Segment[(k, 0), (k, a)], k, m, n)
A: (n + 1, 0)
list4 = Sequence(Text[k, Element[Sequence[(t - 0.15, 0), t, 1, n], k], true, true], k, 1, n)
list3 = Sequence(Text[k, Element[Sequence[(t - 0.5, 0), t, m, -1], k + abs(m) + 1], true, true], k, m, -1)
l2 = Sequence(Segment[(0, k), (a, k)], k, q, p)
list5 = Sequence(Text[k, Element[Sequence[(-0.9, t + 0.2), t, q, -1], k + abs(q) + 1], true, true], k, q, -1)
v = Vector((0, q - 1), (0, p + 1))
B: (0, p + 1)
list6 = Sequence(Text[k, Element[Sequence[(-0.6, t + 0.2), t, 1, p], k], true, true], k, 1, p)
O: B - (0, p + 1)