*/
const Epetra_Comm& comm_world();
+ /**
+ * Returns a Trilinos Epetra_Comm
+ * object needed for creation of
+ * Epetra_Maps.
+ *
+ * If deal.II has been configured to use
+ * a compiler that does not support MPI
+ * then the resulting communicator will
+ * be a serial one. Otherwise, the
+ * communicator will correspond to
+ * MPI_COMM_SELF, i.e. a communicator
+ * that comprises only this one
+ * processor.
+ */
+ const Epetra_Comm& comm_self();
+
/**
* Given a communicator, duplicate it. If
* the given communicator is serial, that
+ const Epetra_Comm&
+ comm_self()
+ {
+#ifdef DEAL_II_COMPILER_SUPPORTS_MPI
+ static Teuchos::RCP<Epetra_MpiComm>
+ communicator = Teuchos::rcp (new Epetra_MpiComm (MPI_COMM_SELF), true);
+#else
+ static Teuchos::RCP<Epetra_SerialComm>
+ communicator = Teuchos::rcp (new Epetra_SerialComm (), true);
+#endif
+
+ return *communicator;
+ }
+
+
+
Epetra_Comm *
duplicate_communicator (const Epetra_Comm &communicator)
{