Re: nth roots of complex numbers
- To: mathgroup at smc.vnet.net
- Subject: [mg39078] Re: nth roots of complex numbers
- From: Friedrich Laher <mathefritz at schmieder-laher.de>
- Date: Sun, 26 Jan 2003 18:44:29 -0500 (EST)
- References: <b10ddh$mou$1@smc.vnet.net>
- Sender: owner-wri-mathgroup at wolfram.com
Zachary Turner schrieb: > Apparently Mathematica randomly returns roots a root of a complex number. > Is there a way I can write my own function that will return a set consisting > of all n roots of a given complex number. For example, Root[z,n] = {a set > consisting of n elements} > > > LstOfRoots[z_, n_] := Module[{a = Abs[z]^(1/n), f}, f[i_] := a Root[#^n - 1, i]; Map[f, Range[n]]] Example LstOfRoots[5,3] in attachment math.gif [contact the author to get this attachment - moderator]