Add assert for edge case if Thin U Requested at runtime
Reference issue
Discussion in !862 (merged)
(Ignore the stuff about changing workspace sizes. That's not necessary since this case doesn't work anyway.)
What does this implement/fix?
There's an old issue when requesting thin unitaries at runtime:
#include <Eigen/Dense>
int main() {
using namespace Eigen;
using MT = Matrix<double, 5, Dynamic>;
MT m = MT::Random(5, 4); // fixed rows > dynamic cols
// fails to resize stuff because U is 5x5 at compile-time, but needs to be 5x4.
BDCSVD<MT> svd1(m, ComputeThinU | ComputeThinV);
}
I don't think this can be "fixed," so this adds an assert for this case and updates tests to look for the assert.
This shouldn't change any behavior, basically just a fix for the tests and to improve the failure message.