math.h(3)
β¨ NAME β¨
math.h β hi bestie, this is the avr-libc math header, aka math.h(3). Itβs giving βall the math constants and function prototypes live here.β π
πΈ SYNOPSIS πΈ
okay so first the macros, then the functions. no skipping, weβre listing every single one. π
π Macros π
#define M_E 2.7182818284590452354
#define M_LOG2E 1.4426950408889634074 /* log_2 e */
#define M_LOG10E 0.43429448190325182765 /* log_10 e */
#define M_LN2 0.69314718055994530942 /* log_e 2 */
#define M_LN10 2.30258509299404568402 /* log_e 10 */
#define M_PI 3.14159265358979323846 /* pi */
#define M_PI_2 1.57079632679489661923 /* pi/2 */
#define M_PI_4 0.78539816339744830962 /* pi/4 */
#define M_1_PI 0.31830988618379067154 /* 1/pi */
#define M_2_PI 0.63661977236758134308 /* 2/pi */
#define M_2_SQRTPI 1.12837916709551257390 /* 2/sqrt(pi) */
#define M_SQRT2 1.41421356237309504880 /* sqrt(2) */
#define M_SQRT1_2 0.70710678118654752440 /* 1/sqrt(2) */
#define NAN __builtin_nan('')
#define INFINITY __builtin_inf()
#define __ASM_ALIAS(x) __asm(#x)
π§ Functions π§
float cosf (float __x)
double cos (double __x) __ASM_ALIAS(cosf)
float sinf (float __x)
double sin (double __x) __ASM_ALIAS(sinf)
float tanf (float __x)
double tan (double __x) __ASM_ALIAS(tanf)
static float fabsf (float __x)
static double fabs (double __x)
float fmodf (float __x, float __y)
double fmod (double __x, double __y) __ASM_ALIAS(fmodf)
float modff (float __x, float *__iptr)
double modf (double __x, double *__iptr) __ASM_ALIAS(modff)
float sqrtf (float __x)
double sqrt (double __x) __ASM_ALIAS(sqrtf)
float cbrtf (float __x)
double cbrt (double __x) __ASM_ALIAS(cbrtf)
float hypotf (float __x, float __y)
double hypot (double __x, double __y) __ASM_ALIAS(hypotf)
float squaref (float __x)
double square (double __x) __ASM_ALIAS(squaref)
float floorf (float __x)
double floor (double __x) __ASM_ALIAS(floorf)
float ceilf (float __x)
double ceil (double __x) __ASM_ALIAS(ceilf)
float frexpf (float __x, int *__pexp)
double frexp (double __x, int *__pexp) __ASM_ALIAS(frexpf)
float ldexpf (float __x, int __exp)
double ldexp (double __x, int __exp) __ASM_ALIAS(ldexpf)
float expf (float __x)
double exp (double __x) __ASM_ALIAS(expf)
float coshf (float __x)
double cosh (double __x) __ASM_ALIAS(coshf)
float sinhf (float __x)
double sinh (double __x) __ASM_ALIAS(sinhf)
float tanhf (float __x)
double tanh (double __x) __ASM_ALIAS(tanhf)
float acosf (float __x)
double acos (double __x) __ASM_ALIAS(acosf)
float asinf (float __x)
double asin (double __x) __ASM_ALIAS(asinf)
float atanf (float __x)
double atan (double __x) __ASM_ALIAS(atanf)
float atan2f (float __y, float __x)
double atan2 (double __y, double __x) __ASM_ALIAS(atan2f)
float logf (float __x)
double log (double __x) __ASM_ALIAS(logf)
float log10f (float __x)
double log10 (double __x) __ASM_ALIAS(log10f)
float powf (float __x, float __y)
double pow (double __x, double __y) __ASM_ALIAS(powf)
int isnanf (float __x)
int isnan (double __x) __ASM_ALIAS(isnanf)
int isinff (float __x)
int isinf (double __x) __ASM_ALIAS(isinff)
static int isfinitef (float __x)
static int isfinite (double __x)
static float copysignf (float __x, float __y)
static double copysign (double __x, double __y)
int signbitf (float __x)
int signbit (double __x) __ASM_ALIAS(signbitf)
float fdimf (float __x, float __y)
double fdim (double __x, double __y) __ASM_ALIAS(fdimf)
float fmaf (float __x, float __y, float __z)
double fma (double __x, double __y, double __z) __ASM_ALIAS(fmaf)
float fmaxf (float __x, float __y)
double fmax (double __x, double __y) __ASM_ALIAS(fmaxf)
float fminf (float __x, float __y)
double fmin (double __x, double __y) __ASM_ALIAS(fminf)
float truncf (float __x)
double trunc (double __x) __ASM_ALIAS(truncf)
float roundf (float __x)
double round (double __x) __ASM_ALIAS(roundf)
long lroundf (float __x)
long lround (double __x) __ASM_ALIAS(lroundf)
long lrintf (float __x)
long lrint (double __x) __ASM_ALIAS(lrintf)
π Author π
This page was generated automatically by Doxygen for avr-libc from the source code. Slay. β¨
π avr-libc version 2.1.0, dated Sat Jan 29 2022 β bye bestie, go be iconic with your floats! π
π¦ where this page comes from
- fedora 43: avr-libc 2.2.1-3.fc43 Β· BSD-3-Clause
- fedora 44: avr-libc 2.2.1-5.fc44 Β· BSD-3-Clause
- opensuse-leap 16.0: avr-libc 2.1.0-bp160.1.33 Β· BSD-3-Clause
- π girlified by deepseek-ai/DeepSeek-V4.1-Flash on : a language model's rewrite of the original, under its terms