" When you solve a new linear system with the matrix, that linear system knows nothing about what happened when you first built the matrix and the original right hand side."
Yes, but I have to call constraints.distribute_local_to_global (...) also when building the new linear system. But I observed that there is also a constraints.distribute_local_to_global () function which writes only into the global matrix. I also need the system matrix A for a second purpose, namely to compute a matrix multiplication: res = A^{-1} * B , where B is another matrix. -To be more precise, I need the inverse of the 19x19 submatrix corresponding to the unconstrained DoFs only -- not the inverse of the full system matrix.. I could not find a function which computes the inverse of a sparse matrix directly (without solving a linear system). What I tried is, LAPACKFullMatrix<double> new_matrix = my_system_matrix , thence calling the invert function. But I am not sure if this is the right way to go. -Also, after calling constraints.distribute_local_to_global(), does it make sense at all to compute an inverse matrix, given that some rows and columns were set to zero? Thank you again! Best Simon Am Fr., 19. Aug. 2022 um 09:59 Uhr schrieb Wolfgang Bangerth < bange...@colostate.edu>: > On 8/19/22 05:46, Simon Wiesheier wrote: > > > > This system boilds down to a 2x2 system for x1 and x2 with x0=0. > > This is exactly what I want to compute, but without having -c*K10 > substracted. > > (Because the new rhs comes from a different problem and has nothing to > do with > > the constrainted dofs - I just need the 2x2 portion from the original > problem) > > Right. But c*K10 is subtracted from the right hand side when you call > constraints.distribute_local_to_global (...) > It is not magically stored somewhere. When you solve a new linear system > with > the matrix, that linear system knows nothing about what happened when you > first built the matrix and the original right hand side. > > Best > W. > > -- > ------------------------------------------------------------------------ > Wolfgang Bangerth email: bange...@colostate.edu > 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 dealii+unsubscr...@googlegroups.com. > To view this discussion on the web visit > https://groups.google.com/d/msgid/dealii/66de0c9f-8dce-48a3-a7fb-6a047bc4f1c7%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 dealii+unsubscr...@googlegroups.com. To view this discussion on the web visit https://groups.google.com/d/msgid/dealii/CAM50jEspLNDrgcjfZwyKPUmMq8YWi4oZyxvQJHPjw%2BRQ4rSxxg%40mail.gmail.com.