BigInteger.Log10(BigInteger) Method

Definition

Returns the base 10 logarithm of a specified number.

public static double Log10 (System.Numerics.BigInteger value);

Parameters

value
BigInteger

A number whose logarithm is to be found.

Returns

The base 10 logarithm of value, as shown in the table in the Remarks section.

Exceptions

The base 10 log of value is out of range of the Double data type.

Remarks

The value parameter is specified as a base 10 number.

The precise return value of the method depends on the sign of value, as the following table shows.

Sign of value parameter Return value
Positive The base 10 log of value; that is, log10value.
Zero Double.NegativeInfinity.
Negative Double.NaN.

To calculate the natural logarithm of a BigInteger value, call the BigInteger.Log(BigInteger) method. To calculate the logarithm of a number in another base, call the BigInteger.Log(BigInteger, Double) method.

This method corresponds to the Math.Log10 method for the primitive numeric types.

Applies to

Product Versions
.NET Core 1.0, Core 1.1, Core 2.0, Core 2.1, Core 2.2, Core 3.0, Core 3.1, 5, 6, 7, 8, 9
.NET Framework 4.0, 4.5, 4.5.1, 4.5.2, 4.6, 4.6.1, 4.6.2, 4.7, 4.7.1, 4.7.2, 4.8, 4.8.1
.NET Standard 1.1, 1.2, 1.3, 1.4, 1.6, 2.0, 2.1
UWP 10.0