Namespaces

Types

Type Natural

Namespace MathNet.Numerics

Interfaces IEquatable<Natural>, IComparable<Natural>

Methods

Properties

Public instance methods

Natural Add(Natural number)

Add a natural number to this natural number.
Parameters
return Natural
Natural number

Natural Add(Natural number, uint carry)

Add an unsigned integer to this natural number.
Parameters
return Natural
Natural number
uint carry

int CompareTo(Natural other)

Compares this natural number with another natural number.
Parameters
return int
Natural other

bool Equals(object obj)

Parameters
return bool
object obj

bool Equals(Natural other)

Checks whether this natural number is equal to another natural number.
Parameters
return bool
Natural other

int GetHashCode()

Parameters
return int

Type GetType()

Parameters
return Type

Natural Multiply(Natural number)

Multiply this natural number with another natural number.
Parameters
return Natural
Natural number

Natural Multiply(uint factor)

Stretch this natural number by an integer factor.
Parameters
return Natural
uint factor

Natural Subtract(Natural number)

Subtract a natural number from this natural number.
Parameters
return Natural
Natural number

Natural Subtract(Natural number, uint carry, Boolean& underflow)

Parameters
return Natural
Natural number
uint carry
Boolean& underflow

Natural Subtract(Natural number, Boolean& underflow)

Parameters
return Natural
Natural number
Boolean& underflow

string ToString()

Parameters
return string

Public static methods

Natural From(uint number)

Create a natural number from an unsigned integer.
Parameters
return Natural
uint number

Natural From(ulong number)

Create a natural number from an unsigned long integer.
Parameters
return Natural
ulong number

Natural Max(Natural a, Natural b)

Returns the bigger of two natural numbers.
Parameters
return Natural
Natural a
Natural b

Natural Min(Natural a, Natural b)

Returns the smaller of two natural numbers.
Parameters
return Natural
Natural a
Natural b

Public properties

uint Degree get;

The biggest exponent with a non-zero coefficient.
return uint

bool IsZero get;

True if this natural number represents zero.
return bool

Natural One get;

Natural number representing one.
return Natural

ulong Radix get;

The number system/base of this number.
return ulong

Natural Two get;

Natural number representing two.
return Natural

Natural Zero get;

Natural number representing zero.
return Natural