Stan Math Library  2.20.0
reverse mode automatic differentiation
check_square.hpp
Go to the documentation of this file.
1 #ifndef STAN_MATH_OPENCL_ERR_CHECK_SQUARE_HPP
2 #define STAN_MATH_OPENCL_ERR_CHECK_SQUARE_HPP
3 #ifdef STAN_OPENCL
6 
7 namespace stan {
8 namespace math {
19 inline void check_square(const char* function, const char* name,
20  const matrix_cl& y) {
21  check_size_match(function, "Expecting a square matrix; rows of ", name,
22  y.rows(), "columns of ", name, y.cols());
23 }
24 
25 } // namespace math
26 } // namespace stan
27 #endif
28 #endif
void check_square(const char *function, const char *name, const matrix_cl &y)
Check if the matrix_cl is square.
The matrix_cl class - allocates memory space on the OpenCL device, functions for transfering matrices...
void check_size_match(const char *function, const char *name_i, T_size1 i, const char *name_j, T_size2 j)
Check if the provided sizes match.
Represents a matrix on the OpenCL device.
Definition: matrix_cl.hpp:29

     [ Stan Home Page ] © 2011–2018, Stan Development Team.