I was inspired this weekend by this video by Robert Howsare:
I’ve seen things like this before and I wanted to explore how to model this in Mathematica. It was fun to explore and it really drove home some ideas about computer programming for me.
The first thing I needed to do was figure out how to find where the hinge point would be given the known locations of the turntables. This figure is how I thought about it:
where and
are the vectors representing the lever arms, and the two perpendicular vectors
and
useful vectors for my analysis.
Let’s let x be the length of and D be the distance between the two centers of the circles. Then we have the following expressions for the length of
:
The left hand side uses the left triangle and the right hand side uses the right triangle. Squaring both sides and canceling the quadratic term leaves us with
Then the length of is given by
It’s not enough to know how long a and b are, though, we need to know their direction. To get the direction of a you can normalize the vector between the circle centers and then multiply by x. The nice thing is that b is just perpendicular to a. If a is {ax, ay}, b is just {ay, -ax} (note there’s another solution but I chose this one so my picture goes down). Then you multiply that normalized perpendicular vector by y and you’re all set.
The reason I thought about programming while doing this is that the set up so far lets me find one hinge, but, if I set up my functions correctly, I should be able to make any number of hinges successively work. Also, the analysis so far is made easy with a language like Mathematica because it has so many built in vector functions like Normalize etc. I can also use the looping tools to collect data points to make pretty pictures and videos like this
Here’s a zoom in on the four designs
It’s cool to see how similar the four are, though not unexpected given how they were constructed.
This was a fun project, and there’s lots of other cool things I could explore (like making the lengths of the arms oscillate at yet a different frequency, for example!). What I’d love to know is whether you can construct the other 3 pictures from just one using some cool math transformation. I’m pretty sure that’s possible but I just brute forced it for this (hey, it’s my last weekend of my spring break, I’m not going to work that hard).