Good to to hear that. I've filed an issue to figure out how to make this more consistent
https://github.com/JuliaLang/julia/issues/10520 2015-03-14 21:06 GMT-04:00 Kristoffer Carlsson <[email protected]>: > > > On Sunday, March 15, 2015 at 1:02:11 AM UTC+1, Andreas Noack wrote: >> >> You can get around this by specifying that the matrix is symmetric. This >> can be done with >> >> cholfact(Symmetric(A, :L)) >> > > Thank you, just what I was looking for. > >> >> which then bypasses the test for symmetry and cholfact only looks at the >> lower triangle. >> >> However, the error you got is not consistent with the way cholfact works >> for dense matrices, so it might be worth changing the behavior of either >> dense or sparse cholfact. Dense cholfact doesn't check for symmetry. >> >> 2015-03-14 17:37 GMT-04:00 Kristoffer Carlsson <[email protected]>: >> >>> From my Finite Element code I generate a global stiffness matrix K. >>> >>> However, I can not use the cholesky factorization on it because of >>> >>> ERROR: ArgumentError: sparse matrix is not symmetric/Hermitian >>> in cholfact at sparse/cholmod.jl:916 >>> in cholfact at sparse/cholmod.jl:991 >>> >>> However, I am pretty sure it is symmetric and positive definite. >>> >>> For example: >>> julia> issym(K) >>> false >>> >>> julia> maximum(abs(K - K')) >>> 4.440892098500626e-16 >>> >>> Matlab for example has no problem running chol on it when I copy + paste >>> it. >>> >>> This works (of course): >>> julia> cholfact((K + K')/2) >>> >>> Are the tolerances for the Hermitian check set too small or is there >>> maybe a specific symmetric sparse type I should use when I know my matrix >>> will be symm + pos def? >>> >>> Best regards, >>> Kristoffer Carlsson >>> >> >>
