TRUST 1.9.8
HPC thermohydraulic platform
Loading...
Searching...
No Matches
interface_INITGAUSS.cpp
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#include <TRUSTArray.h> // might include Kokkos, has to be put before arch_fort to avoid nasty re-define
16#include <interface_INITGAUSS.h>
17#include <arch_fort.h>
18#include <LecFicDiffuse.h>
19#include <Param.h>
20extern "C" {
21#ifdef F77_Majuscule
22 int F77DECLARE(INITGAUSS)(const integer* idimg, const integer* nbnn, const integer* npgau, doublereal* xgau, doublereal* frgau, doublereal* dfrgau, doublereal* poigau);
23#else
24 int F77DECLARE(initgauss)(const integer* idimg, const integer* nbnn, const integer* npgau, doublereal* xgau, doublereal* frgau, doublereal* dfrgau, doublereal* poigau);
25#endif
26}
27#ifndef F77_Majuscule
28inline int F77DECLARE(INITGAUSS)(const integer* idimg, const integer* nbnn, const integer* npgau, doublereal* xgau, doublereal* frgau, doublereal* dfrgau, doublereal* poigau)
29{
30 return F77NAME(initgauss)( idimg, nbnn, npgau, xgau, frgau, dfrgau, poigau);
31}
32#endif
33
51
55
56void interface_INITGAUSS::Compute(const int idimg, const int nbnn, const int npgau, ArrOfDouble& xgau, ArrOfDouble& frgau, ArrOfDouble& dfrgau, ArrOfDouble& poigau) const
57{
58 F77NAME(INITGAUSS)(&idimg, &nbnn, &npgau, xgau.addr(), frgau.addr(), dfrgau.addr(), poigau.addr());
59}
61{
62 LecFicDiffuse entree(nom_fic);
63 Param param("interface_INITGAUSS");
64 set_param(param);
65 param.read(entree);
66}
67
69{
70 Param param("interface_INITGAUSS");
71 set_param(param);
72 param.print(os);
73}
74
76{
77}
78
79
Cette classe implemente les operateurs et les methodes virtuelles de la classe EFichier de la facon s...
class Nom Une chaine de caractere pour nommer les objets de TRUST
Definition Nom.h:31
Helper class to factorize the readOn method of Objet_U classes.
Definition Param.h:112
void print(Sortie &s) const
Print the current state of the registered parameters as a { ... } block.
Definition Param.cpp:135
int read(Entree &is, int with_acco=1)
Low-level entry point used by lire_avec_accolades_depuis.
Definition Param.cpp:62
Classe de base des flux de sortie.
Definition Sortie.h:52
_TYPE_ * addr()
void init_from_file(const Nom &)
void Compute(const int idimg, const int nbnn, const int npgau, ArrOfDouble &xgau, ArrOfDouble &frgau, ArrOfDouble &dfrgau, ArrOfDouble &poigau) const
void set_param(Param &) const