ParaMonte Fortran 2.0.0
Parallel Monte Carlo and Machine Learning Library
See the latest version documentation. |
Generate and return .true.
if and only if the input positive integer
is a whole-number (integer) power of the specified integer base
.
More...
Generate and return .true.
if and only if the input positive integer
is a whole-number (integer) power of the specified integer base
.
The procedures of this generic interface rely on the binary representation of numbers to determine if the number is a power of base two.
For all other cases, an iterative division approach is used to determine the output.
[in] | absx | : The input scalar (or array of the same rank, shape, and size as other array-like arguments) of, representing the absolute value of the number for which the next integer exponent in specified base must be computed. |
[in] | base | : The input positive scalar (or array of the same rank, shape, and size as other array-like arguments), of the same type and kind as absx , representing the base of the exponentiation.(optional, default = 2 ) |
powisint
: The output scalar (or array of the same rank, shape, and size as other array-like arguments), of the type logical
of default kind LK that is .true.
if and only if the input absx
is an integer power of the input absx
.
Possible calling interfaces ⛓
0 < absx
must hold.1 <= base
must hold.CHECK_ENABLED=1
.pure
procedure(s) documented herein become impure
when the ParaMonte library is compiled with preprocessor macro CHECK_ENABLED=1
.pure
in release
build and impure
in debug
and testing
builds.elemental
.
Example usage ⛓
ifort
compiler ⛓ ifort
compiler ⛓ gfortran
compiler ⛓
Final Remarks ⛓
If you believe this algorithm or its documentation can be improved, we appreciate your contribution and help to edit this page's documentation and source file on GitHub.
For details on the naming abbreviations, see this page.
For details on the naming conventions, see this page.
This software is distributed under the MIT license with additional terms outlined below.
This software is available to the public under a highly permissive license.
Help us justify its continued development and maintenance by acknowledging its benefit to society, distributing it, and contributing to it.
Definition at line 113 of file pm_mathExp.F90.