Skip to content

Pivot to solve-centric design with solve groups #701

@fractalsbyx

Description

@fractalsbyx

Define a solve-group object that contains field variables that will be solved concurrently. PDEType and dependencies then become attributes of the solve-group rather than individual variables.
This would reduce redundancy in defining variable dependencies (which is a common source of bugs in user-code).

Then we could (if we want to) reduce the PDE operator to just one RHS and LHS function and use switch/if statements based on the group index. This can reduce code duplication if different solves use the same constructions (for example, in my app, postprocess, explicit time-dependent, and nucleation probability all use the same interpolation function).

(We could actually do this with our current architecture if we wanted to. This is more of a discussion point. Right now, any custom PDE operator needs to have several functions overridden, which I would consider bloated design.)

The current major barrier to solve-groups is that we cannot do coupled linear-solves. This is because the dealii linear solvers (cg) only take one solution vector and matrix-vector product at a time.
To fix this, we need to use dealii BlockVectors which can be dynamically interpreted as separate vectors or a single vector. This would require another major architecture change.
It may also simplify a GPU implementation.

Currently, we are not utilizing dealii MatrixFree blocks, which I imagine would simplify a lot of work.

Metadata

Metadata

Assignees

No one assigned

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions