Complex Structure

Represents a complex number.

Definition

Namespace: Meta.Numerics
Assembly: Meta.Numerics (in Meta.Numerics.dll) Version: 4.2.0+6d77d64445f7d5d91b12e331399c4362ecb25333
C#
public readonly struct Complex : IEquatable<Complex>
Inheritance
Object    ValueType    Complex
Implements
IEquatableComplex

Remarks

Version 4.0 of the .NET Framework introduced a Complex structure equivalent to this one. To maintain compatibility with earlier versions of the .NET Framework, Meta.Numerics maintains its own Complex structure. The Meta.Numerics complex type and the .NET Framework complex type can be used interchangably, because Meta.Numerics defines an implicit cast between them.

Constructors

Complex Initializes a new complex number.

Properties

Conjugate Gets the complex conjugate of the complex number.
Im Gets the imaginary part of the complex number.
Re Gets the real part of the complex number.

Methods

Equals(Complex) Determines whether the given complex number is the same.
Equals(Object) Determines whether the given object represents the same complex number.
(Overrides ValueTypeEquals(Object))
GetHashCode Returns a hash code for the complex number.
(Overrides ValueTypeGetHashCode)
GetTypeGets the Type of the current instance.
(Inherited from Object)
IsNaN Determines if the given complex number is not-a-number.
ToString Produces a string representation of the complex number.
(Overrides ValueTypeToString)

Operators

Addition(Complex, Complex) Adds two complex numbers.
Addition(Complex, Double) Computes the sum of a complex and a real number.
Addition(Double, Complex) Computes the sum of a real and a complex number.
Division(Complex, Complex) Divides two complex numbers.
Division(Complex, Double) Divides a complex number by a real number.
Equality(Complex, Complex) Tests the equality of two complex numbers.
(Complex to Double) Converts the complex number to a double-precision real number.
(Complex to Complex) Converts a Meta.Numerics.Complex number to a System.Numerics.Complex number.
(Complex to Complex) Converts a System.Numerics.Complex number to a Meta.Numerics.Complex number.
(Double to Complex) Converts a double-precision real number to a complex number.
Inequality(Complex, Complex) Tests the inequality of two complex numbers.
Multiply(Complex, Complex) Multiplies two complex numbers.
Multiply(Complex, Double) Multiplies a real number by a complex number.
Multiply(Double, Complex) Multiplies a complex number by a real number.
Subtraction(Complex, Complex) Subtracts the second complex number from the first.
UnaryNegation(Complex) Negates a complex number.

Fields

I Gets the square root of negative one.
One Gets one as a complex number.
Zero Gets zero as a complex number.

See Also