Thank you for your explanations. Basically I formed a weak form of the PDE for 
one element and numerically integrate it at the Gaussian points based on the 
interpolation from the local nodes. Subsequently, I assemble the weak forms 
from all elements into a global system matrix based on a local-to-global 
mapping of the nodes. After applying the boundary conditions, I solve this 
linear system using a linear solver in Intel mkl.

In deal.II, I took almost the same procedures. I formed the weak form for each 
element and assemble them based on the local-to-global mapping. After applying 
the boundary conditions, I solved it with the SparseDirectFUMPK solver. The 
only difference is that I got a very clear discontinuous gradient over the 
edges of elements. I think the solution from deal.II is more close to the 
theorem of FEM, which explains the fundamental idea of weak form. However, I am 
puzzled at why I did not read it in the FEM books before.

Best
David

________________________________
From: Wolfgang Bangerth <bange...@colostate.edu>
Sent: Saturday, January 18, 2020, 11:58 PM
To: David Eaton; dealii@googlegroups.com
Subject: Re: [deal.II] discontinous contour over elements

On 1/17/20 9:11 PM, David Eaton wrote:
>
> Thanks the help from you and the others. The issue of discontinuous vorticity
> field is resolved. Theoretically, I understand the gradient should be
> discontinuous for C0 elements.  However, I still want to convince myself with
> a explanation. while I used Q2Q1 Taylor-Hood element, the discontinuous
> contour still appear. What could be the reason for this?

And they should! You might be thinking that for Q2 functions, if you take the
gradient, you should still get a linear function that is continuous. But the
Q2 functions are only quadratic on each cell separately; they still have a
kink at cell interfaces, and consequently their gradient is discontinuous.


> On the other hand, I
> have a very simple FEM code using C0 elements without doing the projections.
> I just simply assembly the matrix, use a Lagrangian shape function in C0
> element and solve it with a linear solver. It does give a continuous contour
> without doing a projection. What could be the theoretical reason why it does
> not give a discontinuous contour? Is L2 projection is necessary step while
> computing gradients over elements for C0 elements?

Can you describe in mathematical terms what you do? When you say "assemble a
matrix" and "solve it", that sounds a lot like a projection to me.

Best
  W.

--
------------------------------------------------------------------------
Wolfgang Bangerth          email:                 bange...@colostate.edu
                            www: http://www.math.colostate.edu/~bangerth/

Q

Get Outlook for Android<https://aka.ms/ghei36>

-- 
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/SG2PR01MB25497E330F2E2F79F564B963C3300%40SG2PR01MB2549.apcprd01.prod.exchangelabs.com.

Reply via email to