Stan Math Library
2.8.0
reverse mode automatic differentiation
Main Page
Modules
Namespaces
Classes
Files
File List
File Members
All
Classes
Namespaces
Files
Functions
Variables
Typedefs
Enumerator
Friends
Macros
Groups
stan
math
prim
scal
fun
corr_free.hpp
Go to the documentation of this file.
1
#ifndef STAN_MATH_PRIM_SCAL_FUN_CORR_FREE_HPP
2
#define STAN_MATH_PRIM_SCAL_FUN_CORR_FREE_HPP
3
4
#include <
stan/math/prim/scal/err/check_bounded.hpp
>
5
#include <cmath>
6
7
namespace
stan {
8
9
namespace
math {
10
27
template
<
typename
T>
28
inline
29
T
corr_free
(
const
T y) {
30
stan::math::check_bounded<T, double, double>
31
(
"stan::math::lub_free"
,
32
"Correlation variable"
, y, -1, 1);
33
return
atanh
(y);
34
}
35
36
}
37
38
}
39
40
#endif
stan::math::atanh
fvar< T > atanh(const fvar< T > &x)
Definition:
atanh.hpp:13
stan::math::corr_free
T corr_free(const T y)
Return the unconstrained scalar that when transformed to a valid correlation produces the specified v...
Definition:
corr_free.hpp:29
check_bounded.hpp
[
Stan Home Page
]
© 2011–2015, Stan Development Team.