標準/拡張機能 | C/C++ | 依存項目 |
---|---|---|
C/C++ DFP | 両方 | z/OS® V1.11 |
#define __STDC_WANT_DEC_FP__
#include <math.h>
_Decimal32 log1pd32(_Decimal32 x);
_Decimal64 log1pd64(_Decimal64 x);
_Decimal128 log1pd128(_Decimal128 x);
_Decimal32 log1p(_Decimal32 x); /* C++ only */
_Decimal64 log1p(_Decimal64 x); /* C++ only */
_Decimal128 log1p(_Decimal128 x); /* C++ only */
正常に実行された場合、log1p() は Log (1.0 + x) を返します。x の値は、-1.0 より大きい数でなければなりません。
⁄* CELEBL27
This exaxmple illustrates the log1pd128() function.
*⁄
#define __STDC_WANT_DEC_FP__
#include <math.h>
#include <stdio.h>
void main(void)
{
_Decimal128 x, y;
x = 23.2DL;
y = log1pd128(x);
printf("log1pd128( %DDf ) = %DDf¥n", x , y);
}