@@ -81,27 +81,31 @@ struct inv_logit_fun {
8181 * @return Inverse logit applied to each value in x.
8282 */
8383template <typename Container, require_ad_container_t <Container>* = nullptr ,
84- require_all_not_nonscalar_prim_or_rev_kernel_expression_t <Container>* = nullptr ,
85- require_not_rev_matrix_t <Container>* = nullptr >
84+ require_all_not_nonscalar_prim_or_rev_kernel_expression_t <
85+ Container>* = nullptr ,
86+ require_not_rev_matrix_t <Container>* = nullptr >
8687inline auto inv_logit (Container&& x) {
87- return apply_scalar_unary<inv_logit_fun, Container>::apply (std::forward<Container>(x));
88+ return apply_scalar_unary<inv_logit_fun, Container>::apply (
89+ std::forward<Container>(x));
8890}
8991
9092/* *
9193 * Vectorized version of inv_logit() for Eigen types.
9294 *
93- * @tparam T A type of either `std::vector` whose inner type inherits from `Eigen::DenseBase` or a
94- * type that directly inherits from `Eigen::DenseBase`. The inner scalar type must not have a
95- * `var` scalar type.
95+ * @tparam T A type of either `std::vector` whose inner type inherits from
96+ * `Eigen::DenseBase` or a type that directly inherits from `Eigen::DenseBase`.
97+ * The inner scalar type must not have a `var` scalar type.
9698 * @param x Eigen expression
9799 * @return Inverse logit applied to each value in x.
98100 */
99101template <typename Container,
100102 require_container_bt<std::is_arithmetic, Container>* = nullptr ,
101- require_all_not_nonscalar_prim_or_rev_kernel_expression_t <Container>* = nullptr >
103+ require_all_not_nonscalar_prim_or_rev_kernel_expression_t <
104+ Container>* = nullptr >
102105inline auto inv_logit (Container&& x) {
103106 return apply_vector_unary<Container>::apply (
104- std::forward<Container>(x), [](const auto & v) { return v.array ().logistic (); });
107+ std::forward<Container>(x),
108+ [](const auto & v) { return v.array ().logistic (); });
105109}
106110} // namespace math
107111} // namespace stan
0 commit comments