Operator Subtraction
Subtraction(BigRational, BigRational)
Subtracts a BigRational value from another BigRational value.
Declaration
public static BigRational operator -(BigRational a, BigRational b)
Parameters
Type | Name | Description |
---|---|---|
BigRational | a | The value to subtract from (the minuend). |
BigRational | b | The value to subtract (the subtrahend). |
Returns
Type | Description |
---|---|
BigRational | The result of subtracting b from a. |
Subtraction(BigRational, Int64)
Subtracts the values of a specified BigRational from another System.Int64 value.
Declaration
public static BigRational operator -(BigRational a, long b)
Parameters
Type | Name | Description |
---|---|---|
BigRational | a | The value to subtract from (the minuend). |
System.Int64 | b | The value to subtract (the subtrahend). |
Returns
Type | Description |
---|---|
BigRational | The result of subtracting b from a. |
Remarks
Fast subtraction of common cases like: x - 1
.
Note that all smaller signed and unsigned integer types are automatically mapped to this operator, which is efficient on 64-bit systems.
Subtraction(Int64, BigRational)
Subtracts the values of a specified System.Int64 from another BigRational value.
Declaration
public static BigRational operator -(long a, BigRational b)
Parameters
Type | Name | Description |
---|---|---|
System.Int64 | a | The value to subtract from (the minuend). |
BigRational | b | The value to subtract (the subtrahend). |
Returns
Type | Description |
---|---|
BigRational | The result of subtracting b from a. |
Remarks
Fast subtraction of common cases like: 1 - x
.
Note that all smaller signed and unsigned integer types are automatically mapped to this operator, which is efficient on 64-bit systems.