RD> I want to construct and plot a Squircle in J. [...] RD> RD> Has anyone a good idea for performing that calculation? Could the J RD> function plot then draw the Squircle?
It is easy to "plot" parametric functions in the complex plane. Here are three parametric functions, to be computed over parameter inputs for a full circle, say, -pi to pi in 200 tiny steps: circle =. cos j. sin square =. cos j.&* sin squircle =. (square + circle) % 2: NB. your "mean" of the functions. NB. Show time! plot (circle , square ,: squircle) i: 1p1 j. 200 Martin Neitzel PS: That * in cos j.&* sin is Sign, bulging out the circle to the full 1 _1 (square) borders. Have some thoughts on what actually happens when the Sign * acts on and returns a 0, and how that shows up. ---------------------------------------------------------------------- For information about J forums see http://www.jsoftware.com/forums.htm