The <tgmath.h> header defines a type-generic macro for each mathematical function defined in <math.h> and <complex.h>.
The <tgmath.h> header shall define the following macros:
For all functions that have both real and complex counterparts, a type-generic macro XXX exists.
For all functions that do not have complex counterparts, a type-generic macro XXX exists.
For all complex number functions that do not have real counterparts, a type-generic macro cXXX exists.
Related topics:
<threads.h> | <time.h> | <uchar.h> | <wchar.h> | <wctype.h> | Standard Library in C
List of topics: C Programming
The <tgmath.h> header shall define the following macros:
For all functions that have both real and complex counterparts, a type-generic macro XXX exists.
| Type-generic macro | Real function variants | Complex function variants | ||||
|---|---|---|---|---|---|---|
| float | double | long double | float | double | long double | |
| fabs | fabsf | fabs | fabsl | cabsf | cabs | cabsl | 
| exp | expf | exp | expl | cexpf | cexp | cexpl | 
| log | logf | log | logl | clogf | clog | clogl | 
| pow | powf | pow | powl | cpowf | cpow | cpowl | 
| sqrt | sqrtf | sqrt | sqrtl | csqrtf | csqrt | csqrtl | 
| sin | sinf | sin | sinl | csinf | csin | csinl | 
| cos | cosf | cos | cosl | ccosf | ccos | ccosl | 
| tan | tanf | tan | tanl | ctanf | ctan | ctanl | 
| asin | asinf | asin | asinl | casinf | casin | casinl | 
| acos | acosf | acos | acosl | cacosf | cacos | cacosl | 
| atan | atanf | atan | atanl | catanf | catan | catanl | 
| sinh | sinhf | sinh | sinhl | csinhf | csinh | csinhl | 
| cosh | coshf | cosh | coshl | ccoshf | ccosh | ccoshl | 
| tanh | tanhf | tanh | tanhl | ctanhf | ctanh | ctanhl | 
| asinh | asinhf | asinh | asinhl | casinhf | casinh | casinhl | 
| acosh | acoshf | acosh | acoshl | cacoshf | cacosh | cacoshl | 
| atanh | atanhf | atanh | atanhl | catanhf | catanh | catanhl | 
For all functions that do not have complex counterparts, a type-generic macro XXX exists.
| Type-generic macro | Real function variants | ||
|---|---|---|---|
| float | double | long double | |
| atan2 | atan2f | atan2 | atan2l | 
| cbrt | cbrtf | cbrt | cbrtl | 
| ceil | ceilf | ceil | ceill | 
| copysign | copysignf | copysign | copysignl | 
| erf | erff | erf | erfl | 
| erfc | erfcf | erfc | erfcl | 
| exp2 | exp2f | exp2 | exp2l | 
| expm1 | expm1f | expm1 | expm1l | 
| fdim | fdimf | fdim | fdiml | 
| floor | floorf | floor | floorl | 
| fma | fmaf | fma | fmal | 
| fmax | fmaxf | fmax | fmaxl | 
| fmin | fminf | fmin | fminl | 
| fmod | fmodf | fmod | fmodl | 
| frexp | frexpf | frexp | frexpl | 
| hypot | hypotf | hypot | hypotl | 
| ilogb | ilogbf | ilogb | ilogbl | 
| ldexp | ldexpf | ldexp | ldexpl | 
| lgamma | lgammaf | lgamma | lgammal | 
| llrint | llrintf | llrint | llrintl | 
| llround | llroundf | llround | llroundl | 
| log10 | log10f | log10 | log10l | 
| log1p | log1pf | log1p | log1pl | 
| log2 | log2f | log2 | log2l | 
| logb | logbf | logb | logbl | 
| lrint | lrintf | lrint | lrintl | 
| lround | lroundf | lround | lroundl | 
| nearbyint | nearbyintf | nearbyint | nearbyintl | 
| nextafter | nextafterf | nextafter | nextafterl | 
| nexttoward | nexttowardf | nexttoward | nexttowardl | 
| remainder | remainderf | remainder | remainderl | 
| remquo | remquof | remquo | remquol | 
| rint | rintf | rint | rintl | 
| round | roundf | round | roundl | 
| scalbln | scalblnf | scalbln | scalblnl | 
| scalbn | scalbnf | scalbn | scalbnl | 
| tgamma | tgammaf | tgamma | tgammal | 
| trunc | truncf | trunc | truncl | 
For all complex number functions that do not have real counterparts, a type-generic macro cXXX exists.
| Type-generic macro | Complex function variants | ||
|---|---|---|---|
| float | double | long double | |
| carg | cargf | carg | cargl | 
| conj | conjf | conj | conjl | 
| creal | crealf | creal | creall | 
| cimag | cimagf | cimag | cimagl | 
| cproj | cprojf | cproj | cprojl | 
Related topics:
<threads.h> | <time.h> | <uchar.h> | <wchar.h> | <wctype.h> | Standard Library in C
List of topics: C Programming
 
No comments:
Post a Comment