Seyed,

There is a vector called cell_cf for instance. It contains all integrated 
> material forces (summed up material forces from integration points) for 
> each cell. Each cell has 4 vertices and 8 DoFs in 2D. Hence, it has to be a 
> 8x1 vector.
>
[...]
> Now imagine you have this vector which represents forces for each vertex, 
> e.g. vertex 1 has 0.010126 in X-direction and 0.007502 in Y-direction, 
> vertex 2 has  0.011509 in X-direction and -0.012249  in Y-direction and so 
> on...
>
So you have a FESystem<2>(FE_Q<2>(1),2) element, i.e. linear continuous 
elements with two components, and the vector represents corresponding local 
DoF values?
 

> How is one able now to take these vectors for each cell and assemble them 
> correspondent to the DoF and summarize the values for coinciding nodes. 
> Remember the values are computed within Gauss points and are just 
> summarized over integration points to one single vector for each cell. It 
> means there should be nothing stored on the nodes yet, but we have to take 
> the information to the global structure and node/vertices level.
>
For Q1 elements you have a nodal basis. In particular, assigning the value 
to the DoF with the corresponding support point and component is all you 
have to do. The Gauss quadrature points never include the vertices [1] so 
saying that the values represent forces for each vertex and at the same 
time that the values are computed within Gauss points sounds contradictory.
You can find out about the (global) DoF corresponding to the (vertex_no)th 
vertex via
cell->vertex_dof_index(vertex_no, i) 
where i loops through the number of components, i.e i=0 for the x-component 
and i=1 for the y-component. The position of the (vertex_no)th can be 
obtained by:
cell->vertex(vertex_no)
Note that this approach is only suitable for Q1 elements. For higher 
polynomial degree, you have to calculate the values for all the support 
points of the finite element.
 
Best, 
Daniel 

[1] 
https://en.wikipedia.org/wiki/Gaussian_quadrature#Gauss.E2.80.93Legendre_quadrature
 

-- 
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.
For more options, visit https://groups.google.com/d/optout.

Reply via email to