Complex<T>.Root Of Unity Method
Returns a complex number that is the specified
root of unity of the specified degree.
Definition
Namespace: Numerics.NET
Assembly: Numerics.NET (in Numerics.NET.dll) Version: 9.0.4
C#
A complex number that is the indexth root of unity of degree degree.
Assembly: Numerics.NET (in Numerics.NET.dll) Version: 9.0.4
public static Complex<T> RootOfUnity(
int degree,
int index
)
Parameters
Return Value
Complex<T>A complex number that is the indexth root of unity of degree degree.
Remarks
The roots of unity are the solutions to the equation zn= R.One, with n the degree, which cannot be zero. There are exactly n solutions to this equations. Together, they give the coordinates of a regular n-sided polygon with its center at the origin, its vertices at unit distance from the origin, and its first vertex on the real axis.
This method returns the roots of the specified degree in counter-clockwise order. The index can be any integer value.
This method requires that the operand type supports real arithmetic.
Exceptions
Argument | degree is equal to zero. |