Postscript code for epicycloid?
February 19, 2006 7:51 PM
Subscribe
I want a true vector-based (i.e., not merely a series of thousands of line segments) Postscript or Illustrator file of an
epicycloid where a=5, b=2.
This is the image I'm after. The equations for an epicycloid a=5,b=2 work out to [x=7cos(θ)-2cos(7θ/2), y=7sin(θ)-2sin(7θ/2)], θ=0..4π.
I have no problem creating this in Grapher or Matlab or Maple or what have you using that equation, but if I try to export an EPS file, what I get is essentially a high resolution bitmap — a list of thousands of straight lines that make a facsimile of the shape if it's not enlarged too much.
Does anyone have enough of a command of Postscript to actually write up the code that would generate the
true vector representation? Is that even possible in postscript?
posted by dmd to science & nature (25 comments total)
posted by fandango_matt at 8:01 PM on February 19, 2006