I DID NOT WRITE THIS CODE. You can find the original at https://www.a1k0n.net/2011/07/20/donut-math.html I just thought it was super cool and wanted to share it with you! :)