If you want to take some more inspiration using mesh_loop, ScratchData, and 
FEInterfaceData, you could take a look at this:

https://github.com/dealii/dealii/blob/master/tests/meshworker/scratch_data_08.cc

where the FEInterfaceValues which is now included in ScratchData is used to 
solve SIPG on locally refined grids, with just this:



    for (unsigned int q = 0; q < p.size(); ++q)
      for (unsigned int i = 0; i < n_dofs; ++i)
        for (unsigned int j = 0; j < n_dofs; ++j)
          {
            face_matrix(i, j) +=
              (-fev.jump_gradient(i, q) * n[q] * fev.average(j, q) -
               fev.average(i, q) * fev.jump_gradient(j, q) * n[q] +
               gh * fev.jump(i, q) * fev.jump(j, q)) *
              JxW[q];
          }
  };

:)

Ps: I am planning to extend FEInterfaceValues to be able to extract function 
values and gradients, so that it can also be used easily with the automatic 
differentiation tools that 
we have, or to easily write a posteriori error estimators… If anybody is 
looking for a starter project, this may be a very nice one.

L.

> On 10 Jul 2020, at 17:09, Bruno Blais <blais.br...@gmail.com> wrote:
> 
> Dear Timo,
> A step-12-like version of Step-39 for the Laplace equation would be very 
> interesting. I would be glad to help on making one of those. The same could 
> be said about the Stokes equations.
> 
> Ideally, once that is done, i would like to try and make one for stabilized 
> Navier-Stokes for both CG and DG, but I feel I need a bit more of experience 
> with writing steps before I move on to that.
> 
> So if you feel you need any help with the two aforementioned steps, I would 
> be glad to help. I really like what you have done with the FEInterfaceValues, 
> so if we can make it more popular, why not ? :)!
> I am also integrating teaching DG within one of my graduate classes and I 
> feel using deal.II for that will be really helpful.
> 
> Best
> Bruno
> 
> 
> 
> 
> On Friday, 10 July 2020 07:39:08 UTC-4, Timo Heister wrote:
> Hi Bruno, 
> 
> I introduced FEInterfaceValues because I was frustrated by the lack of 
> DG examples and as a consequence DG users in the community and I 
> realized that a more intuitive way to teach it was necessary. Of 
> course we need more than 1 or 2 examples to do that. 
> I have a lot of unfinished stuff on my machine including working 
> Laplace and Stokes examples (see my todo list here 
> https://github.com/dealii/dealii/issues/8884 ) that I haven't gotten 
> back to yet. 
> 
> Let me know if you want to work together on something or if you have 
> any ideas or suggestions. 
> 
> Best, 
> Timo 
> 
> 
> On Thu, Jul 9, 2020 at 8:50 PM Bruno Blais <blais...@gmail.com> wrote: 
> > 
> > Dear all, 
> > I hope you are well. 
> > I have been playing with the DG methods within deal.II lately (which has 
> > been lots of fun). 
> > I really enjoy the way step-12 is written, especially because of the use of 
> > the FEInterfaceValue class. In my opinion it makes low level stuff very 
> > easily accessible, yet it is relatively easy to understand. 
> > However, I am under the impression that there are no similar test for 
> > elliptic equations in which you need to use Nitsche method + Symmetric 
> > Interior Penalty for the boundary + inner faces respectively. I know of 
> > step-39, but it does not use the same "low-levelish" features. 
> > I have written such a code for my own pleasure for the laplace equation and 
> > I am currently working on its advection-diffusion version (mostly following 
> > Larson Chapter 14). 
> > 
> > Would it be interesting to turn such a case into a deal.II step (that would 
> > follow in step-12 footstep) or does the community feel that the existing 
> > steps for DG sufficiently cover the ground? 
> > 
> > Best 
> > Bruno 
> > 
> > -- 
> > The deal.II project is located at http://www.dealii.org/ 
> > For mailing list/forum options, see 
> > https://groups.google.com/d/forum/dealii?hl=en 
> > --- 
> > You received this message because you are subscribed to the Google Groups 
> > "deal.II User Group" group. 
> > To unsubscribe from this group and stop receiving emails from it, send an 
> > email to dea...@googlegroups.com. 
> > To view this discussion on the web visit 
> > https://groups.google.com/d/msgid/dealii/b931b23c-b284-4047-a887-d500ac9e8486o%40googlegroups.com.
> >  
> 
> 
> 
> -- 
> Timo Heister 
> http://www.math.clemson.edu/~heister/ 
> 
> -- 
> The deal.II project is located at http://www.dealii.org/
> For mailing list/forum options, see 
> https://groups.google.com/d/forum/dealii?hl=en
> --- 
> You received this message because you are subscribed to the Google Groups 
> "deal.II User Group" group.
> To unsubscribe from this group and stop receiving emails from it, send an 
> email to dealii+unsubscr...@googlegroups.com.
> To view this discussion on the web visit 
> https://groups.google.com/d/msgid/dealii/9340f75c-a631-46e0-ac2e-400c6d14ff57o%40googlegroups.com.

-- 
The deal.II project is located at http://www.dealii.org/
For mailing list/forum options, see 
https://groups.google.com/d/forum/dealii?hl=en
--- 
You received this message because you are subscribed to the Google Groups 
"deal.II User Group" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to dealii+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/dealii/E95FA8C8-02BD-4C8E-B663-472B60303410%40gmail.com.

Reply via email to