Additional SchurComplement Feature

Issue #43 closed
Alistair Bentley created an issue

I've been working on performance testing some new preconditioning options for NSE in Proteus. I'd like to be able to specify my own approximation for the Schur operator S that appears in the Schur complement method. I believe this can be achieved with the PETSc function MatCreateSchurComplement but I haven't found support for this in petsc4py.

I'd be happy to submit a PR adding this feature but I wanted to make sure it wasn't already something that was already in place that I just missed.

Thanks in advance,

Alistair

Comments (6)

  1. Lisandro Dalcin

    No, these wrappers are missing. Contributions welcome! Thank you in advance...

    PS: However, make sure MatCreateSchurComplement() is what you really need. Maybe all what you need is to define a new matrix operator with the right sizes according to the pressure space discretization. Are you planning to build an explicit, AIJ-format matrix for the preconditioner? Or maybe will you use a "matrix-free" approach? For the second case, petsc4py do have something builtin. Just let me know.

  2. Alistair Bentley reporter

    Thanks for the comments.

    Originally I was planning to use the matrix-free approach to build the operator, but I didn't see a way to override the default PETSc approximation to the Schur operator. After a bit of reading, it seemed to me that MatCreateSchurComplement might be able to do the trick.

    Anyway, I'm going to play around with this for a bit and I'll circle back when I find a solution.

  3. Alistair Bentley reporter

    Sorry for dragging my feet on this. I've been able to achieve what I was hoping for through the ksp.pc object. That said, I keep meaning to set up MatCreateSchurComplement() function because I think it will achieve the same thing in a more transparent way. Either way, feel free to close this issue and whenever I get around to setting up MatCreateSchurComplement() I can submit the wrapper in a PR.

  4. Log in to comment