Reference documentation for deal.II version 9.2.0
\(\newcommand{\dealvcentcolon}{\mathrel{\mathop{:}}}\) \(\newcommand{\dealcoloneq}{\dealvcentcolon\mathrel{\mkern-1.2mu}=}\) \(\newcommand{\jump}[1]{\left[\!\left[ #1 \right]\!\right]}\) \(\newcommand{\average}[1]{\left\{\!\left\{ #1 \right\}\!\right\}}\)
Classes | Namespaces | Macros | Functions | Variables
numbers.h File Reference
#include <deal.II/base/config.h>
#include <deal.II/base/types.h>
#include <cuComplex.h>
#include <cmath>
#include <complex>
#include <cstddef>
#include <type_traits>
#include <deal.II/differentiation/ad/adolc_math.h>
#include <adolc/adouble.h>
#include <Sacado.hpp>

Go to the source code of this file.

Classes

struct  internal::VectorizedArrayWidthSpecifier< Number >
 
struct  internal::VectorizedArrayWidthSpecifier< double >
 
struct  internal::VectorizedArrayWidthSpecifier< float >
 
struct  numbers::is_cuda_compatible< Number, typename >
 
struct  numbers::is_cuda_compatible< std::complex< Number >, void >
 
struct  numbers::NumberTraits< number >
 
struct  numbers::NumberTraits< std::complex< number > >
 
struct  Differentiation::AD::internal::NumberType< T >
 
struct  Differentiation::AD::is_ad_number< NumberType >
 
struct  internal::is_explicitly_convertible< From, To >
 
struct  internal::NumberType< T >
 
struct  internal::NumberType< std::complex< T > >
 
struct  internal::NumberType< cuComplex >
 
struct  internal::NumberType< cuDoubleComplex >
 

Namespaces

 internal
 
 numbers
 
 Differentiation
 
 Differentiation::AD
 
 Differentiation::AD::internal
 

Macros

#define DEAL_II_CUDA_HOST_DEV   __host__ __device__
 

Functions

template<typename Number , std::size_t width>
::VectorizedArray< Number, width > std::sqrt (const ::VectorizedArray< Number, width > &)
 
template<typename Number , std::size_t width>
::VectorizedArray< Number, width > std::abs (const ::VectorizedArray< Number, width > &)
 
template<typename Number , std::size_t width>
::VectorizedArray< Number, width > std::max (const ::VectorizedArray< Number, width > &, const ::VectorizedArray< Number, width > &)
 
template<typename Number , std::size_t width>
::VectorizedArray< Number, width > std::min (const ::VectorizedArray< Number, width > &, const ::VectorizedArray< Number, width > &)
 
template<typename Number , size_t width>
::VectorizedArray< Number, width > std::pow (const ::VectorizedArray< Number, width > &, const Number p)
 
template<typename Number , size_t width>
::VectorizedArray< Number, width > std::sin (const ::VectorizedArray< Number, width > &)
 
template<typename Number , size_t width>
::VectorizedArray< Number, width > std::cos (const ::VectorizedArray< Number, width > &)
 
template<typename Number , size_t width>
::VectorizedArray< Number, width > std::tan (const ::VectorizedArray< Number, width > &)
 
template<typename Number , size_t width>
::VectorizedArray< Number, width > std::exp (const ::VectorizedArray< Number, width > &)
 
template<typename Number , size_t width>
::VectorizedArray< Number, width > std::log (const ::VectorizedArray< Number, width > &)
 
bool numbers::is_finite (const double x)
 
bool numbers::is_finite (const std::complex< double > &x)
 
bool numbers::is_finite (const std::complex< float > &x)
 
bool numbers::is_finite (const std::complex< long double > &x)
 
template<typename Number1 , typename Number2 >
constexpr bool numbers::values_are_equal (const Number1 &value_1, const Number2 &value_2)
 
template<typename Number1 , typename Number2 >
bool numbers::values_are_not_equal (const Number1 &value_1, const Number2 &value_2)
 
template<typename Number >
constexpr bool numbers::value_is_zero (const Number &value)
 
template<typename Number1 , typename Number2 >
bool numbers::value_is_less_than (const Number1 &value_1, const Number2 &value_2)
 
template<typename Number1 , typename Number2 >
bool numbers::value_is_less_than_or_equal_to (const Number1 &value_1, const Number2 &value_2)
 
template<typename Number1 , typename Number2 >
bool numbers::value_is_greater_than (const Number1 &value_1, const Number2 &value_2)
 
template<typename Number1 , typename Number2 >
bool numbers::value_is_greater_than_or_equal_to (const Number1 &value_1, const Number2 &value_2)
 
bool numbers::is_nan (const double x)
 
bool numbers::values_are_equal (const adouble &value_1, const adouble &value_2)
 
template<typename Number >
bool numbers::values_are_equal (const adouble &value_1, const Number &value_2)
 
template<typename Number >
bool numbers::values_are_equal (const Number &value_1, const adouble &value_2)
 
bool numbers::value_is_less_than (const adouble &value_1, const adouble &value_2)
 
template<typename Number >
bool numbers::value_is_less_than (const adouble &value_1, const Number &value_2)
 
template<typename Number >
bool numbers::value_is_less_than (const Number &value_1, const adouble &value_2)
 

Variables

static constexpr double numbers::E = 2.7182818284590452354
 
static constexpr double numbers::LOG2E = 1.4426950408889634074
 
static constexpr double numbers::LOG10E = 0.43429448190325182765
 
static constexpr double numbers::LN2 = 0.69314718055994530942
 
static constexpr double numbers::LN10 = 2.30258509299404568402
 
static constexpr double numbers::PI = 3.14159265358979323846
 
static constexpr double numbers::PI_2 = 1.57079632679489661923
 
static constexpr double numbers::PI_4 = 0.78539816339744830962
 
static constexpr double numbers::SQRT2 = 1.41421356237309504880
 
static constexpr double numbers::SQRT1_2 = 0.70710678118654752440
 

Macro Definition Documentation

◆ DEAL_II_CUDA_HOST_DEV

#define DEAL_II_CUDA_HOST_DEV   __host__ __device__

Definition at line 34 of file numbers.h.

Function Documentation

◆ sqrt()

template<typename Number , std::size_t width>
::VectorizedArray<Number, width> std::sqrt ( const ::VectorizedArray< Number, width > &  x)

Compute the square root of a vectorized data field. The result is returned as vectorized array in the form {sqrt(x[0]), sqrt(x[1]), ..., sqrt(x[size()-1])}.

Definition at line 5412 of file vectorization.h.

◆ abs()

template<typename Number , std::size_t width>
::VectorizedArray<Number, width> std::abs ( const ::VectorizedArray< Number, width > &  x)

Compute the absolute value (modulus) of a vectorized data field. The result is returned as vectorized array in the form {abs(x[0]), abs(x[1]), ..., abs(x[size()-1])}.

Definition at line 5450 of file vectorization.h.

◆ max()

template<typename Number , std::size_t width>
::VectorizedArray<Number, width> std::max ( const ::VectorizedArray< Number, width > &  x,
const ::VectorizedArray< Number, width > &  y 
)

Compute the componentwise maximum of two vectorized data fields. The result is returned as vectorized array in the form {max(x[0],y[0]), max(x[1],y[1]), ...}.

Definition at line 5466 of file vectorization.h.

◆ min()

template<typename Number , std::size_t width>
::VectorizedArray<Number, width> std::min ( const ::VectorizedArray< Number, width > &  x,
const ::VectorizedArray< Number, width > &  y 
)

Compute the componentwise minimum of two vectorized data fields. The result is returned as vectorized array in the form {min(x[0],y[0]), min(x[1],y[1]), ...}.

Definition at line 5483 of file vectorization.h.

◆ pow()

template<typename Number , size_t width>
::VectorizedArray<Number, width> std::pow ( const ::VectorizedArray< Number, width > &  x,
const Number  p 
)

Raises the given number x to the power p for a vectorized data field. The result is returned as vectorized array in the form {pow(x[0],p), pow(x[1],p), ..., pow(x[size()-1],p)}.

Definition at line 5428 of file vectorization.h.

◆ sin()

template<typename Number , size_t width>
::VectorizedArray<Number, width> std::sin ( const ::VectorizedArray< Number, width > &  x)

Compute the sine of a vectorized data field. The result is returned as vectorized array in the form {sin(x[0]), sin(x[1]), ..., sin(x[VectorizedArray::size()-1])}.

Definition at line 5297 of file vectorization.h.

◆ cos()

template<typename Number , size_t width>
::VectorizedArray<Number, width> std::cos ( const ::VectorizedArray< Number, width > &  x)

Compute the cosine of a vectorized data field. The result is returned as vectorized array in the form {cos(x[0]), cos(x[1]), ..., cos(x[size()-1])}.

Definition at line 5324 of file vectorization.h.

◆ tan()

template<typename Number , size_t width>
::VectorizedArray<Number, width> std::tan ( const ::VectorizedArray< Number, width > &  x)

Compute the tangent of a vectorized data field. The result is returned as vectorized array in the form {tan(x[0]), tan(x[1]), ..., tan(x[size()-1])}.

Definition at line 5346 of file vectorization.h.

◆ exp()

template<typename Number , size_t width>
::VectorizedArray<Number, width> std::exp ( const ::VectorizedArray< Number, width > &  x)

Compute the exponential of a vectorized data field. The result is returned as vectorized array in the form {exp(x[0]), exp(x[1]), ..., exp(x[size()-1])}.

Definition at line 5368 of file vectorization.h.

◆ log()

template<typename Number , size_t width>
::VectorizedArray<Number, width> std::log ( const ::VectorizedArray< Number, width > &  x)

Compute the natural logarithm of a vectorized data field. The result is returned as vectorized array in the form {log(x[0]), log(x[1]), ..., log(x[size()-1])}.

Definition at line 5390 of file vectorization.h.