Skip to content

roulette

6 motifs. Import them from geomotif.motifs, or build one by name with registry.create("epicycles").

epicycles

epicycles

Rotating arms stacked tip to tail; the path of the last tip.

from geomotif import save_svg
from geomotif.motifs import Epicycles

motif = Epicycles()
save_svg(motif.build(), "epicycles.svg", width=320, height=320)
geomotif render epicycles --out epicycles.svg
{
  "geomotif": "1.3.1",
  "motif": "epicycles",
  "params": {
    "resolution": null,
    "arms": [
      [
        120.0,
        1.0,
        0.0
      ],
      [
        30.0,
        7.0,
        0.0
      ],
      [
        12.0,
        13.0,
        0.0
      ]
    ],
    "turns": 1.0,
    "center": [
      0.0,
      0.0
    ]
  }
}
Parameters
Name Type Default Notes
arms tuple[tuple[float, float, float], ...] ((120.0, 1.0, 0.0), (30.0, 7.0, 0.0), (12.0, 13.0, 0.0))
turns float 1.0
center Point (0.0, 0.0)
resolution int | None None Segments per strand -- a strand gets one more point than that, so both ends are included. None (default) scales density with the winding.

roulette.epicycloid

roulette.epicycloid

A point on the rim of a wheel rolling outside a ring: a ring of petals.

from geomotif import save_svg
from geomotif.motifs import Epicycloid

motif = Epicycloid()
save_svg(motif.build(), "roulette.epicycloid.svg", width=320, height=320)
geomotif render roulette.epicycloid --out roulette.epicycloid.svg
{
  "geomotif": "1.3.1",
  "motif": "roulette.epicycloid",
  "params": {
    "resolution": null,
    "outer": 100,
    "inner": 30,
    "center": [
      0.0,
      0.0
    ]
  }
}
Parameters
Name Type Default Notes
outer int 100
inner int 30
center Point (0.0, 0.0)
resolution int | None None Segments per strand -- a strand gets one more point than that, so both ends are included. None (default) scales density with the winding.

roulette.epitrochoid

roulette.epitrochoid

A pen fixed to a wheel rolling around the outside of a ring.

from geomotif import save_svg
from geomotif.motifs import Epitrochoid

motif = Epitrochoid()
save_svg(motif.build(), "roulette.epitrochoid.svg", width=320, height=320)
geomotif render roulette.epitrochoid --out roulette.epitrochoid.svg
{
  "geomotif": "1.3.1",
  "motif": "roulette.epitrochoid",
  "params": {
    "resolution": null,
    "outer": 100,
    "inner": 30,
    "offset": 45.0,
    "center": [
      0.0,
      0.0
    ]
  }
}
Parameters
Name Type Default Notes
outer int 100
inner int 30
offset float 45.0
center Point (0.0, 0.0)
resolution int | None None Segments per strand -- a strand gets one more point than that, so both ends are included. None (default) scales density with the winding.

roulette.hypocycloid

roulette.hypocycloid

A point on the rim of a wheel rolling inside a ring: a cusped star.

from geomotif import save_svg
from geomotif.motifs import Hypocycloid

motif = Hypocycloid()
save_svg(motif.build(), "roulette.hypocycloid.svg", width=320, height=320)
geomotif render roulette.hypocycloid --out roulette.hypocycloid.svg
{
  "geomotif": "1.3.1",
  "motif": "roulette.hypocycloid",
  "params": {
    "resolution": null,
    "outer": 100,
    "inner": 30,
    "center": [
      0.0,
      0.0
    ]
  }
}
Parameters
Name Type Default Notes
outer int 100
inner int 30
center Point (0.0, 0.0)
resolution int | None None Segments per strand -- a strand gets one more point than that, so both ends are included. None (default) scales density with the winding.

roulette.hypotrochoid

roulette.hypotrochoid

A pen fixed to a wheel rolling around the inside of a ring.

from geomotif import save_svg
from geomotif.motifs import Hypotrochoid

motif = Hypotrochoid()
save_svg(motif.build(), "roulette.hypotrochoid.svg", width=320, height=320)
geomotif render roulette.hypotrochoid --out roulette.hypotrochoid.svg
{
  "geomotif": "1.3.1",
  "motif": "roulette.hypotrochoid",
  "params": {
    "resolution": null,
    "outer": 100,
    "inner": 30,
    "offset": 45.0,
    "center": [
      0.0,
      0.0
    ]
  }
}
Parameters
Name Type Default Notes
outer int 100
inner int 30
offset float 45.0
center Point (0.0, 0.0)
resolution int | None None Segments per strand -- a strand gets one more point than that, so both ends are included. None (default) scales density with the winding.

spirograph

spirograph

The toy, in the toy's own terms: a ring, a wheel and a hole.

from geomotif import save_svg
from geomotif.motifs import Spirograph

motif = Spirograph()
save_svg(motif.build(), "spirograph.svg", width=320, height=320)
geomotif render spirograph --out spirograph.svg
{
  "geomotif": "1.3.1",
  "motif": "spirograph",
  "params": {
    "resolution": null,
    "ring_teeth": 96,
    "wheel_teeth": 36,
    "hole": 0.7,
    "ring_radius": 150.0,
    "center": [
      0.0,
      0.0
    ]
  }
}
Parameters
Name Type Default Notes
ring_teeth int 96
wheel_teeth int 36
hole float 0.7
ring_radius float 150.0
center Point (0.0, 0.0)
resolution int | None None Segments per strand -- a strand gets one more point than that, so both ends are included. None (default) scales density with the winding.