TrioCFD 1.9.9_beta
TrioCFD documentation
Loading...
Searching...
No Matches
Extruder.h
1/****************************************************************************
2* Copyright (c) 2026, 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 Extruder_included
17#define Extruder_included
18
19#include <Faces_builder.h>
20#include <Interprete_geometrique_base.h>
21#include <Static_Int_Lists.h>
22#include <Domaine_forward.h>
23#include <Domaine_forward.h>
24#include <Bord.h>
25
26/*! @brief class Extruder This class is an interpreter used to read and execute
27 *
28 * the Extruder directive:
29 * Extruder domain_name
30 * This directive is intended for VEF 2D discretization to obtain
31 * a 3D mesh by extrusion followed by cutting.
32 *
33 * @sa Interprete Extruder, this class is also usable in 3D
34 */
35
36template <typename _SIZE_>
38{
39 Declare_instanciable_sans_constructeur_32_64(Extruder_32_64);
40
41public :
42 using int_t = _SIZE_;
46 using IntTab_t = IntTab_T<_SIZE_>;
47 using DoubleTab_t = DoubleTab_T<_SIZE_>;
50
52
54 inline void setDirection(double lx, double ly, double lz)
55 {
56 direction[0]=lx;
57 direction[1]=ly;
58 direction[2]=lz;
59 }
60 inline void setNbTranches(int n) { NZ = n; }
61
63
64
65protected:
69
70 ArrOfDouble direction;
71 int NZ = -10;
72
73private:
74 void traiter_faces_dvt_hexa(Faces_t&, int_t);
75 void traiter_faces_dvt(Faces_t&, Faces_t&, int_t, int_t, int_t);
76};
77
78using Extruder = Extruder_32_64<int>;
79using Extruder_64 = Extruder_32_64<trustIdType>;
80
81#endif
Class Bord This class represents a boundary of a domain, it is a type of frontier.
Definition Bord.h:31
class Domaine_32_64 A Domain is a mesh composed of a set of geometric elements of the same type.
Definition Domaine.h:62
Class defining operators and methods for all reading operation in an input flow (file,...
Definition Entree.h:42
class Extruder This class is an interpreter used to read and execute
Definition Extruder.h:38
DoubleTab_T< _SIZE_ > DoubleTab_t
Definition Extruder.h:47
void setNbTranches(int n)
Definition Extruder.h:60
Faces_builder_32_64< _SIZE_ > Faces_builder_t
Definition Extruder.h:48
void setDirection(double lx, double ly, double lz)
Definition Extruder.h:54
Faces_32_64< _SIZE_ > Faces_t
Definition Extruder.h:44
ArrOfDouble direction
Definition Extruder.h:70
Bord_32_64< _SIZE_ > Bord_t
Definition Extruder.h:45
IntTab_T< _SIZE_ > IntTab_t
Definition Extruder.h:46
Static_Int_Lists_32_64< _SIZE_ > Static_Int_Lists_t
Definition Extruder.h:49
Domaine_32_64< _SIZE_ > Domaine_t
Definition Extruder.h:43
Entree & interpreter_(Entree &) override
Main function of the Extruder interpreter. Extrudes the domain.
Definition Extruder.cpp:51
virtual void extruder_dvt_hexa(Domaine_t &, Faces_t &, int_t, int_t)
Definition Extruder.cpp:581
virtual void extruder_dvt(Domaine_t &, Faces_t &, int_t, int_t)
Definition Extruder.cpp:383
void extruder(Domaine_t &)
Extrudes all elements of a domain: transforms the geometric elements of the domain into 3D elements.
Definition Extruder.cpp:86
_SIZE_ int_t
Definition Extruder.h:42
void extruder_hexa(Domaine_t &)
Definition Extruder.cpp:443
Class Faces Faces describes a set of faces by their type (point, segment, triangle or quadrangle),...
Definition Faces.h:50
Helper class for building the faces of a domain. (used only to create the arrays of real faces).
Class Interprete_geometrique_base.
This class allows storing lists of integers accessible in constant time.