3 #include "EigenMatrixTypedefs.h"
8 template <
unsigned int rows,
unsigned int cols>
9 Eigen::Matrix<double, rows, cols> RKMatrixToEigenMatrix(
const RKMatrix<rows, cols>& rkMatrix) {
10 Eigen::Matrix<double, rows, cols> eigenMatrix;
12 for (
unsigned int row=0; row < rows; ++row) {
13 for (
unsigned int col=0; col < cols; ++col) {
14 eigenMatrix(row, col) = rkMatrix[cols*row + col];
22 template <
unsigned int rows,
unsigned int cols>
23 RKMatrix<rows, cols> eigenMatrixToRKMatrix(
const Eigen::Matrix<double, rows, cols>& eigenMatrix) {
24 RKMatrix<rows, cols> rkMatrix;
26 for (
unsigned int row=0; row < rows; ++row) {
27 for (
unsigned int col=0; col < cols; ++col) {
28 rkMatrix(row, col) = eigenMatrix(row, col);