deal.II version GIT relicensing-6834-g5b78e6bcdf 2026-10-01 11:20:01+00:00
\(\newcommand{\dealvcentcolon}{\mathrel{\mathop{:}}}\) \(\newcommand{\dealcoloneq}{\dealvcentcolon\mathrel{\mkern-1.2mu}=}\) \(\newcommand{\jump}[1]{\left[\!\left[ #1 \right]\!\right]}\) \(\newcommand{\average}[1]{\left\{\!\left\{ #1 \right\}\!\right\}}\)
Loading...
Searching...
No Matches
tria_orientation.h
Go to the documentation of this file.
1// -----------------------------------------------------------------------------
2//
3// SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception OR LGPL-2.1-or-later
4// Copyright (C) 2023 - 2025 by the deal.II authors
5//
6// This file is part of the deal.II library.
7//
8// Detailed license information governing the source code and contributions
9// can be found in LICENSE.md and CONTRIBUTING.md at the top level directory.
10//
11// -----------------------------------------------------------------------------
12
13#ifndef dealii_tria_orientation_h
14#define dealii_tria_orientation_h
15
16#include <deal.II/base/config.h>
17
18#include <deal.II/base/types.h>
20
21#include <tuple>
22
24
25namespace internal
26{
31 combined_face_orientation(const bool face_orientation,
32 const bool face_rotation,
33 const bool face_flip)
34 {
35 return (face_orientation ? 0 : 1) + (face_rotation ? 2 : 0) +
36 (face_flip ? 4 : 0);
37 }
38
43 inline std::tuple<bool, bool, bool>
45 const types::geometric_orientation combined_orientation)
46 {
47 Assert(combined_orientation != numbers::invalid_geometric_orientation,
49 "The provided orientation value is not valid. This typically "
50 "means this value was initialized to an invalid value and not "
51 "correctly set later."));
52 return {!Utilities::get_bit(combined_orientation, 0),
53 Utilities::get_bit(combined_orientation, 1),
54 Utilities::get_bit(combined_orientation, 2)};
55 }
56
57
58} // namespace internal
59
60
61
63
64#endif
#define DEAL_II_NAMESPACE_OPEN
Definition config.h:38
#define DEAL_II_NAMESPACE_CLOSE
Definition config.h:39
#define Assert(cond, exc)
static ::ExceptionBase & ExcMessage(std::string arg1)
bool get_bit(const unsigned char number, const unsigned int n)
Definition utilities.h:1564
types::geometric_orientation combined_face_orientation(const bool face_orientation, const bool face_rotation, const bool face_flip)
std::tuple< bool, bool, bool > split_face_orientation(const types::geometric_orientation combined_orientation)
constexpr types::geometric_orientation invalid_geometric_orientation
Definition types.h:369
std::uint8_t geometric_orientation
Definition types.h:38