Having never used J's plotting facilities before, I played a bit
with the already mentioned 'shamrock' curve.  More precisely,
I tried (in J6.02/Linux) both

    (A) 'radar' plot rng;'D&+@(cos+*:@sin)@(N&*)'

and

    (B) pd (D&+@(cos+*:@sin)@(N&*);]) steps rng   (with 'polar 1')

for lots of values for N (positive integers) and D (reals).
rng  was (0 2p1) or (0 2p1 2000).

I ran into a number of issues.

  * (A) does not produce correct plots for D<0.

  * With (A), if only the range (0 2p1) is specified (but no number
    of steps), the resulting curve can be anywhere from partly wrong
    to a complete mess (while it should only differ in quality of
    approximation).

  * (A) disregards the 'aspect' option.  It uses the aspect ratio of
    whatever plot window is already open or has been open before.
    On the other hand, the background ('radar') circles remain intact
    (if they represent 'coordinate lines' in the polar plotting mode,
    I would expect them to become ellipses).

  * Setting 'aspect 1' with (B) does not actually produce a plot with
    this ratio.  (I have noticed that Gnuplot has a similar deffect.)

  * If, having executed (A) and not closed its plot window, (B) is
    attempted, it produces a 'length error' rather than a plot.
----------------------------------------------------------------------
For information about J forums see http://www.jsoftware.com/forums.htm

Reply via email to