Arcane  v4.1.4.0
Documentation développeur
Chargement...
Recherche...
Aucune correspondance
AMRZonePosition.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/* AMRZonePosition.h (C) 2000-2026 */
9/* */
10/* Definition d'une zone 2D ou 3D d'un maillage. */
11/*---------------------------------------------------------------------------*/
12#ifndef ARCANE_CARTESIANMESH_AMRBOXPOSITION_H
13#define ARCANE_CARTESIANMESH_AMRBOXPOSITION_H
14/*---------------------------------------------------------------------------*/
15/*---------------------------------------------------------------------------*/
16
17#include "arcane/cartesianmesh/CartesianMeshGlobal.h"
18#include "arcane/utils/Real3.h"
19#include "arcane/core/VariableTypes.h"
20
21/*---------------------------------------------------------------------------*/
22/*---------------------------------------------------------------------------*/
23
24namespace Arcane
25{
26
27/*---------------------------------------------------------------------------*/
28/*---------------------------------------------------------------------------*/
29
34class ARCANE_CARTESIANMESH_EXPORT AMRZonePosition
35{
36 public:
37
44 : m_position(position)
45 , m_length(length)
46 , m_is_3d(true)
47 {}
48
55 : m_position(position)
56 , m_length(length)
57 , m_is_3d(false)
58 {}
59
60 public:
61
67 {
68 return m_position;
69 }
70
75 Real3 length() const
76 {
77 return m_length;
78 }
79
84 bool is3d() const
85 {
86 return m_is_3d;
87 }
88
95 void cellsInPatch(IMesh* mesh, UniqueArray<Int32>& cells_local_id) const;
96
105 void cellsInPatch(ICartesianMesh* mesh, UniqueArray<Int32>& cells_local_id, AMRPatchPosition& position) const;
106
117 AMRPatchPosition toAMRPatchPosition(ICartesianMesh* mesh) const;
118
119 private:
120
121 Real3 m_position;
122 Real3 m_length;
123 bool m_is_3d;
124};
125
126/*---------------------------------------------------------------------------*/
127/*---------------------------------------------------------------------------*/
128
129} // End namespace Arcane
130
131/*---------------------------------------------------------------------------*/
132/*---------------------------------------------------------------------------*/
133
134#endif
Classe permettant de définir la position d'un patch dans le maillage cartésien.
Real3 length() const
Méthode permettant de retrouver la taille de la zone.
bool is3d() const
Méthode permettant de savoir si c'est une zone 2D ou 3D.
AMRZonePosition(const Real3 &position, const Real3 &length)
Constructeur de zone 3D.
Real3 position() const
Méthode permettant de retrouver la position de la zone.
AMRZonePosition(const Real2 &position, const Real2 &length)
Constructeur de zone 2D.
Interface d'un maillage cartésien.
Classe gérant un vecteur de réel de dimension 2.
Definition Real2.h:121
Classe gérant un vecteur de réel de dimension 3.
Definition Real3.h:132
Vecteur 1D de données avec sémantique par valeur (style STL).
-*- tab-width: 2; indent-tabs-mode: nil; coding: utf-8-with-signature -*-