File: mpi_utils.h

package info (click to toggle)
dolfinx-mpc 0.9.3-1
  • links: PTS, VCS
  • area: main
  • in suites: sid
  • size: 1,188 kB
  • sloc: python: 7,263; cpp: 5,462; makefile: 69; sh: 4
file content (22 lines) | stat: -rw-r--r-- 574 bytes parent folder | download | duplicates (3)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
// Copyright (C) 2022 Jorgen S. Dokken
//
// This file is part of DOLFINX_MPC
//
// SPDX-License-Identifier:    MIT

#include <dolfinx/common/IndexMap.h>
#include <dolfinx/common/MPI.h>

namespace dolfinx_mpc
{
/// @brief Create a MPI-communicator from owners in the index map to the
/// processes with ghosts
///
/// @param[in] map The index map
/// @returns The mpi communicator
MPI_Comm create_owner_to_ghost_comm(const dolfinx::common::IndexMap& map);

std::pair<std::vector<int>, std::vector<int>>
compute_neighborhood(const MPI_Comm& comm);

} // namespace dolfinx_mpc