Spirographs. Write a program that takes three double command-line arguments R, r, and a and draws the resulting spirograph. A spirograph (technically, an epicycloid) is a curve formed by rolling a circle of radius r around a larger fixed circle of radius R. If the pen offset from the center of the rolling circle is (r+a), then the equation of the resulting curve at time t is given by
Such curves were popularized by a best-selling toy that contains discs with gear teeth on the edges and small holes that you could put a pen in to trace Spiro graphs.
Already registered? Login
Not Account? Sign up
Enter your email address to reset your password
Back to Login? Click here