huttered40 / capital

Distributed-memory implementations of novel Cholesky and QR matrix factorizations
BSD 2-Clause "Simplified" License
2 stars 1 forks source link

Repair diagonal inversion #26

Closed huttered40 closed 4 years ago

huttered40 commented 4 years ago

After new changes to reduce the number of intermediate matrix allocations and serializations, the diagonal inversion no longer functions correctly. This is mainly because I do not want to support two more invoke methods in summa.

I don't need this functionality currently, but it should probably be repaired at some point.

huttered40 commented 4 years ago

See if this can be repaired when I add pointer interfaces to summa.

huttered40 commented 4 years ago

Diagonal inversion will not be expected if user passes in a pointer.

huttered40 commented 4 years ago

Ok, I have this in a state in which it does not crash, but it does attain a nan or inf residual.

However for non-power-of-2 matrices, I get an error: what(): std::bad_array_new_length terminate called after throwing an instance of 'std::bad_array_new_length'

mpiexec -np 64 ./bin/cholinv 289 1 1 0 0 1 2
huttered40 commented 4 years ago

I looked over the code, and although there were no obvious errors, one thing I think could be the issue is that we pass into solve a reference to a matrix, and then possibly overwrite it via the same table.

huttered40 commented 4 years ago

Fixed.