Try this:
Eigen::MatrixXd d; // Matrix of doubles.
Eigen::MatrixXf f = d.cast <float> (); // Matrix of floats.
Try this:
Eigen::MatrixXd d; // Matrix of doubles.
Eigen::MatrixXf f = d.cast <float> (); // Matrix of floats.