BigInteger::Pow Method (BigInteger, Int32)
Raises a BigInteger value to the power of a specified value.
Assembly: System.Numerics (in System.Numerics.dll)
Parameters
- value
-
Type:
System.Numerics::BigInteger
The number to raise to the exponent power.
- exponent
-
Type:
System::Int32
The exponent to raise value by.
| Exception | Condition |
|---|---|
| ArgumentOutOfRangeException | The value of the exponent parameter is negative. |
The Pow method returns 1 if the value of the exponent parameter is 0, or if the values of both the value and exponent parameters are 0. If exponent is 1, the Pow method returns value. If value is negative, the method returns a negative result.
This method corresponds to the Math::Pow method for primitive numeric types.
The following example illustrates exponentiation using a BigInteger value and an exponent whose value ranges from 0 to 10.
Available since 8
.NET Framework
Available since 4.0
Portable Class Library
Supported in: portable .NET platforms
Silverlight
Available since 4.0
Windows Phone
Available since 8.1