From: Wolfgang Bangerth Date: Sat, 18 Oct 2008 04:01:20 +0000 (+0000) Subject: When reinit-ing vectors, do not assume that we should create a new equidistributed... X-Git-Tag: v8.0.0~8528 X-Git-Url: https://gitweb.dealii.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=1c139c183e9fca707f75e8e8209098edb1d0f547;p=dealii.git When reinit-ing vectors, do not assume that we should create a new equidistributed map but actually copy the Epetra_Map of the base vector. git-svn-id: https://svn.dealii.org/trunk@17273 0785d39b-7218-0410-832d-ea1e28bc413d --- diff --git a/deal.II/lac/source/trilinos_vector.cc b/deal.II/lac/source/trilinos_vector.cc index 5e4ad408fe..caa5d8d56f 100755 --- a/deal.II/lac/source/trilinos_vector.cc +++ b/deal.II/lac/source/trilinos_vector.cc @@ -118,7 +118,10 @@ namespace TrilinosWrappers { vector.reset(); if (map.SameAs(v.vector->Map()) == false) - map = Epetra_Map(v.vector->GlobalLength(),0,v.vector->Comm()); + map = Epetra_Map(v.vector->Map().NumGlobalElements(), + v.vector->Map().NumMyElements(), + v.vector->Map().IndexBase(), + v.vector->Map().Comm()); vector = std::auto_ptr (new Epetra_FEVector(map)); last_action = Zero;