DG for incompressible NSE

In the above trilinear form we need to use the convect(.) operator for first term but for other terms how we can write them in freefem.

You have an example of use of discontinuous Galerkin for the Laplace problem at
You will see the use of mean() and jump()

1 Like

Is it possible to modify the content of mean() and jump()? I would like to use a weighted DG method where the mean and jump functions are not defined with the standard definitions.

Thank you, N.

I would say that it is not possible to modify them, but maybe somebody has some ideas to do that (take a combination of mean and jump in order to get a weighted mean ?). It depends strongly on the precise formula you would like to implement…

Hello Sir, I am trying to apply DG for pressure correction scheme of navier stokes equation.
In my code the bilinear form,:-
problem U ([uu1,uu2], [v1,v2])= int2d(Th) (uu1v1+uu2 v2) + int2d(Th) (phidt (dx(v1) + dy(v2))) // velocity Correction
-intalledges(Th) (dt * mean(phi) * (jump(v1)*N.x+jump(v2)N.y)/nTonEdge)
-int2d(Th)(u1 * v1+u2 * v2)
isn’t working. Here phi is a known value, calculated from a previous bilinear form. I think the problem occurs when i am trying to integrate the product “mean(phi)
( jump(v1) * N.x + jump(v2) * N.y)”.
So is there any other way of doing this integration or the problem is in somewhere else.
Please enlighten me.

What do you mean by “isn’t working”? Does it produce an error? Is it doing nothing? Is it doing something different than what you expect?
It is difficult to answer without the code.