n components with matrix-free and MPI

13 views
Skip to first unread message

Hermes Sampedro

unread,
Oct 21, 2021, 6:20:04 AM10/21/21
to deal.II User Group
Dear all, 

I am having some trouble understanding how to have access to the different components (2 for complex values) in a matrix-free implementation and MPI. I need to have access to each component to perform the different operations to them in the local_apply() function.

I saw this documentation (https://www.dealii.org/current/doxygen/deal.II/classFEEvaluation.html, @Handling multi-component systems) which get the components using BlockVectors. 
However, I define in my class FESystem<dim>  fe;  and after, fe(FE_Q<dim>(degree), 2)  to have 2 components and use LinearAlgebra::distributed::Vector<number> for the solution, dst, scr.
In this case, is it possible to have access to the different components using blocks() as it is done in the example (https://github.com/dealii/dealii/blob/master/tests/matrix_free/matrix_vector_stokes_noflux.cc, line 67) using for example phi.read_dof_values(src.block(0)) ?


I would really appreciate it if I can get help on this matter.

Regards, 
H.



Reply all
Reply to author
Forward
0 new messages