Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

CSC interface for the SPD solver #24

Open
PetrKryslUCSD opened this issue Mar 28, 2023 · 3 comments
Open

CSC interface for the SPD solver #24

PetrKryslUCSD opened this issue Mar 28, 2023 · 3 comments

Comments

@PetrKryslUCSD
Copy link
Owner

PetrKryslUCSD commented Mar 28, 2023

@j-fu I started rewriting the SPD solver. I guess that means refactoring the general sparse interface.
How do you feel about that interface now? Would you change something?

@PetrKryslUCSD
Copy link
Owner Author

How about creating an abstract Problem, with subtypes of the detailed Problem as originally designed and a sparse-matrix based Problem?

@j-fu
Copy link
Contributor

j-fu commented Mar 28, 2023

I think in a way we have this already: the CSC part just uses the SparseSolver and in that sense it is different from the part using the Sparspak Problem struct.

Essentially LinearSolve.jl provides a Problem struct for (not only) SparseMatrixCSC which among others can be solved by Sparspak.

@j-fu
Copy link
Contributor

j-fu commented Mar 28, 2023

My main concerns with the architecture are:

  • The _inmatrix methods have quite a bit of complex code as duplicates, and with a bit of time I would try to correct this.
  • We are missing a Factorization struct (as discussed in Update csc interface #23)
  • Also it seems that we could have Cholesky - great that it seems that you try to develop this! In the spirit of my remark Update csc interface #23 I then think about havin a sparspakldt . Julia also has some symmetry detection and Symmetric{A} and Hermitian{A} which can be used for some automatic detection voodoo.

Otherwise I tried to care about being drop-in compatible with other sparse solvers, and having Sparspak as a good citizen of he LinearSolve.jl backend population, and would continue to do so, as I also replaced the linear solver logic in VoronoiVFM.jl with that of LinearSolve.jl (which IMHO could be clearer, but I came to late to that party...) It works quite well and allows to be very flexible with interative/sparse solver choices.

From my POV, the Problm struct in Sparspak is quite good for teaching the steps of sparse linear solvers. I could imagine to use it for this purpose.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants