Hello! I have some general questions about deal.II. I am not sure if what I think is correct. Thank you for your help!
i) Copy Trilinos::MPI::Vector Consider using Trilinos to do MPI. Suppose the following vectors: TrilinosWrappers::MPI::Vector distributed_sln_old (locally_owned_dofs, mpi_communicator), distributed_sln_new (locally_owned_dofs, mpi_communicator); TrilinosWrappers::MPI::Vector locally_relevant_sln_with_ghost_old (locally_owned_dofs, locally_relevant_dofs, mpi_communicator), locally_relevant_sln_with_ghost_new (locally_owned_dofs, locally_relevant_dofs, mpi_communicator); //this is the local vector with ghost. //Now we have four assignments: locally_relevant_sln_with_ghost_new = distributed_sln_new; //This is commonly seen in the tutorials. I assume the locally_owned_dofs are copied, and the ghosts are properly updated. distributed_sln_new = distributed_sln_old; //These two are all local vectors, so it is just a copy operation. locally_relevant_sln_with_ghost_new = locally_relevant_sln_with_ghost_old; //This and the following one are rarely seen in the tutorials. Does this mean the vector is exactly copied? i.e. both locally_owned_dofs and the ghost_dofs are all copied? distributed_sln_new = locally_relevant_sln_with_ghost_new; //Does this mean the locally_owned_dofs are copied, while the ghosts are neglected? ii) ConstraintMatrix::distribute() and Newton's method In a Newton's method solver, we have: version A: //...get the new newton_update vector from solving the equation constraints.distribute(newton_update); new_sln = old_sln + alpha* newton_update; version B: //...get the new newton_update vector from solving the equation new_sln = old_sln + alpha* newton_update; constraints.distribute(new_sln); In the tutorials it seems version A is more commonly used. However, it seems to me that if there are inhomogeneous constraints, then only version B is correct. Is it right? I don't know how the distribute() function is implemented, but based on the documentation it seems version B is a more logical and universal way. iii) solve system with inhomogeneous constraints I have a problem with inhomogeneous constraints. I did some tests and it seems that sometimes the solver collapses due to convergence(?) while sometimes it doesn't, for example depending on the mesh. May I ask, with inhomogeneous constraints, do I need to, say, choose different preconditioner, or providing the preconditioner with AdditionalData? Best, Yiyang -- 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.