deal.II version GIT relicensing-2084-gab787ef0dd 2024-11-04 03:10:00+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
types.h
Go to the documentation of this file.
1// ------------------------------------------------------------------------
2//
3// SPDX-License-Identifier: LGPL-2.1-or-later
4// Copyright (C) 2010 - 2023 by the deal.II authors
5//
6// This file is part of the deal.II library.
7//
8// Part of the source code is dual licensed under Apache-2.0 WITH
9// LLVM-exception OR LGPL-2.1-or-later. Detailed license information
10// governing the source code and code contributions can be found in
11// LICENSE.md and CONTRIBUTING.md at the top level directory of deal.II.
12//
13// ------------------------------------------------------------------------
14
15#ifndef dealii_types_h
16#define dealii_types_h
17
18
19#include <deal.II/base/config.h>
20
21#include <cstdint>
22#include <type_traits> // make_signed_t
23
24
26
31namespace types
32{
43 using subdomain_id = unsigned int;
44
48 using global_vertex_index = std::uint64_t;
49
54#define DEAL_II_VERTEX_INDEX_MPI_TYPE MPI_UINT64_T
55
59 using fe_index = unsigned short int;
60
78#ifdef DEAL_II_WITH_64BIT_INDICES
79 using global_dof_index = std::uint64_t;
80#else
81 using global_dof_index = unsigned int;
82#endif
83
89#ifdef DEAL_II_WITH_64BIT_INDICES
90 using signed_global_dof_index = long long;
91#else
93#endif
94
99#ifdef DEAL_II_WITH_64BIT_INDICES
100# define DEAL_II_DOF_INDEX_MPI_TYPE MPI_UINT64_T
101#else
102# define DEAL_II_DOF_INDEX_MPI_TYPE MPI_UNSIGNED
103#endif
104
118#ifdef DEAL_II_WITH_64BIT_INDICES
119 using global_cell_index = std::uint64_t;
120#else
121 using global_cell_index = unsigned int;
122#endif
123
131
144 using boundary_id = unsigned int;
145
156 using manifold_id = unsigned int;
157
167 using material_id = unsigned int;
168
172 using geometric_entity_type = std::uint8_t;
173} // namespace types
174
178using TrilinosScalar = double;
179
180
181namespace TrilinosWrappers
182{
183 namespace types
184 {
188 using int64_type = long long int;
189
190#ifdef DEAL_II_WITH_64BIT_INDICES
194 using int_type = int64_type;
195#else
199 using int_type = int;
200#endif
201 } // namespace types
202} // namespace TrilinosWrappers
203
204
205// this part of the namespace numbers got moved to the bottom types.h file,
206// because otherwise we get a circular inclusion of config.h, types.h, and
207// numbers.h
208namespace numbers
209{
220 static const unsigned int invalid_unsigned_int =
221 static_cast<unsigned int>(-1);
222
234 static_cast<types::global_dof_index>(-1);
235
244
253 static_cast<types::global_dof_index>(-1);
254
266 static_cast<types::coarse_cell_id>(-1);
267
278 static_cast<types::material_id>(-1);
279
293 static_cast<types::boundary_id>(-1);
294
313 static_cast<types::boundary_id>(-1);
314
326 static_cast<types::manifold_id>(-1);
327
342 static_cast<types::subdomain_id>(-1);
343
363 static_cast<types::subdomain_id>(-2);
364} // namespace numbers
365
367
368#endif
#define DEAL_II_NAMESPACE_OPEN
Definition config.h:498
#define DEAL_II_NAMESPACE_CLOSE
Definition config.h:499
long long int int64_type
Definition types.h:188
const types::material_id invalid_material_id
Definition types.h:277
const types::boundary_id invalid_boundary_id
Definition types.h:292
const types::boundary_id internal_face_boundary_id
Definition types.h:312
const types::coarse_cell_id invalid_coarse_cell_id
Definition types.h:265
const types::fe_index invalid_fe_index
Definition types.h:243
const types::subdomain_id artificial_subdomain_id
Definition types.h:362
const types::subdomain_id invalid_subdomain_id
Definition types.h:341
static const unsigned int invalid_unsigned_int
Definition types.h:220
const types::manifold_id flat_manifold_id
Definition types.h:325
const types::global_dof_index invalid_dof_index
Definition types.h:252
const types::global_dof_index invalid_size_type
Definition types.h:233
Definition types.h:32
std::uint64_t global_vertex_index
Definition types.h:48
std::uint8_t geometric_entity_type
Definition types.h:172
unsigned short int fe_index
Definition types.h:59
unsigned int global_cell_index
Definition types.h:121
double TrilinosScalar
Definition types.h:178