On Wed, Jun 24, 2009 at 1:55 PM, Ed Keith<[email protected]> wrote:
> I type "3 %: _8" into J and was surprised when I got "1j1.73205".

> Is there a way to generate all roots?

Sure, just multiply any one root by the roots of 1:

allroots=: (([:r.i.*[:o.2&%)@[ * %:)"0
3 allroots 8
   2 _1j1.73205 _1j_1.73205

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

Reply via email to