Arcane  4.1.12.0
Developer documentation
Loading...
Searching...
No Matches
SubMeshTools.h
1// -*- tab-width: 2; indent-tabs-mode: nil; coding: utf-8-with-signature -*-
2//-----------------------------------------------------------------------------
3// Copyright 2000-2026 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/* SubMeshTools.h (C) 2000-2024 */
9/* */
10/* Algorithms specific to sub-meshing. */
11/*---------------------------------------------------------------------------*/
12#ifndef ARCANE_MESH_SUBMESHTOOLS_H
13#define ARCANE_MESH_SUBMESHTOOLS_H
14/*---------------------------------------------------------------------------*/
15/*---------------------------------------------------------------------------*/
16/*
17 * This section should eventually contain the entire specific implementation of sub-meshing
18 */
19
20#include "arcane/mesh/MeshGlobal.h"
21
22#include "arcane/utils/TraceAccessor.h"
23#include "arcane/utils/String.h"
24
25/*---------------------------------------------------------------------------*/
26/*---------------------------------------------------------------------------*/
27
28namespace Arcane
29{
30class IItemFamily;
31class IParallelMng;
32class IMesh;
33class ItemInternal;
34class Cell;
35} // namespace Arcane
36
37/*---------------------------------------------------------------------------*/
38/*---------------------------------------------------------------------------*/
39
40namespace Arcane::mesh
41{
42
43class DynamicMesh;
45
46/*---------------------------------------------------------------------------*/
47/*---------------------------------------------------------------------------*/
48
49class SubMeshTools
50: public TraceAccessor
51{
52 public:
53
54 SubMeshTools(DynamicMesh* mesh, DynamicMeshIncrementalBuilder* mesh_builder);
55 ~SubMeshTools();
56
57 public:
58
59 void removeDeadGhostCells();
60 void removeGhostMesh();
61 void removeFloatingItems();
62 void updateGhostMesh();
63 void updateGhostFamily(IItemFamily* family);
64 static void display(IMesh* mesh, const String msg = String());
65
66 private:
67
68 void _fillGhostItems(ItemFamily* family, Array<Int32>& items_local_id);
69 void _fillFloatingItems(ItemFamily* family, Array<Int32>& items_local_id);
70 void _checkValidItemOwner();
71 void _checkFloatingItems();
72
73 private:
74
75 DynamicMesh* m_mesh;
76 DynamicMeshIncrementalBuilder* m_mesh_builder;
77 IParallelMng* m_parallel_mng;
78
79 private:
80
81 void _updateGroups();
82 void _removeCell(Cell cell);
83};
84
85/*---------------------------------------------------------------------------*/
86/*---------------------------------------------------------------------------*/
87
88} // namespace Arcane::mesh
89
90/*---------------------------------------------------------------------------*/
91/*---------------------------------------------------------------------------*/
92
93#endif
Base class for 1D data vectors.
Cell of a mesh.
Definition Item.h:1300
Interface of an entity family.
Definition IItemFamily.h:83
Interface of the parallelism manager for a subdomain.
Internal structure of a mesh entity.
TraceAccessor(ITraceMng *m)
Constructs an accessor via the trace manager m.
Implementation of a mesh.
Definition DynamicMesh.h:98
void _fillGhostItems(ItemFamily *family, Array< Int32 > &items_local_id)
Fills items_Local_id with the ghost entities of the family family.
-- tab-width: 2; indent-tabs-mode: nil; coding: utf-8-with-signature --