Make the factorization algorithm applicable to coefficients

Issue #43 new
Dominic Kempf created an issue

I admit I have no idea of how hard it is to implement this or what other technical difficulties it might come along with. The underlying problem I want to solve is the following:

dune-pdelab uses a residual formulation. To make this compatible with UFL, the trial function is not considered an argument, but a coefficient (I subclassed TrialFunction). At code generation time, however, that coefficient is treated different from normal coefficients (much more like an argument).

Rewriting our code to work with the factorized output from uflacs, I liked very much how the generation code for arguments simplified (AND got more robust). However, I still have the same ugly problems with the trial function, that I had before. So I thought it would be very nice to be able to tell uflacs to treat a certain coefficient as an argument w.r.t. to the factorization algorithm.

I assign this to you, Martin, as I guess you are the only possible contact person for this question :D

Comments (3)

  1. Martin Sandve Alnæs

    Hmm... possibly not very hard. Will try when I get around to a planned minor review of that code. (Although I'm a bit busy in the immediate future).

    Do you compute the element matrix and vector in the same kernel? I've thought about adding that, for the obvious savings for nonlinear problems.

  2. Dominic Kempf reporter

    No, we do use different kernels there (for reasons of simplicity). With a fully functional code generation tool chain around, we could/should of course add combined kernels (should be rather simple, I guess). How is that connected to my question?

    Thanks for having a look!

  3. Martin Sandve Alnæs
    • removed responsible

    Removing assignment to me so I can use the assignee field to denote what I'm working on short-term.

  4. Log in to comment