Yes, basically I want to compute a matrix-vector product. But if my system has say 500k DoFs, I only need say 1k elements of the result of vmult, because the number of rows I am interested in is quite small -- they correspond to a small set of DoFs living on the boundary.
For efficiency reasons, I decided to loop manually over the rows I am interested in. In a serial program, that worked smoothly. But if I get the gist of your message, vmult and extracting the relevant elements is the only way to do this in parallel, right? Thank you, Simon Wolfgang Bangerth <[email protected]> schrieb am Fr., 29. Dez. 2023, 19:02: > On 12/28/23 12:22, Simon wrote: > > > > I want to build the scalar product between rows of a > > TrilinosWrappers::SparseMatrix and a TrilinosWrappers::MPI::Vector. > > This sounds like you're computing a matrix-vector product -- the dot > products > you compute are the elements of the resulting vector. > > As you have learned, it isn't entirely trivial to determine how > information > must be transmitted in parallel for these kinds of operations. But it is > also > not necessary: The parallel matrix classes all have matrix-vector > ("vmult") > operations implemented. Why not use those? > > Best > W. > > -- > ------------------------------------------------------------------------ > Wolfgang Bangerth email: [email protected] > www: http://www.math.colostate.edu/~bangerth/ > > > -- > 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 [email protected]. > To view this discussion on the web visit > https://groups.google.com/d/msgid/dealii/8e748b05-a6da-45d6-bd2a-23b552c818e6%40colostate.edu > . > -- 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 [email protected]. To view this discussion on the web visit https://groups.google.com/d/msgid/dealii/CAM50jEs67zos%3D4oJ3fGs2_J_-T-2vsywjb6xVdd7BTqXd5%2B6AQ%40mail.gmail.com.
