TrioCFD 1.9.8
TrioCFD documentation
Loading...
Searching...
No Matches
Traitement_particulier_Solide_canal.cpp
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#include <Traitement_particulier_Solide_canal.h>
17#include <Periodique.h>
18#include <Champ_Uniforme.h>
19#include <EcrFicCollecteBin.h>
20#include <TRUSTTrav.h>
21#include <Conduction.h>
22#include <Probleme_base.h>
23
24Implemente_base(Traitement_particulier_Solide_canal,"Traitement_particulier_Solide_canal",Traitement_particulier_Solide_base);
25
26
28{
29 return is;
30}
31
32
34{
35 return is;
36}
37
39{
40
41 // FIN Initialisation
42 Motcle accouverte = "{" , accfermee = "}" ;
43 Motcle motbidon, motlu;
44 is >> motbidon ;
45 if (motbidon == accouverte)
46 {
47 Motcles les_mots(3);
48 les_mots[0] = "u_inst";
49 les_mots[1] = "stats";
50 les_mots[2] = "nb_points";
51
52 is >> motlu;
53 while(motlu != accfermee)
54 {
55 int rang=les_mots.search(motlu);
56 switch(rang)
57 {
58 case 0 :
59 {
60 // Pour spat, ex u_inst
61 is >> dt_post_inst; // intervalle de temps de sorties des moyennes spatiales
62 // initialisation pour le calcul des stats spat.
63 Cerr << "Spatial average parameters read..." << finl;
64 Cerr << "dt_post_inst : " << dt_post_inst << finl;
65 break;
66 }
67 case 1 :
68 {
69 // Pour stats
70 is >> temps_deb; // temps de debut de calcul des stats temp.
71 is >> temps_fin; // temps de fin de calcul des stats temp.
72 is >> dt_post_stat; // intervalle de temps de sorties des stats temp.
73 // initialisation pour le calcul des stats temp.
74 Cerr << "Reading time statitics parameters..." << finl;
75 Cerr << "Initial time : " << temps_deb << " End time : " << temps_fin << finl;
76 Cerr << "Time interval for output : " << dt_post_stat << finl;
77 // Verif ensuite pour voir si on a rentrer les valeurs specifiques aux calculs des stats spat.
78 break;
79 }
80 case 2 :
81 {
82 is >> N ;
83 Cerr << "Number of points estimated in the solid for profiles : " << N << finl;
84 break;
85 }
86 }
87 is >> motlu;
88 }
89 is >> motlu;
90 if (motlu != accfermee)
91 {
92 Cerr << "Error while reading in Traitement_particulier_Solide_canal" << finl;;
93 Cerr << "We were expecting a }" << finl;
94 exit();
95 }
96 }
97 else
98 {
99 Cerr << "Error while reading in Traitement_particulier_Solide_canal" << finl;
100 Cerr << "We were expecting a {" << finl;
101 exit();
102 }
103
104 return is;
105}
106
107
108
114
116{
117 /* Equation_base& eqn=mon_equation.valeur();
118 const Discretisation_base& discr=eqn.discretisation();
119 Nom nom_discr=discr.que_suis_je();
120 if(nom_discr=="VEFPreP1B" || nom_discr=="VEF")
121 {
122 N=20;
123 val_moy_temp.resize(N,N);
124 val_moy_temp=0.;
125 }
126 else
127 {*/
128
129 Tmoy_temp.resize(N);
130 Tmoy_temp=0;
131 T2_moy_temp.resize(N);
132 T2_moy_temp=0;
133
134 // }
135}
136
Class defining operators and methods for all reading operation in an input flow (file,...
Definition Entree.h:42
Une chaine de caractere (Nom) en majuscules.
Definition Motcle.h:26
Un tableau d'objets de la classe Motcle.
Definition Motcle.h:63
int search(const Motcle &t) const
Definition Motcle.cpp:321
friend class Entree
Definition Objet_U.h:76
virtual Entree & readOn(Entree &)
Lecture d'un Objet_U sur un flot d'entree Methode a surcharger.
Definition Objet_U.cpp:293
virtual Sortie & printOn(Sortie &) const
Ecriture de l'objet sur un flot de sortie Methode a surcharger.
Definition Objet_U.cpp:282
static void exit(int exit_code=-1)
Routine de sortie de TRUST dans une region Kokkos.
Definition Process.cpp:455
Classe de base des flux de sortie.
Definition Sortie.h:52
classe Traitement_particulier_Solide_base
classe Traitement_particulier_Solide_canal