Hello SfePy devels,
Could you, please, explain me some SfePy internals?
(1) Question 1. Surface processing.
As I see in examples the 3D meshes contains only volume elements (tetrahedra) and no surface elements (triangles). But in problem solution pipeline we need to apply essential boundary conditions on surface nodes and need to evaluate some surface integrals, for example, for Neumann boundary conditions. How does SfePy working with surfaces?
For essential boundary conditions, yes, we can take only the far nodes in tetrahedra. But for the surface integrals we need the surface elements -- triangles. Does SfePy extract boundary triangles from volume tetrahedra?
(2) Question 2. Dimensions of the SfePy arrays.
Consider the postprocesing hook: def post_process(out, pb, state, extend = False): electric_field = pb.evaluate('ev_grad.2.Omega(u)', mode='el_avg') print electric_field.shape
flux = pb.evaluate('d_surface_flux.2.Gamma(m.K, u)', mode='el_avg')
print flux.shape
In my example shapes are: electric_field: (5235, 1, 3, 1) flux: (3898, 1, 1, 1)
Could you explain me why the variables are 4-dimensional arrays. My understanding is following: the surface?
- 1st dimension is the number of the tetrahedra element. 5235 is the total number of the volume element. By what is 3898? Is it a number of the tetrahedra which are contains in boundary or is it a number of triangles on
- The 3d dimension is the dimension of variable. The grad is a 3 dimensional vector, the flux is a scalar. But what are the 2nd and 4th dimensions?
Sincerely, Alexander.