Commit 49bb4f10 authored by Praetorius, Simon's avatar Praetorius, Simon

vector operations

parent 1ed23fa5
......@@ -93,6 +93,14 @@ namespace vector_operations {
size_t num_rows(const std::vector<T> &v) {
return static_cast<size_t>(v.size());
};
template<typename T>
size_t num_rows(T &v) {
return 1;
};
template<typename T>
size_t num_rows(const T &v) {
return 1;
};
// num_rows/num_cols for matrix types
template<typename T>
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment