mirror of
https://gitlab.com/libeigen/eigen.git
synced 2025-08-12 03:39:01 +08:00
Bug fix in MatrixExponential.h
Initialize matrices for intermediate results to correct dimension
This commit is contained in:
parent
6e4e94ff32
commit
32f95ec267
@ -292,7 +292,10 @@ namespace MatrixExponentialInternal {
|
||||
template <typename MatrixType>
|
||||
void compute(const MatrixType &M, MatrixType* result)
|
||||
{
|
||||
MatrixType num, den, U, V;
|
||||
MatrixType num(M.rows(), M.cols());
|
||||
MatrixType den(M.rows(), M.cols());
|
||||
MatrixType U(M.rows(), M.cols());
|
||||
MatrixType V(M.rows(), M.cols());
|
||||
MatrixType Id = MatrixType::Identity(M.rows(), M.cols());
|
||||
float l1norm = static_cast<float>(M.cwise().abs().colwise().sum().maxCoeff());
|
||||
int squarings;
|
||||
|
Loading…
x
Reference in New Issue
Block a user