Invertir

Ayuda

invierte = false
h = If(invierte, 0.0, 1.0)
n1 = 2 (slider from 1 to 7, step 1)
n: round(n1)
O = (5.959999999999999, 0.4599999999999999)
r = 4.3 (slider from 3 to 6, step 0.1)
c = Circle(O, r)
m1 = 3 (slider from 3 to 10, step 1)
A = Point(c)
m: round(m1)
B = Rotate(A, 2.0 * 3.141592653589793 / m, O)
u = Vector(A, B)
lista1 = Sequence(A + k * u / n, k, 0.0, n)
lista2a = Sequence(Semicircle[Element[lista1, k + h], Element[lista1, k + 1.0 - h]], k, 1.0, n, 2.0)
lista2b = Sequence(Semicircle[Element[lista1, k + 1.0 - h], Element[lista1, k + h]], k, 2.0, n, 2.0)
lista4 = Sequence(Rotate[A, 2.0 * 3.141592653589793 * k / m, O], k, 0.0, m)
ayuda = false
b = Vector(A, (A + B) / 2.0)
w = Vector((A + B) / 2.0, A)
z = Vector((A + B) / 2.0, O)
a = Vector(O, (A + B) / 2.0)
lista3a = Sequence(Sequence[Rotate[Element[lista2a, s], 2.0 * 3.141592653589793 * k / m, O], k, 1.0, m], s, 1.0, (n + 1.0) / 2.0)
lista3b = Sequence(Sequence[Rotate[Element[lista2b, s], 2.0 * 3.141592653589793 * k / m, O], k, 1.0, m], s, 1.0, (n + 1.0) / 2.0)
lista5 = Sequence(Segment[Element[lista4, k], Element[lista4, k + 1.0]], k, 1.0, m + 0.0 * n)
lista5a = Sequence(Sequence[Rotate[Element[lista2a, s], 2.0 * 3.141592653589793 * k / m + 0.0 * n, O], k, 1.0, m + 0.0 * n], s, 1.0, (n + 1.0) / 2.0 + 0.0 * m)
lista5b = Sequence(Sequence[Rotate[Element[lista2b, s], 2.0 * 3.141592653589793 * k / m + 0.0 * n, O], k, 1.0, m + 0.0 * n], s, 1.0, (n + 1.0) / 2.0 + 0.0 * m)
texto1: n + ""
texto2: m + ""
texto3: r + ""