|
dune-common 2.11
|
Loading...
Searching...
No Matches
math.hh
Go to the documentation of this file.
3// SPDX-FileCopyrightInfo: Copyright © DUNE Project contributors, see file LICENSE.md in module root
95 static_assert(std::numeric_limits<T>::is_integer, "`factorial(n)` has to be called with an integer type.");
115 static_assert(std::numeric_limits<T>::is_integer, "`binomial(n, k)` has to be called with an integer type.");
131 constexpr inline static auto binomial (std::integral_constant<T, n>, std::integral_constant<T, k>) noexcept
137 constexpr inline static auto binomial (std::integral_constant<T, n>, std::integral_constant<T, n>) noexcept
Utilities for type computations, constraining overloads, ...
#define DUNE_COMMON_MATH_ISFUNCTION_FUNCTOR(function)
Definition math.hh:251
#define DUNE_COMMON_MATH_ISFUNCTION(function, stdfunction)
Definition math.hh:214
static constexpr T binomial(const T &n, const T &k) noexcept
calculate the binomial coefficient n over k as a constexpr
Definition math.hh:113
constexpr Base power(Base m, Exponent p)
Power method for integer exponents.
Definition math.hh:75
static constexpr T factorial(const T &n) noexcept
calculate the factorial of n as a constexpr
Definition math.hh:93
constexpr K conjugateComplex(const K &x)
compute conjugate complex of x
Definition math.hh:146
bool isNaN(const FieldVector< K, SIZE > &b, PriorityTag< 2 >, ADLTag)
Returns whether any entry is NaN.
Definition fvector.hh:458
bool isInf(const FieldVector< K, SIZE > &b, PriorityTag< 2 >, ADLTag)
Returns whether any entry is infinite.
Definition fvector.hh:446
auto isFinite(const FieldVector< K, SIZE > &b, PriorityTag< 2 >, ADLTag)
Returns whether all entries are finite.
Definition fvector.hh:435
bool isUnordered(const FieldVector< K, 1 > &b, const FieldVector< K, 1 > &c, PriorityTag< 2 >, ADLTag)
Returns true if either b or c is NaN.
Definition fvector.hh:470
Standard implementation of MathematicalConstants.
Definition math.hh:34
static const T pi()
Archimedes' constant.
Definition math.hh:48
Tag to make sure the functions in this namespace can be found by ADL.
Definition math.hh:212
T acos(T... args)
T exp(T... args)
T imag(T... args)
T isunordered(T... args)
T real(T... args)
Legal Statements / Impressum | Hosted by TU Dresden & Uni Heidelberg | Generated by
1.9.8