Automatic Differentiation
 
Loading...
Searching...
No Matches

◆ col_mapN()

template<typename F , typename Tuple , typename... Args, require_tuple_t< Tuple > * = nullptr>
auto stan::math::col_mapN ( F &&  f,
Tuple &&  ms,
Args &&...  args 
)
inline

Return a matrix whose j-th column is f(get<0>(ms).col(j), get<1>(ms).col(j), ..., args...).

The tuple ms must contain at least two Eigen matrices with identical dimensions. Additional trailing arguments are shared across calls. If the inputs have zero columns, or if the first returned column is empty, returns a 0x0 matrix. All returned columns must have the same number of rows.

Template Parameters
Ftype of functor
Tupletype of tuple of Eigen matrix inputs
Argstypes of shared arguments
Parameters
[in]ffunctor applied to each tuple of columns
[in]mstuple of Eigen matrix inputs
[in]argsshared arguments passed to each call
Returns
matrix of results
Exceptions
std::invalid_argumentif the inputs have different dimensions or returned columns have inconsistent sizes

Definition at line 266 of file map.hpp.