12#ifndef ARCANE_CORE_MESHUTILS_H 
   13#define ARCANE_CORE_MESHUTILS_H 
   17#include "arcane/utils/FunctorUtils.h" 
   20#include "arcane/core/Item.h" 
   41namespace Arcane::MeshUtils
 
   43extern "C++" ARCANE_CORE_EXPORT 
void 
   44writeMeshItemInfo(ISubDomain*, 
Cell cell, 
bool depend_info = 
true);
 
   45extern "C++" ARCANE_CORE_EXPORT 
void 
   46writeMeshItemInfo(ISubDomain*, Node node, 
bool depend_info = 
true);
 
   47extern "C++" ARCANE_CORE_EXPORT 
void 
   48writeMeshItemInfo(ISubDomain*, Edge edge, 
bool depend_info = 
true);
 
   49extern "C++" ARCANE_CORE_EXPORT 
void 
   50writeMeshItemInfo(ISubDomain*, Face face, 
bool depend_info = 
true);
 
   72extern "C++" ARCANE_CORE_EXPORT 
bool 
   75extern "C++" ARCANE_CORE_EXPORT 
bool 
  102extern "C++" ARCANE_CORE_EXPORT 
bool 
  117extern "C++" ARCANE_CORE_EXPORT 
Face 
  120ARCANE_DEPRECATED_REASON(
"Y2025: Use getFaceFromNodesLocalId() instead")
 
  139extern "C++" ARCANE_CORE_EXPORT 
Face 
  142ARCANE_DEPRECATED_REASON(
"Y2025: Use getFaceFromNodesUniqueId() instead")
 
  146  return getFaceFromNodesUniqueId(node, face_nodes_unique_id);
 
  154extern "C++" ARCANE_CORE_EXPORT Int64
 
  155generateHashUniqueId(SmallSpan<const Int64> nodes_unique_id);
 
  167extern "C++" ARCANE_CORE_EXPORT 
void 
  183extern "C++" ARCANE_CORE_EXPORT 
void 
  184checkMeshProperties(IMesh* mesh, 
bool is_sorted, 
bool has_no_hole, 
bool check_faces);
 
  192extern "C++" ARCANE_CORE_EXPORT 
void 
  193writeMeshInfosSorted(IMesh* mesh, 
const String& file_name);
 
  195extern "C++" ARCANE_CORE_EXPORT 
void 
  196writeMeshInfos(IMesh* mesh, 
const String& file_name);
 
  203extern "C++" ARCANE_CORE_EXPORT 
void 
  204writeMeshConnectivity(IMesh* mesh, 
const String& file_name);
 
  206extern "C++" ARCANE_CORE_EXPORT 
void 
  207checkMeshConnectivity(IMesh* mesh, 
const XmlNode& root_node, 
bool check_sub_domain);
 
  209extern "C++" ARCANE_CORE_EXPORT 
void 
  210checkMeshConnectivity(IMesh* mesh, 
const String& file_name, 
bool check_sub_domain);
 
  217extern "C++" ARCANE_CORE_EXPORT 
void 
  218printItems(std::ostream& ostr, 
const String& name, ItemGroup item_group);
 
  228extern "C++" ARCANE_CORE_EXPORT Int64
 
  229printMeshGroupsMemoryUsage(IMesh* mesh, Int32 print_level);
 
  232extern "C++" ARCANE_CORE_EXPORT 
void 
  233shrinkMeshGroups(IMesh* mesh);
 
  241extern "C++" ARCANE_CORE_EXPORT 
void 
  242dumpSynchronizerTopologyJSON(IVariableSynchronizer* var_syncer, 
const String& filename);
 
  248extern "C++" ARCANE_CORE_EXPORT 
void 
  249computeConnectivityPatternOccurence(IMesh* mesh);
 
  269extern "C++" ARCANE_CORE_EXPORT 
void 
  270markMeshConnectivitiesAsMostlyReadOnly(IMesh* mesh, RunQueue* q = 
nullptr,
 
  271                                       bool do_prefetch = 
false);
 
  282extern "C++" ARCANE_CORE_EXPORT ItemBase
 
  283findOneItem(IItemFamily* family, Int64 unique_id);
 
  294extern "C++" ARCANE_CORE_EXPORT ItemBase
 
  295findOneItem(IItemFamily* family, ItemUniqueId unique_id);
 
  302extern "C++" ARCANE_CORE_EXPORT 
void 
  303visitGroups(IItemFamily* family, IFunctorWithArgumentT<ItemGroup&>* functor);
 
  310extern "C++" ARCANE_CORE_EXPORT 
