dly wrote:
> Can you demonstrate this function with some arguments?

>>> angle =:12&o.
>
  angle=:12&o.
  roots=:[:^ 0j2p1&% * i. NB. roots of unity
  roots 8
1 0.707107j0.707107 0j1 _0.707107j0.707107 _1 _0.707107j_0.707107 0j_1
0.707107j_0.707107
   +. roots 8
        1         0
 0.707107  0.707107
        0         1
_0.707107  0.707107
       _1         0
_0.707107 _0.707107
        0        _1
 0.707107 _0.707107
   angle roots 8
0 0.785398 1.5708 2.35619 3.14159 _2.35619 _1.5708 _0.785398
   (angle roots 8)%2p1
0 0.125 0.25 0.375 0.5 _0.375 _0.25 _0.125

Best wishes,

John

----------------------------------------------------------------------
For information about J forums see http://www.jsoftware.com/forums.htm

Reply via email to