TrioCFD 1.9.8
TrioCFD documentation
Loading...
Searching...
No Matches
Rectangle_axi.h
1/****************************************************************************
2* Copyright (c) 2024, CEA
3* All rights reserved.
4*
5* Redistribution and use in source and binary forms, with or without modification, are permitted provided that the following conditions are met:
6* 1. Redistributions of source code must retain the above copyright notice, this list of conditions and the following disclaimer.
7* 2. Redistributions in binary form must reproduce the above copyright notice, this list of conditions and the following disclaimer in the documentation and/or other materials provided with the distribution.
8* 3. Neither the name of the copyright holder nor the names of its contributors may be used to endorse or promote products derived from this software without specific prior written permission.
9*
10* THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED.
11* IN NO EVENT SHALL THE COPYRIGHT HOLDER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS;
12* OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
13*
14*****************************************************************************/
15
16#ifndef Rectangle_axi_included
17#define Rectangle_axi_included
18
19#include <Rectangle.h>
20
21/*! @brief Classe Rectangle_axi Cette classe represente la deformee du rectangle dans
22 *
23 * le cas d'un maillage en coordonnees cylindriques
24 * Les methodes de la classe Rectangle dont Rectangle_axi derive sont
25 * surchargees pour effectuer les calculs en coordonnees cylindrique.
26 *
27 * @sa Rectangle Elem_geom_base Elem_geom
28 */
29template <typename _SIZE_>
31{
32
33 Declare_instanciable_32_64(Rectangle_axi_32_64);
34
35public :
36 using int_t = _SIZE_;
37 using IntTab_t = IntTab_T<_SIZE_>;
38 using SmallArrOfTID_t = SmallArrOfTID_T<_SIZE_>;
39 using DoubleVect_t = DoubleVect_T<_SIZE_>;
40 using DoubleTab_t = DoubleTab_T<_SIZE_>;
42
43
44 const Nom& nom_lml() const override;
45
46 int contient(const ArrOfDouble& pos, int_t elem) const override;
47 // Avoid hidding from mother class:
48 int contient(const SmallArrOfTID_t& soms, int_t elem) const override { return Rectangle_32_64<_SIZE_>::contient(soms, elem); }
49 inline Type_Face type_face(int=0) const override;
50 void calculer_volumes(DoubleVect_t& vols) const override;
51 void calculer_centres_gravite(DoubleTab_t& ) const override ;
52
53protected:
54 // Members herited from top classes:
56 using Elem_geom_base_32_64<_SIZE_>::mon_dom;
57
58};
59
60
61/*! @brief Renvoie le i-ieme type de face.
62 *
63 * Un rectangle (Axi) n'a qu'un seul type de face.
64 *
65 * @param (int i) le rang du type de face a renvoyer
66 * @return (Type_Face) un type de face
67 */
68template <typename _SIZE_>
69inline Type_Face Rectangle_axi_32_64<_SIZE_>::type_face(int i) const
70{
71 assert(i==0);
72 return Type_Face::segment_2D_axi;
73}
74
75
76using Rectangle_axi = Rectangle_axi_32_64<int>;
77using Rectangle_axi_64 = Rectangle_axi_32_64<trustIdType>;
78
79#endif
classe Domaine_32_64 un Domaine est un maillage compose d'un ensemble d'elements geometriques de meme...
Definition Domaine.h:62
Classe Elem_geom_base Cette classe est la classe de base pour la definition d'elements.
class Nom Une chaine de caractere pour nommer les objets de TRUST
Definition Nom.h:31
static int dimension
Definition Objet_U.h:99
Classe Rectangle Cette classe represente l'element geometrique Rectangle.
Definition Rectangle.h:31
int contient(const ArrOfDouble &pos, int_t elem) const override
Renvoie 1 si l'element ielem du domaine associe a l'element geometrique contient le point.
Classe Rectangle_axi Cette classe represente la deformee du rectangle dans.
void calculer_volumes(DoubleVect_t &vols) const override
Calcule les volumes des elements du domaine associe.
Domaine_32_64< _SIZE_ > Domaine_t
Type_Face type_face(int=0) const override
Renvoie le i-ieme type de face.
SmallArrOfTID_T< _SIZE_ > SmallArrOfTID_t
IntTab_T< _SIZE_ > IntTab_t
void calculer_centres_gravite(DoubleTab_t &) const override
Calcule les centres de gravites de tous les elements du domaine associe a l'element goemetrique.
DoubleTab_T< _SIZE_ > DoubleTab_t
int contient(const ArrOfDouble &pos, int_t elem) const override
Renvoie 1 si l'element ielem du domaine associe a l'element geometrique contient le point.
int contient(const SmallArrOfTID_t &soms, int_t elem) const override
Renvoie 1 si les sommets specifies par le parametre "pos" sont les sommets de l'element "element" du ...
DoubleVect_T< _SIZE_ > DoubleVect_t
const Nom & nom_lml() const override
Renvoie le nom LML d'un rectangle_axi = "VOXEL8".