void 
  311visitGroups(IMesh* mesh, IFunctorWithArgumentT<ItemGroup&>* functor);
 
  329template <
typename LambdaType> 
inline void 
  354template <
typename LambdaType> 
inline void 
  389template <
typename DataType> 
inline bool 
  404getMaxItemUniqueIdCollective(
IMesh* mesh);
 
  427extern "C++" ARCANE_CORE_EXPORT 
void 
  429                             const String& expected_hash, 
bool print_hash_value,
 
  437extern "C++" ARCANE_CORE_EXPORT 
void 
  449computeNodeNodeViaEdgeConnectivity(
IMesh* mesh, 
const String& connectivity_name);
 
  460computeBoundaryNodeNodeViaEdgeConnectivity(
IMesh* mesh, 
const String& connectivity_name);
 
  472extern "C++" ARCANE_CORE_EXPORT 
void 
  473computeAndSetOwnerForNodes(
IMesh* mesh);
 
  485extern "C++" ARCANE_CORE_EXPORT 
void 
  486computeAndSetOwnerForEdges(
IMesh* mesh);
 
  498extern "C++" ARCANE_CORE_EXPORT 
void 
  499computeAndSetOwnerForFaces(
IMesh* mesh);
 
  509namespace Arcane::mesh_utils
 
  514using MeshUtils::checkMeshConnectivity;
 
  515using MeshUtils::checkMeshProperties;
 
  516using MeshUtils::computeConnectivityPatternOccurence;
 
  517using MeshUtils::dumpSynchronizerTopologyJSON;
 
  518using MeshUtils::getFaceFromNodesLocal;
 
  519using MeshUtils::getFaceFromNodesUnique;
 
  520using MeshUtils::printItems;
 
  521using MeshUtils::printMeshGroupsMemoryUsage;
 
  522using MeshUtils::removeItemAndKeepOrder;
 
  523using MeshUtils::reorderNodesOfFace;
 
  524using MeshUtils::reorderNodesOfFace2;
 
  525using MeshUtils::shrinkMeshGroups;
 
  526using MeshUtils::writeMeshConnectivity;
 
  527using MeshUtils::writeMeshInfos;
 
  528using MeshUtils::writeMeshInfosSorted;
 
  529using MeshUtils::writeMeshItemInfo;
 
Fonctions de gestion mémoire et des allocateurs.
Int64 computeCapacity(Int64 size)
Calcule une capacité adaptée pour une taille de size.
bool checkResizeArray(Array< DataType > &array, Int64 new_size, bool force_resize)
Redimensionne un tableau qui est indexé par des 'ItemLocalId'.
bool reorderNodesOfFace(Int64ConstArrayView before_ids, Int64ArrayView after_ids)
Réordonne les noeuds d'une face.
void visitGroups(IItemFamily *family, IFunctorWithArgumentT< ItemGroup & > *functor)
Visite l'ensemble des groupes de family avec le functor functor.
bool reorderNodesOfFace2(Int64ConstArrayView nodes_unique_id, Int32ArrayView new_index)
Réordonne les noeuds d'une face.
Face getFaceFromNodesLocalId(Node node, Int32ConstArrayView face_nodes_local_id)
Recherche une entité face à partir des numéros locaux de ces noeuds.
Classe de base des vecteurs 1D de données.
Interface d'un fonctor avec argument mais sans valeur de retour.
Interface d'un algorithme de hashage.
Interface d'une famille d'entités.
Interface d'un service de synchronisation de variable.
Identifiant unique d'une entité.
Vue sur un vecteur d'entités.
Référence à une instance.
Chaîne de caractères unicode.
Int32 checkResizeArrayWithCapacity(Array< DataType > &array, Int64 new_size, bool force_resize)
Redimensionne un tableau en ajoutant une réserve de mémoire.
-*- tab-width: 2; indent-tabs-mode: nil; coding: utf-8-with-signature -*-
ArrayView< Int64 > Int64ArrayView
Equivalent C d'un tableau à une dimension d'entiers 64 bits.
std::int64_t Int64
Type entier signé sur 64 bits.
ConstArrayView< Int32 > Int32ConstArrayView
Equivalent C d'un tableau à une dimension d'entiers 32 bits.
ConstArrayView< Int64 > Int64ConstArrayView
Equivalent C d'un tableau à une dimension d'entiers 64 bits.
ArrayView< Int32 > Int32ArrayView
Equivalent C d'un tableau à une dimension d'entiers 32 bits.
@ Cell
Le maillage est AMR par maille.