1#ifndef STAN_MATH_PRIM_FUN_ACOSH_HPP
2#define STAN_MATH_PRIM_FUN_ACOSH_HPP
26template <
typename T, require_arithmetic_t<T>* =
nullptr>
48template <
typename T, require_complex_bt<std::is_arithmetic, T>* =
nullptr>
65 static inline auto fun(
const T& x) {
80template <
typename T, require_ad_container_t<T>* =
nullptr>
95template <
typename Container,
97inline auto acosh(
const Container& x) {
113 auto y =
log(z +
sqrt(z * z - 1));
require_t< container_type_check_base< is_container, base_type_t, TypeCheck, Check... > > require_container_bt
Require type satisfies is_container.
double copysign(double a, double_d b)
std::complex< V > complex_acosh(const std::complex< V > &z)
Return the hyperbolic arc cosine of the complex argument.
double value_of_rec(const fvar< T > &v)
Return the value of the specified variable.
fvar< T > acosh(const fvar< T > &x)
bool is_nan(T &&x)
Returns 1 if the input's value is NaN and 0 otherwise.
fvar< T > log(const fvar< T > &x)
void check_greater_or_equal(const char *function, const char *name, const T_y &y, const T_low &low, Idxs... idxs)
Throw an exception if y is not greater or equal than low.
fvar< T > sqrt(const fvar< T > &x)
int is_inf(const fvar< T > &x)
Returns 1 if the input's value is infinite and 0 otherwise.
The lgamma implementation in stan-math is based on either the reentrant safe lgamma_r implementation ...
static auto fun(const T &x)
Return the inverse hyperbolic cosine of the specified argument.
Structure to wrap acosh() so it can be vectorized.
Base template class for vectorization of unary scalar functions defined by a template class F to a sc...