0

动态画数轴

g = Segment((0, 0), (0, 0.2))
n = 26 (slider from 0 to 26, step 1)
u = Vector((-6, 0), (7, 0))
f = Segment((-6, 0), (7, 0))
l1 = Flatten({1…6, -1…-5})
l2 = Zip(Segment[(k, 0), (k, 0.2)], k, l1)
A = (-0.21454545454545504, -0.6418181818181812)
l3 = Zip(Text[k, A + (k, 0)], k, l1)
l4 = Flatten(Zip[{p, q}, p, l2, q, l3])
l5 = Sequence(Take[l4, k, If[Mod[k, 2] ≟ 1, k]], k, 1, n - 4)
l6 = Sequence(Take[l4, k, If[Mod[k, 2] ≟ 0, k]], k, 1, n - 4)
B = (5.550454545454546, 1.1381818181818206)
C = (9.24045454545454, 1.1381818181818206)