This small Arduino construction reproduces the machanics of a (single) ball kept inside a torus. By moving the Arduino board itself accross the 6 dimansions, the ball circulates inside.
The behavior is calculated realtime by the processor, based on standard mechanics equations, using moment of inertia.
All calculations are based on Euler angles, in the canonical (first) approach based on the ZXZ angles: ψ (psi), θ (theta) then φ (phi). This picture from Berkeley University explains the used notation.
Few notations:
- the torus has a radius of l
- α (alpha) is the angle of the ball in the torus referential with x axis
- g is the gravity constant
Assuming a fixed board, where its z axis points verticaly upward, the only moment is from the gravity force:
Then as the board is actually a non galilean referencial, the moment of virtual forces appply too. First as the referential translates along the 3 axis, the monent of the inertia force applies. As the referential rotates, the 3 new virtual forces are the Euler force, the Coriolis force and the centrifugal force. The 3 forces are explained here.
The moment of the 4 virtual forces are equal to:
So the complete equation is:
I have calculated all the equations myself, so if you find any error, please contact me!
Thanks to STLFinder for the picture of the toy.