cmath File Reference

Go to the source code of this file.

## Namespaces

namespace | std

## Macros

#define | __cpp_lib_hypot
#define | __cpp_lib_interpolate
#define | _GLIBCXX_CMATH
#define | _GLIBCXX_INCLUDE_NEXT_C_HEADERS

## Functions

template<typename _Tp>
_Tp | std::__hypot3 (_Tp __x, _Tp __y, _Tp __z)
template<typename _Fp>
constexpr _Fp | std::__lerp (_Fp __a, _Fp __b, _Fp __t) noexcept
template<typename _Tp>
constexpr __gnu_cxx::__enable_if< __is_integer< _Tp >::__value, double >::__type | std::acos (_Tp __x)
constexpr float | std::acos (float __x)
constexpr long double | std::acos (long double __x)
template<typename _Tp, typename _Abi, typename..., typename _R = _Math_return_type_t< decltype(std::acos(declval<double>())), _Tp, _Abi>>
_GLIBCXX_SIMD_ALWAYS_INLINE enable_if_t< is_floating_point_v< _Tp >, _R > | std::acos (simd< _Tp, _Abi > __x)
template<typename _Tp>
constexpr __gnu_cxx::__enable_if< __is_integer< _Tp >::__value, double >::__type | std::asin (_Tp __x)
constexpr float | std::asin (float __x)
constexpr long double | std::asin (long double __x)
template<typename _Tp, typename _Abi, typename..., typename _R = _Math_return_type_t< decltype(std::asin(declval<double>())), _Tp, _Abi>>
_GLIBCXX_SIMD_ALWAYS_INLINE enable_if_t< is_floating_point_v< _Tp >, _R > | std::asin (simd< _Tp, _Abi > __x)
template<typename _Tp>
constexpr __gnu_cxx::__enable_if< __is_integer< _Tp >::__value, double >::__type | std::atan (_Tp __x)
constexpr float | std::atan (float __x)
constexpr long double | std::atan (long double __x)
template<typename _Tp, typename _Abi, typename..., typename _R = _Math_return_type_t< decltype(std::atan(declval<double>())), _Tp, _Abi>>
_GLIBCXX_SIMD_ALWAYS_INLINE enable_if_t< is_floating_point_v< _Tp >, _R > | std::atan (simd< _Tp, _Abi > __x)
template<typename _Tp, typename _Up>
constexpr __gnu_cxx::__promote_2< _Tp, _Up >::__type | std::atan2 (_Tp __y, _Up __x)
template<typename _Tp, typename _Abi, typename..., typename _Arg2 = _Extra_argument_type<_Tp, _Tp, _Abi>, typename _R = _Math_return_type_t< decltype(std::atan2(declval<double>(), _Arg2::declval())), _Tp, _Abi>>
_GLIBCXX_SIMD_ALWAYS_INLINE enable_if_t< is_floating_point_v< _Tp >, _R > | std::atan2 (const simd< _Tp, _Abi > &__x, const typename _Arg2::type &__y)
constexpr float | std::atan2 (float __y, float __x)
constexpr long double | std::atan2 (long double __y, long double __x)
template<typename _Tp>
constexpr __gnu_cxx::__enable_if< __is_integer< _Tp >::__value, double >::__type | std::ceil (_Tp __x)
constexpr float | std::ceil (float __x)
constexpr long double | std::ceil (long double __x)
template<typename _Tp, typename _Abi, typename..., typename _R = _Math_return_type_t< decltype(std::ceil(declval<double>())), _Tp, _Abi>>
_GLIBCXX_SIMD_ALWAYS_INLINE enable_if_t< is_floating_point_v< _Tp >, _R > | std::ceil (simd< _Tp, _Abi > __x)
template<typename _Tp>
constexpr __gnu_cxx::__enable_if< __is_integer< _Tp >::__value, double >::__type | std::cos (_Tp __x)
template<typename _Tp, typename _Abi, typename = __detail::__odr_helper>
enable_if_t< is_floating_point_v< _Tp >, simd< _Tp, _Abi > > | std::cos (const simd< _Tp, _Abi > &__x)
constexpr float | std::cos (float __x)
constexpr long double | std::cos (long double __x)
template<typename _Tp>
constexpr __gnu_cxx::__enable_if< __is_integer< _Tp >::__value, double >::__type | std::cosh (_Tp __x)
constexpr float | std::cosh (float __x)
constexpr long double | std::cosh (long double __x)
template<typename _Tp, typename _Abi, typename..., typename _R = _Math_return_type_t< decltype(std::cosh(declval<double>())), _Tp, _Abi>>
_GLIBCXX_SIMD_ALWAYS_INLINE enable_if_t< is_floating_point_v< _Tp >, _R > | std::cosh (simd< _Tp, _Abi > __x)
template<typename _Tp>
constexpr __gnu_cxx::__enable_if< __is_integer< _Tp >::__value, double >::__type | std::exp (_Tp __x)
constexpr float | std::exp (float __x)
constexpr long double | std::exp (long double __x)
template<typename _Tp, typename _Abi, typename..., typename _R = _Math_return_type_t< decltype(std::exp(declval<double>())), _Tp, _Abi>>
_GLIBCXX_SIMD_ALWAYS_INLINE enable_if_t< is_floating_point_v< _Tp >, _R > | std::exp (simd< _Tp, _Abi > __x)
template<typename _Tp>
constexpr __gnu_cxx::__enable_if< __is_integer< _Tp >::__value, double >::__type | std::fabs (_Tp __x)
constexpr float | std::fabs (float __x)
constexpr long double | std::fabs (long double __x)
template<typename _Tp, typename _Abi, typename..., typename _R = _Math_return_type_t< decltype(std::fabs(declval<double>())), _Tp, _Abi>>
_GLIBCXX_SIMD_ALWAYS_INLINE enable_if_t< is_floating_point_v< _Tp >, _R > | std::fabs (simd< _Tp, _Abi > __x)
template<typename _Tp>
constexpr __gnu_cxx::__enable_if< __is_integer< _Tp >::__value, double >::__type | std::floor (_Tp __x)
constexpr float | std::floor (float __x)
constexpr long double | std::floor (long double __x)
template<typename _Tp, typename _Abi, typename..., typename _R = _Math_return_type_t< decltype(std::floor(declval<double>())), _Tp, _Abi>>
_GLIBCXX_SIMD_ALWAYS_INLINE enable_if_t< is_floating_point_v< _Tp >, _R > | std::floor (simd< _Tp, _Abi > __x)
template<typename _Tp, typename _Up>
constexpr __gnu_cxx::__promote_2< _Tp, _Up >::__type | std::fmod (_Tp __x, _Up __y)
template<typename _Tp, typename _Abi, typename..., typename _Arg2 = _Extra_argument_type<_Tp, _Tp, _Abi>, typename _R = _Math_return_type_t< decltype(std::fmod(declval<double>(), _Arg2::declval())), _Tp, _Abi>>
_GLIBCXX_SIMD_ALWAYS_INLINE enable_if_t< is_floating_point_v< _Tp >, _R > | std::fmod (const simd< _Tp, _Abi > &__x, const typename _Arg2::type &__y)
constexpr float | std::fmod (float __x, float __y)
constexpr long double | std::fmod (long double __x, long double __y)
template<typename _Tp>
constexpr __gnu_cxx::__enable_if< __is_integer< _Tp >::__value, double >::__type | std::frexp (_Tp __x, int *__exp)
template<typename _Tp, typename _Abi, typename = __detail::__odr_helper>
enable_if_t< is_floating_point_v< _Tp >, simd< _Tp, _Abi > > | std::frexp (const simd< _Tp, _Abi > &__x, _Samesize< int, simd< _Tp, _Abi > > *__exp)
float | std::frexp (float __x, int *__exp)
long double | std::frexp (long double __x, int *__exp)
template<typename _Tp, typename _Up, typename _Vp>
__gnu_cxx::__promote_3< _Tp, _Up, _Vp >::__type | std::hypot (_Tp __x, _Up __y, _Vp __z)
double | std::hypot (double __x, double __y, double __z)
float | std::hypot (float __x, float __y, float __z)
long double | std::hypot (long double __x, long double __y, long double __z)
template<typename _Tp>
constexpr __gnu_cxx::__enable_if< __is_integer< _Tp >::__value, double >::__type | std::ldexp (_Tp __x, int __exp)
template<typename _Tp, typename _Abi, typename..., typename _Arg2 = _Extra_argument_type<int, _Tp, _Abi>, typename _R = _Math_return_type_t< decltype(std::ldexp(declval<double>(), _Arg2::declval())), _Tp, _Abi>>
_GLIBCXX_SIMD_ALWAYS_INLINE enable_if_t< is_floating_point_v< _Tp >, _R > | std::ldexp (const simd< _Tp, _Abi > &__x, const typename _Arg2::type &__y)
constexpr float | std::ldexp (float __x, int __exp)
constexpr long double | std::ldexp (long double __x, int __exp)
template<typename _Tp, typename _Up, typename _Vp>
constexpr __gnu_cxx::__promoted_t< _Tp, _Up, _Vp > | std::lerp (_Tp __x, _Up __y, _Vp __z) noexcept
constexpr double | std::lerp (double __a, double __b, double __t) noexcept
constexpr float | std::lerp (float __a, float __b, float __t) noexcept
constexpr long double | std::lerp (long double __a, long double __b, long double __t) noexcept
template<typename _Tp>
constexpr __gnu_cxx::__enable_if< __is_integer< _Tp >::__value, double >::__type | std::log (_Tp __x)
constexpr float | std::log (float __x)
constexpr long double | std::log (long double __x)
template<typename _Tp, typename _Abi, typename..., typename _R = _Math_return_type_t< decltype(std::log(declval<double>())), _Tp, _Abi>>
_GLIBCXX_SIMD_ALWAYS_INLINE enable_if_t< is_floating_point_v< _Tp >, _R > | std::log (simd< _Tp, _Abi > __x)
template<typename _Tp>
constexpr __gnu_cxx::__enable_if< __is_integer< _Tp >::__value, double >::__type | std::log10 (_Tp __x)
constexpr float | std::log10 (float __x)
constexpr long double | std::log10 (long double __x)
template<typename _Tp, typename _Abi, typename..., typename _R = _Math_return_type_t< decltype(std::log10(declval<double>())), _Tp, _Abi>>
_GLIBCXX_SIMD_ALWAYS_INLINE enable_if_t< is_floating_point_v< _Tp >, _R > | std::log10 (simd< _Tp, _Abi > __x)
template<typename _Tp, typename _Abi, typename = __detail::__odr_helper>
enable_if_t< is_floating_point_v< _Tp >, simd< _Tp, _Abi > > | std::modf (const simd< _Tp, _Abi > &__x, simd< _Tp, _Abi > *__iptr)
float | std::modf (float __x, float *__iptr)
long double | std::modf (long double __x, long double *__iptr)
template<typename _Tp, typename _Up>
constexpr __gnu_cxx::__promote_2< _Tp, _Up >::__type | std::pow (_Tp __x, _Up __y)
template<typename _Tp, typename _Abi, typename..., typename _Arg2 = _Extra_argument_type<_Tp, _Tp, _Abi>, typename _R = _Math_return_type_t< decltype(std::pow(declval<double>(), _Arg2::declval())), _Tp, _Abi>>
_GLIBCXX_SIMD_ALWAYS_INLINE enable_if_t< is_floating_point_v< _Tp >, _R > | std::pow (const simd< _Tp, _Abi > &__x, const typename _Arg2::type &__y)
constexpr float | std::pow (float __x, float __y)
constexpr long double | std::pow (long double __x, long double __y)
template<typename _Tp>
constexpr __gnu_cxx::__enable_if< __is_integer< _Tp >::__value, double >::__type | std::sin (_Tp __x)
template<typename _Tp, typename _Abi, typename = __detail::__odr_helper>
enable_if_t< is_floating_point_v< _Tp >, simd< _Tp, _Abi > > | std::sin (const simd< _Tp, _Abi > &__x)
constexpr float | std::sin (float __x)
constexpr long double | std::sin (long double __x)
template<typename _Tp>
constexpr __gnu_cxx::__enable_if< __is_integer< _Tp >::__value, double >::__type | std::sinh (_Tp __x)
constexpr float | std::sinh (float __x)
constexpr long double | std::sinh (long double __x)
template<typename _Tp, typename _Abi, typename..., typename _R = _Math_return_type_t< decltype(std::sinh(declval<double>())), _Tp, _Abi>>
_GLIBCXX_SIMD_ALWAYS_INLINE enable_if_t< is_floating_point_v< _Tp >, _R > | std::sinh (simd< _Tp, _Abi > __x)
template<typename _Tp>
constexpr __gnu_cxx::__enable_if< __is_integer< _Tp >::__value, double >::__type | std::sqrt (_Tp __x)
constexpr float | std::sqrt (float __x)
constexpr long double | std::sqrt (long double __x)
template<typename _Tp, typename _Abi, typename..., typename _R = _Math_return_type_t< decltype(std::sqrt(declval<double>())), _Tp, _Abi>>
_GLIBCXX_SIMD_ALWAYS_INLINE enable_if_t< is_floating_point_v< _Tp >, _R > | std::sqrt (simd< _Tp, _Abi > __x)
template<typename _Tp>
constexpr __gnu_cxx::__enable_if< __is_integer< _Tp >::__value, double >::__type | std::tan (_Tp __x)
constexpr float | std::tan (float __x)
constexpr long double | std::tan (long double __x)
template<typename _Tp, typename _Abi, typename..., typename _R = _Math_return_type_t< decltype(std::tan(declval<double>())), _Tp, _Abi>>
_GLIBCXX_SIMD_ALWAYS_INLINE enable_if_t< is_floating_point_v< _Tp >, _R > | std::tan (simd< _Tp, _Abi > __x)
template<typename _Tp>
constexpr __gnu_cxx::__enable_if< __is_integer< _Tp >::__value, double >::__type | std::tanh (_Tp __x)
constexpr float | std::tanh (float __x)
constexpr long double | std::tanh (long double __x)
template<typename _Tp, typename _Abi, typename..., typename _R = _Math_return_type_t< decltype(std::tanh(declval<double>())), _Tp, _Abi>>
_GLIBCXX_SIMD_ALWAYS_INLINE enable_if_t< is_floating_point_v< _Tp >, _R > | std::tanh (simd< _Tp, _Abi > __x)

## Detailed Description

This is a Standard C++ Library file. You should `#include` this file in your programs, rather than any of the *.h implementation files.

This is the C++ version of the Standard C Library header `math.h`, and its contents are (mostly) the same as that header, but are all contained in the namespace `std` (except for names which are defined as macros in C).

Definition in file cmath.

## Macro Definition Documentation

## __cpp_lib_hypot

#define __cpp_lib_hypot

Definition at line 3556 of file cmath.

## __cpp_lib_interpolate

#define __cpp_lib_interpolate

Definition at line 3629 of file cmath.

## _GLIBCXX_CMATH

#define _GLIBCXX_CMATH

Definition at line 52 of file cmath.

## _GLIBCXX_INCLUDE_NEXT_C_HEADERS

#define _GLIBCXX_INCLUDE_NEXT_C_HEADERS

Definition at line 46 of file cmath.