Rotating a hendecagon on the circle of fifths produces either the circle of fourths or circle of fifths, whichever is in the opposite direction of the rotation.
This visualization was written in Java using a graphical library called Processing (https://processing.org), and Java's built-in MIDI library for sound (package javax.sound.midi).
________
Interested in learning more about algorithms and how to program? Here are some useful and/or classic textbooks that I recommend (these are affiliate links, if you buy one, I get a small commission):
▶ “Algorithms” (4th Edition) by Robert Sedgewick & Kevin Wayne: https://amzn.to/3uo25xR
▶ “Effective Java” (3rd Edition) by Joshua Bloch: https://amzn.to/3HOnYJL
▶ “Design Patterns: Elements of Reusable Object-Oriented Software” by Erich Gamma, Richard Helm, Ralph Johnson, & John Vlissides: https://amzn.to/49fpr7R
▶ “Discrete Algorithmic Mathematics” by Stephen B. Maurer & Anthony Ralston: https://amzn.to/4bmsOvG
#music #visualization #polygon #pentagon #circleoffifths #musictheory #scale #chromaticscale #math #geometry #rotation #modulararithmetic