DOLFINx
0.12.0.0
DOLFINx C++
Toggle main menu visibility
Loading...
Searching...
No Matches
dolfinx
graph
sfc.h
Go to the documentation of this file.
1
// Copyright (C) 2026 Garth N. Wells
2
//
3
// This file is part of DOLFINx (https://www.fenicsproject.org)
4
//
5
// SPDX-License-Identifier: LGPL-3.0-or-later
6
7
#pragma once
8
9
#include "AdjacencyList.h"
10
#include "partition.h"
11
#include <cstdint>
12
#include <mpi.h>
13
#include <optional>
14
#include <span>
15
#include <vector>
16
19
20
namespace
dolfinx::graph
21
{
45
std::vector<int>
partition_sfc_morton
(
46
MPI_Comm comm,
int
nparts, std::span<const double> x,
int
gdim,
47
std::optional<std::span<const std::int32_t>> weights = std::nullopt);
48
71
std::vector<int>
partition_sfc_hilbert
(
72
MPI_Comm comm,
int
nparts, std::span<const double> x,
int
gdim,
73
std::optional<std::span<const std::int32_t>> weights = std::nullopt);
74
86
std::vector<std::int32_t>
reorder_sfc_morton
(std::span<const double> x,
87
int
gdim);
88
99
std::vector<std::int32_t>
reorder_sfc_hilbert
(std::span<const double> x,
100
int
gdim);
101
}
// namespace dolfinx::graph
dolfinx::graph
Graph data structures and algorithms.
Definition
AdjacencyList.h:23
dolfinx::graph::partition_sfc_hilbert
std::vector< int > partition_sfc_hilbert(MPI_Comm comm, int nparts, std::span< const double > x, int gdim, std::optional< std::span< const std::int32_t > > weights=std::nullopt)
Partition points into nparts groups using a Hilbert space-filling curve.
Definition
sfc.cpp:689
dolfinx::graph::partition_sfc_morton
std::vector< int > partition_sfc_morton(MPI_Comm comm, int nparts, std::span< const double > x, int gdim, std::optional< std::span< const std::int32_t > > weights=std::nullopt)
Partition points into nparts groups using a Morton ('Z-order') space-filling curve.
Definition
sfc.cpp:681
dolfinx::graph::reorder_sfc_hilbert
std::vector< std::int32_t > reorder_sfc_hilbert(std::span< const double > x, int gdim)
Reorder locally supplied points using a Hilbert space-filling curve.
Definition
sfc.cpp:704
dolfinx::graph::reorder_sfc_morton
std::vector< std::int32_t > reorder_sfc_morton(std::span< const double > x, int gdim)
Reorder locally supplied points using a Morton ('Z-order') space-filling curve.
Definition
sfc.cpp:697
Generated by
1.18.0