Thanks so much for your insight and your fixes.
Regarding the Epicycloid_Mset formula:
Replacing the line "ang=atan(imag(w)/real(w)" with "ang=imag(log(w))" will remove the restriction
of having to use only even numbers of cusps, since the complex log() utilises atan2() internally.
I have been burned before with using atan instead of atan2. atan only works over 180 degrees where atan2 works over the full 360. Your trick for getting atan2 by using the imaginary part of the complex log function is great because that is available within FractInt and Fracton.
I think I see your logic into the inverted astroids. I had noticed that Paul Carlson used the angle to drive the parametric form of the curve. The parameter like you said is a measure of how far you are down a path that describes the curve. Using it this way is only exactly the same for a circle. Rewriting the curve equation to be a function of the angle instead of a function of how far you are along the curve should get rid of the distortion. I think I can see though that there are some limitations by using the angle. Parametric curves can have loops and the same curve written in angle form would have to have more than one solution at the angle of a loop. That probably explains why curves with loops didn't show any evidence of having a loop.
I will credit you for "additional improvements" in the next version of the formula. Thanks so much for solving the problem.