Arcane  v3.14.10.0
Documentation développeur
Chargement...
Recherche...
Aucune correspondance
GhostLayerBuilder.h
1// -*- tab-width: 2; indent-tabs-mode: nil; coding: utf-8-with-signature -*-
2//-----------------------------------------------------------------------------
3// Copyright 2000-2024 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/* GhostLayerBuilder.h (C) 2000-2024 */
9/* */
10/* Construction des couches fantômes. */
11/*---------------------------------------------------------------------------*/
12#ifndef ARCANE_MESH_GHOSTLAYERBUILDER_H
13#define ARCANE_MESH_GHOSTLAYERBUILDER_H
14/*---------------------------------------------------------------------------*/
15/*---------------------------------------------------------------------------*/
16
17#include "arcane/utils/TraceAccessor.h"
18
19#include "arcane/mesh/DynamicMeshIncrementalBuilder.h"
20
21/*---------------------------------------------------------------------------*/
22/*---------------------------------------------------------------------------*/
23
24namespace Arcane
25{
26class SerializeBuffer;
27}
28
29namespace Arcane::mesh
30{
31class DynamicMesh;
32
33/*---------------------------------------------------------------------------*/
34/*---------------------------------------------------------------------------*/
39: public TraceAccessor
40{
41 public:
42
44
47
48 public:
49
52 virtual ~GhostLayerBuilder();
53
54 public:
55
56 void addGhostLayers(bool is_allocate);
57
60 void addGhostChildFromParent2(Array<Int64>& ghost_cell_to_refine);
61
62 private:
63
64 DynamicMesh* m_mesh;
65 DynamicMeshIncrementalBuilder* m_mesh_builder;
66
67 private:
68
69 void _addOneGhostLayerV2();
70 void _exchangeData(IParallelExchanger* exchanger,BoundaryInfosMap& boundary_infos_to_send);
71 void _printItem(ItemInternal* ii,std::ostream& o);
72 void _exchangeCells(HashTableMapT<Int32,SharedArray<Int32>>& cells_to_send,bool with_flags);
73};
74
75/*---------------------------------------------------------------------------*/
76/*---------------------------------------------------------------------------*/
77//TOTO A definir ailleurs
79{
80 public:
81 NodeUidToSubDomain(Int64 max_uid,Int32 nb_rank);
82
83 Int32 uidToRank(Int64 uid)
84 {
85 Int32 rank = (Int32)(uid / m_nb_by_rank);
86 if (rank>=m_nb_rank)
87 --rank;
88 Int32 nrank = rank % m_modulo;
89 return nrank;
90 }
91 Int32 modulo() const { return m_modulo; }
92
93 private:
94
95 Int32 m_nb_rank;
96 Int32 m_modulo;
97 Int64 m_nb_by_rank;
98};
99
100/*---------------------------------------------------------------------------*/
101/*---------------------------------------------------------------------------*/
102
103} // End namespace Arcane::mesh
104
105/*---------------------------------------------------------------------------*/
106/*---------------------------------------------------------------------------*/
107
108#endif
Table de hachage pour tableaux associatifs.
Echange d'informations entre processeurs.
Structure interne d'une entité de maillage.
Lecteur des fichiers de maillage via la bibliothèque LIMA.
Definition Lima.cc:120
Construction d'un maillage de manière incrémentale.
Implémentation d'un maillage.
Definition DynamicMesh.h:97
Construction des couches fantômes.
Tableau associatif de ItemInternal.
-*- tab-width: 2; indent-tabs-mode: nil; coding: utf-8-with-signature -*-