TrioCFD 1.9.8
TrioCFD documentation
Loading...
Searching...
No Matches
Sources.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 Sources_included
17#define Sources_included
18
19#include <TRUST_List.h>
20#include <Source.h>
21
22/*! @brief class Sources Sources represente une liste de Source.
23 *
24 * Une equation contient un membres Equation_base::les_sources de type
25 * Sources. Un objet Sources est un morceaux d'equation, cette classe
26 * herite donc de MorEqn.
27 *
28 * @sa Source MorEqn
29 */
30class Sources : public LIST(Source), public MorEqn
31{
32 Declare_instanciable(Sources);
33
34public:
35 DoubleTab& ajouter(DoubleTab& ) const;
36 DoubleTab& calculer(DoubleTab& ) const;
37 void contribuer_jacobienne(Matrice_Bloc& matrice, int n) const;
38 void mettre_a_jour(double temps);
39 void resetTime(double temps);
40 void completer();
41 void dimensionner(Matrice_Morse&) const;
42 void contribuer_a_avec(const DoubleTab&, Matrice_Morse&) const;
43 //void contribuer_au_second_membre(DoubleTab& ) const ;
44 virtual void associer_champ_rho(const Champ_base& champ_rho);
45 virtual int a_pour_Champ_Fonc(const Motcle& mot,
46 OBS_PTR(Champ_base)& ch_ref) const;
47 int impr(Sortie&) const;
48 int initialiser(double temps);
49 void check_multiphase_compatibility() const override;
50};
51
52#endif
classe Champ_base Cette classe est la base de la hierarchie des champs.
Definition Champ_base.h:43
Classe Matrice_Morse Represente une matrice M (creuse), non necessairement carree.
classe MorEqn Classe qui regroupe les fonctionnalites de liaison avec une
Definition MorEqn.h:35
OBS_PTR(Equation_base) mon_equation
Une chaine de caractere (Nom) en majuscules.
Definition Motcle.h:26
Classe de base des flux de sortie.
Definition Sortie.h:52
class Sources Sources represente une liste de Source.
Definition Sources.h:31
void contribuer_jacobienne(Matrice_Bloc &matrice, int n) const
Definition Sources.cpp:211
int impr(Sortie &) const
Appelle Source::impr() sur toutes les sources de la liste.
Definition Sources.cpp:176
void contribuer_a_avec(const DoubleTab &, Matrice_Morse &) const
contribution a la matrice implicite des termes sources par defaut pas de contribution
Definition Sources.cpp:201
int initialiser(double temps)
Appelle Source::initialiser(temps) sur toutes les sources de la liste.
Definition Sources.cpp:226
void resetTime(double temps)
Rest all sources to a given time See ProblemeTrio::resetTime().
Definition Sources.cpp:117
void mettre_a_jour(double temps)
Mise a jour en temps, de toute les sources de la liste.
Definition Sources.cpp:109
virtual int a_pour_Champ_Fonc(const Motcle &mot, OBS_PTR(Champ_base)&ch_ref) const
Pour chaque source de la liste, appel a a_pour_Champ_Fonc(mot,ch_ref).
Definition Sources.cpp:154
void check_multiphase_compatibility() const override
Definition Sources.cpp:234
void dimensionner(Matrice_Morse &) const
Dimensionnement de la matrice implicite des termes sources.
Definition Sources.cpp:187
void completer()
Appelle Source::completer() sur toutes les sources de la liste.
Definition Sources.cpp:127
virtual void associer_champ_rho(const Champ_base &champ_rho)
Pour chaque source de la liste, appel a associer_champ_rho de la source.
Definition Sources.cpp:139
DoubleTab & ajouter(DoubleTab &) const
Ajoute la contribution de toutes les sources de la liste au tableau passe en parametre,...
Definition Sources.cpp:85
DoubleTab & calculer(DoubleTab &) const
Calcule la contribution de toutes les sources de la liste stocke le resultat dans le tableau passe en...
Definition Sources.cpp:98