sigma  1.0.0
Loading...
Searching...
No Matches
hyperbolic.ipp
1#pragma once
3#include <cmath>
4
5namespace sigma {
6
7template<typename T>
9 T mean = std::sinh(a.mean());
10 T dcda = std::cosh(a.mean());
11 return detail_::unary_result(a, mean, dcda);
12}
13
14template<typename T>
16 T mean = std::cosh(a.mean());
17 T dcda = std::sinh(a.mean());
18 return detail_::unary_result(a, mean, dcda);
19}
20
21template<typename T>
23 T mean = std::tanh(a.mean());
24 T dcda = 1.0 - std::pow(std::tanh(a.mean()), 2.0);
25 return detail_::unary_result(a, mean, dcda);
26}
27
28template<typename T>
30 T mean = std::asinh(a.mean());
31 T dcda = 1.0 / std::sqrt(1 + std::pow(a.mean(), 2.0));
32 return detail_::unary_result(a, mean, dcda);
33}
34
35template<typename T>
37 T mean = std::acosh(a.mean());
38 T dcda = 1.0 / std::sqrt(std::pow(a.mean(), 2.0) - 1.0);
39 return detail_::unary_result(a, mean, dcda);
40}
41
42template<typename T>
44 T mean = std::atanh(a.mean());
45 T dcda = 1.0 / (1.0 - std::pow(a.mean(), 2.0));
46 return detail_::unary_result(a, mean, dcda);
47}
48
49} // namespace sigma
Models an unceratin variable.
Definition uncertain.hpp:34
value_t mean() const
Get the mean value of the variable.
Definition uncertain.hpp:71
Uncertain< T > unary_result(const Uncertain< T > &a, T mean, T dcda)
Generalized Unary Changes.
Definition operation_common.hpp:43
The primary namespace for the sigma library.
Definition affine.hpp:12
GeneralInterval< T > atanh(const GeneralInterval< T > &a)
Calculate the inverse hyperbolic tangent of a general interval.
Definition hyperbolic.ipp:75
GeneralInterval< T > tanh(const GeneralInterval< T > &a)
Calculate the hyperbolic tangent of a general interval.
Definition hyperbolic.ipp:45
GeneralInterval< T > cosh(const GeneralInterval< T > &a)
Calculate the hyperbolic cosine of a general interval.
Definition hyperbolic.ipp:17
GeneralInterval< T > acosh(const GeneralInterval< T > &a)
Calculate the inverse hyperbolic cosine of a general interval.
Definition hyperbolic.ipp:61
GeneralInterval< T > asinh(const GeneralInterval< T > &a)
Calculate the inverse hyperbolic sine of a general interval.
Definition hyperbolic.ipp:53
GeneralInterval< T > sinh(const GeneralInterval< T > &a)
Calculate the hyperbolic sine of a general interval.
Definition hyperbolic.ipp:9
Common implementation details for operations.