Does anyone know a good way how i can extract blocks from an Eigen::VectorXf that can be interpreted as a specific Eigen::MatrixXf without copying data? (the vector should c
If you want to reinterpret a subvector as a matrix then yes, you have to use Map:
Map A(W.data()); // using the first 4 elements
Map B(W.tail(4).data()); // using the last 4 elements
Map C(W.data()+6, 2,2); // using the 6th to 10th elements
// with sizes defined at runtime.