Arcane  v3.14.10.0
Documentation développeur
Chargement...
Recherche...
Aucune correspondance
CartesianMeshGenerationInfo.h
1// -*- tab-width: 2; indent-tabs-mode: nil; coding: utf-8-with-signature -*-
2//-----------------------------------------------------------------------------
3// Copyright 2000-2022 CEA (www.cea.fr) IFPEN (www.ifpenergiesnouvelles.com)
4// See the top-level COPYRIGHT file for details.
5// SPDX-License-Identifier: Apache-2.0
6//-----------------------------------------------------------------------------
7/*---------------------------------------------------------------------------*/
8/* CartesianMeshGenerationInfo.h (C) 2000-2022 */
9/* */
10/* Informations sur la génération des maillages cartésiens. */
11/*---------------------------------------------------------------------------*/
12#ifndef ARCANE_CORE_INTERNAL_CARTESIANMESHGENERATIONINFO_H
13#define ARCANE_CORE_INTERNAL_CARTESIANMESHGENERATIONINFO_H
14/*---------------------------------------------------------------------------*/
15/*---------------------------------------------------------------------------*/
16
17#include "arcane/utils/ArrayView.h"
18#include "arcane/utils/Real3.h"
19
20#include "arcane/ICartesianMeshGenerationInfo.h"
21
22/*---------------------------------------------------------------------------*/
23/*---------------------------------------------------------------------------*/
24
25namespace Arcane::impl
26{
27
28/*---------------------------------------------------------------------------*/
29/*---------------------------------------------------------------------------*/
34class ARCANE_CORE_EXPORT CartesianMeshGenerationInfo
36{
37 static constexpr Int32 NB_DIM = 3;
38
39 public:
40
42
43 public:
44
45 Int64 globalNbCell() const override { return m_global_nb_cell; }
46 Int64ConstArrayView globalNbCells() const override { return m_global_nb_cells; }
47 Int32ConstArrayView subDomainOffsets() const override { return m_sub_domain_offsets; }
48 Int32ConstArrayView nbSubDomains() const override { return m_nb_sub_domains; }
49 Int32ConstArrayView ownNbCells() const override { return m_own_nb_cells; };
50 Int64ConstArrayView ownCellOffsets() const override { return m_own_cell_offsets; };
51 Int64 firstOwnCellUniqueId() const override { return m_first_own_cell_unique_id; }
52 Real3 globalOrigin() const override { return m_global_origin; };
53 Real3 globalLength() const override { return m_global_length; };
54
55 public:
56
57 void setOwnCellOffsets(Int64 x,Int64 y,Int64 z) override;
58 void setGlobalNbCells(Int64 x,Int64 y,Int64 z) override;
59 void setSubDomainOffsets(Int32 x,Int32 y,Int32 z) override;
60 void setNbSubDomains(Int32 x,Int32 y,Int32 z) override;
61 void setOwnNbCells(Int32 x,Int32 y,Int32 z) override;
62 void setFirstOwnCellUniqueId(Int64 uid) override;
63 void setGlobalOrigin(Real3 pos) override;
64 void setGlobalLength(Real3 length) override;
65
66 private:
67
68 IMesh* m_mesh;
69 Int32 m_mesh_dimension = -1;
70 Int64 m_global_nb_cell = 0;
71
72 Int64ArrayView m_global_nb_cells;
73 Int32ArrayView m_sub_domain_offsets;
74 Int32ArrayView m_nb_sub_domains;
75 Int32ArrayView m_own_nb_cells;
76 Int64ArrayView m_own_cell_offsets;
77
78 Int64 m_global_nb_cell_ptr[NB_DIM];
79 Int32 m_sub_domain_offset_ptr[NB_DIM];
80 Int32 m_nb_sub_domain_ptr[NB_DIM];
81 Int32 m_own_nb_cell_ptr[NB_DIM];
82 Int64 m_own_cell_offset_ptr[NB_DIM];
83 Real3 m_global_origin;
84 Real3 m_global_length;
85
86 Int64 m_first_own_cell_unique_id = -1;
87
88 private:
89
90 void _init();
91};
92
93/*---------------------------------------------------------------------------*/
94/*---------------------------------------------------------------------------*/
95
96} // End namespace Arcane
97
98/*---------------------------------------------------------------------------*/
99/*---------------------------------------------------------------------------*/
100
101#endif
Informations sur la génération des maillages cartésiens.
Lecteur des fichiers de maillage via la bibliothèque LIMA.
Definition Lima.cc:120
Classe gérant un vecteur de réel de dimension 3.
Definition Real3.h:132
Informations sur la génération des maillages cartésiens.
Vue modifiable d'un tableau d'un type T.
Vue constante d'un tableau de type T.