Bruce, [...] 3. Like in 2., but for adding values to individual elements. Use > VectorOperation::add. > > I guess 3) is obscure. Does this mean that you are adding a new element > where none existed before or that you are incrementing an existing element? > If the former, aren't the total number of elements in a vector specified > when you declare the vector size so how do you add more elements? > This does not mean that you want to modify the size of a vector or the underlying distribution pattern. It just means that after you modify some element of a vector using its original value, e.g. vec(5)+=2, you need to call compress(VectorOperation::add).
> > The results coming from p_local_solution look good (smooth) and appear to > have been scaled, only the results for p_local_rho have a problem. I've > tried to create a simple reproducer but so far haven't had any success. > I'll keep trying. > As you already figured, DataOut needs a ghosted vector containing all the elements on locally owned cells for proper output. If I read your code correctly, only p_local_solution and rho have ghost elements while p_local_rho and phi are completely distributed, i.e. the don't have ghost elements. Hence, I am not surprised that the visualization of p_local_rho looks incorrect. Best, Daniel -- 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.