Reference documentation for deal.II version 9.5.0
\(\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// Copyright (C) 2009 - 2023 by the deal.II authors
4//
5// This file is part of the deal.II library.
6//
7// The deal.II library is free software; you can use it, redistribute
8// it, and/or modify it under the terms of the GNU Lesser General
9// Public License as published by the Free Software Foundation; either
10// version 2.1 of the License, or (at your option) any later version.
11// The full text of the license can be found in the file LICENSE.md at
12// the top level directory of deal.II.
13//
14// ---------------------------------------------------------------------
15
16#ifndef dealii_types_h
17#define dealii_types_h
18
19
20#include <deal.II/base/config.h>
21
22#include <cstdint>
23#include <type_traits> // make_signed_t
24
25
27
32namespace types
33{
44 using subdomain_id = unsigned int;
45
49 using global_vertex_index = std::uint64_t;
50
55#define DEAL_II_VERTEX_INDEX_MPI_TYPE MPI_UINT64_T
56
60 using fe_index = unsigned short int;
61
79#ifdef DEAL_II_WITH_64BIT_INDICES
80 using global_dof_index = std::uint64_t;
81#else
82 using global_dof_index = unsigned int;
83#endif
84
90 using signed_global_dof_index = std::make_signed_t<global_dof_index>;
91
96#ifdef DEAL_II_WITH_64BIT_INDICES
97# define DEAL_II_DOF_INDEX_MPI_TYPE MPI_UINT64_T
98#else
99# define DEAL_II_DOF_INDEX_MPI_TYPE MPI_UNSIGNED
100#endif
101
115#ifdef DEAL_II_WITH_64BIT_INDICES
116 using global_cell_index = std::uint64_t;
117#else
118 using global_cell_index = unsigned int;
119#endif
120
128
141 using boundary_id = unsigned int;
142
153 using manifold_id = unsigned int;
154
164 using material_id = unsigned int;
165
169 using geometric_entity_type = std::uint8_t;
170} // namespace types
171
175using TrilinosScalar = double;
176
177
178namespace TrilinosWrappers
179{
180 namespace types
181 {
185 using int64_type = long long int;
186
187#ifdef DEAL_II_WITH_64BIT_INDICES
191 using int_type = int64_type;
192#else
196 using int_type = int;
197#endif
198 } // namespace types
199} // namespace TrilinosWrappers
200
201
202// this part of the namespace numbers got moved to the bottom types.h file,
203// because otherwise we get a circular inclusion of config.h, types.h, and
204// numbers.h
205namespace numbers
206{
213 static const unsigned int invalid_unsigned_int =
214 static_cast<unsigned int>(-1);
215
223 static_cast<types::global_dof_index>(-1);
224
229
234 static_cast<types::global_dof_index>(-1);
235
243 static_cast<types::coarse_cell_id>(-1);
244
251 static_cast<types::material_id>(-1);
252
262 static_cast<types::boundary_id>(-1);
263
278 static_cast<types::boundary_id>(-1);
279
287 static_cast<types::manifold_id>(-1);
288
299 static_cast<types::subdomain_id>(-1);
300
316 static_cast<types::subdomain_id>(-2);
317} // namespace numbers
318
320
321#endif
#define DEAL_II_NAMESPACE_OPEN
Definition config.h:472
#define DEAL_II_NAMESPACE_CLOSE
Definition config.h:473
long long int int64_type
Definition types.h:185
const types::material_id invalid_material_id
Definition types.h:250
const types::boundary_id invalid_boundary_id
Definition types.h:261
const types::boundary_id internal_face_boundary_id
Definition types.h:277
const types::coarse_cell_id invalid_coarse_cell_id
Definition types.h:242
const types::fe_index invalid_fe_index
Definition types.h:228
const types::subdomain_id artificial_subdomain_id
Definition types.h:315
const types::subdomain_id invalid_subdomain_id
Definition types.h:298
static const unsigned int invalid_unsigned_int
Definition types.h:213
const types::manifold_id flat_manifold_id
Definition types.h:286
const types::global_dof_index invalid_dof_index
Definition types.h:233
const types::global_dof_index invalid_size_type
Definition types.h:222
Definition types.h:33
std::uint64_t global_vertex_index
Definition types.h:49
std::uint8_t geometric_entity_type
Definition types.h:169
unsigned short int fe_index
Definition types.h:60
std::make_signed_t< global_dof_index > signed_global_dof_index
Definition types.h:90
unsigned int global_cell_index
Definition types.h:118
double TrilinosScalar
Definition types.h:175