Computes the inverse logarithm

You're viewing an older version of this page (#934). View the current version.

View versions (2)

Interface

#include <codecogs/maths/combinatorics/arithmetic/log_inv.h>

using namespace Maths::Combinatorics::Arithmetic;

Overview

Function to compute the inverse logarithm, by feeding it with the base and the result.

Example 1

Computing

\log_{10} x = 2
(1)
printf("Inverse logarithm of base 10 resulting 2: %d ",log_inv(10,2));

Output:

Inverse logarithm of base 10 resulting 2: 100

It will return -1 for incorrect base input ( good input goes from +1* to +infinite).

* - +1 means the first number right after 1 (ie. 1,0001).

Parameters

base
Any value above 1
result
Any value (even negative)

Returns

The value to apply the logarithm operator ( log x )
GPL Licence — free for non commercial use. See Licence details.

DECLARATION

log_inv

This class contains functions that aren't avaible in System.Math class.

Author

Johny Void