input value
the natural logarithm of 1+x
var v = log1p( 4.0 );
// returns ~1.609
var v = log1p( -1.0 );
// returns -Infinity
var v = log1p( 0.0 );
// returns 0.0
var v = log1p( -0.0 );
// returns -0.0
var v = log1p( -2.0 );
// returns NaN
var v = log1p( NaN );
// returns NaN
Evaluates the natural logarithm of
1+x.Notes
x < -1, the function returnsNaN, as the natural logarithm is not defined for negative numbers.