Namespaces
Variants
Actions

std::log, std::logf, std::logl

From cppreference.com
< cpp‎ | numeric‎ | math
 
 
 
 
Defined in header <cmath>
(1)
float       log ( float num );

double      log ( double num );

long double log ( long double num );
(until C++23)
/*floating-point-type*/
            log ( /*floating-point-type*/ num );
(since C++23)
(constexpr since C++26)
float       logf( float num );
(2) (since C++11)
(constexpr since C++26)
long double logl( long double num );
(3) (since C++11)
(constexpr since C++26)
SIMD overload (since C++26)
Defined in header <simd>
template< /*math-floating-point*/ V >

constexpr /*deduced-simd-t*/<V>

            log ( const V& v_num );
(S) (since C++26)
Additional overloads (since C++11)
Defined in header <cmath>
template< class Integer >
double      log ( Integer num );
(A) (constexpr since C++26)
1-3) Computes the natural (base-e) logarithm of num. The library provides overloads of std::log for all cv-unqualified floating-point types as the type of the parameter.(since C++23)
S) The SIMD overload performs an element-wise std::log on v_num.
(See