16#include <OpConvCentre4IJK.h>
17#include <Perf_counters.h>
21OpConvCentre4IJK_double::OpConvCentre4IJK_double()
39 g1 = -dx*dx*(dx/2+dxav)/(4*(dx+dxam+dxav)*(dx+dxam)*dxam);
40 g2 = (dx+2*dxam)*(dx+2*dxav)/(8*dxam*(dx+dxav));
41 g3 = (dx+2*dxam)*(dx+2*dxav)/(8*dxav*(dx+dxam));
42 g4 = -dx*dx*(dx/2+dxam)/(4*(dx+dxam+dxav)*dxav*(dx+dxav));
54 const ArrOfDouble_with_ghost& delta_z,
bool is_z_component,
bool is_z_periodic)
57 for (
int i = 0; i < nb_values; i++)
59 if ((!is_z_periodic) && (i + offset < istart || i + offset > iend))
80 d1 = (delta_z[i-2] + delta_z[i-1]) * 0.5;
81 d2 = (delta_z[i-1] + delta_z[i]) * 0.5;
82 d3 = (delta_z[i] + delta_z[i+1]) * 0.5;
84 calcul_g(d1, d2, d3, g(i,0), g(i,1), g(i,2), g(i,3));
99 const int offset_to_global_k_layer =
channel_data_.offset_to_global_k_layer();
100 const ArrOfDouble_with_ghost& delta_z =
channel_data_.get_delta_z();
107 istart =
channel_data_.first_global_k_layer_flux(0 , 2 ) + 1;
111 istart =
channel_data_.first_global_k_layer_flux(2 , 2 ) + 1;
119 const IJK_Field_double& vx,
const IJK_Field_double& vy,
const IJK_Field_double& vz,
120 IJK_Field_double& dvx, IJK_Field_double& dvy, IJK_Field_double& dvz)
127 const IJK_Field_double& vx,
const IJK_Field_double& vy,
const IJK_Field_double& vz,
128 IJK_Field_double& dvx, IJK_Field_double& dvy, IJK_Field_double& dvz)
138void OpConvCentre4IJK_double::calculer_div_rhou(
const IJK_Field_double& rhovx,
const IJK_Field_double& rhovy,
const IJK_Field_double& rhovz,
144 const int ni = resu.
ni();
145 const int nj = resu.
nj();
147 for (
int j = -1; j < nj; j++)
148 for (
int i = -1; i < ni; i++)
151 (rhovx(i+1,j,k_layer) - rhovx(i,j,k_layer)) * surface_x
152 + (rhovy(i,j+1,k_layer) - rhovy(i,j,k_layer)) * surface_y
153 + (rhovz(i,j,k_layer+1) - rhovz(i,j,k_layer)) * surface_z;
154 resu(i,j,k_layer) = divergence;
159 const IJK_Field_double& vx,
const IJK_Field_double& vy,
const IJK_Field_double& vz,
160 IJK_Field_double& dvx, IJK_Field_double& dvy, IJK_Field_double& dvz,
161 IJK_Field_double& div_rho_u)
163 statistics().begin_count(STD_COUNTERS::convection,statistics().get_last_opened_counter_level()+1);
179 statistics().end_count(STD_COUNTERS::convection);
184 const IJK_Field_double& vx,
const IJK_Field_double& vy,
const IJK_Field_double& vz,
185 IJK_Field_double& dvx, IJK_Field_double& dvy, IJK_Field_double& dvz,
186 IJK_Field_double& div_rho_u)
188 statistics().begin_count(STD_COUNTERS::convection,statistics().get_last_opened_counter_level()+1);
204 statistics().end_count(STD_COUNTERS::convection);
This class encapsulates all the information related to the eulerian mesh for TrioIJK.
int get_nb_faces_local(int compo, int direction) const
Returns the number, in requested direction, of faces that are oriented in direction of "compo".
Class defining operators and methods for all reading operation in an input flow (file,...
virtual Entree & readOn(Entree &)
Lecture d'un Objet_U sur un flot d'entree Methode a surcharger.
virtual Sortie & printOn(Sortie &) const
Ecriture de l'objet sur un flot de sortie Methode a surcharger.
void calcul_g(const double &dxam, const double &dx, const double &dxav, double &g1, double &g2, double &g3, double &g4)
void calculer_avec_u_div_rhou(const IJK_Field_double &rhovx, const IJK_Field_double &rhovy, const IJK_Field_double &rhovz, const IJK_Field_double &vx, const IJK_Field_double &vy, const IJK_Field_double &vz, IJK_Field_double &dvx, IJK_Field_double &dvy, IJK_Field_double &dvz, IJK_Field_double &div_rho_u) override
void ajouter(const IJK_Field_double &inputx, const IJK_Field_double &inputy, const IJK_Field_double &inputz, const IJK_Field_double &vx, const IJK_Field_double &vy, const IJK_Field_double &vz, IJK_Field_double &dvx, IJK_Field_double &dvy, IJK_Field_double &dvz)
IJK_Field_double * div_rho_u_
DoubleTab g_compo_xy_dir_z_
void fill_g_compo(DoubleTab &g, int nb_values, int offset, int istart, int iend, const ArrOfDouble_with_ghost &delta_z, bool is_z_component, bool is_z_periodic)
void initialize(const Domaine_IJK &splitting) override
void ajouter_avec_u_div_rhou(const IJK_Field_double &rhovx, const IJK_Field_double &rhovy, const IJK_Field_double &rhovz, const IJK_Field_double &vx, const IJK_Field_double &vy, const IJK_Field_double &vz, IJK_Field_double &dvx, IJK_Field_double &dvy, IJK_Field_double &dvz, IJK_Field_double &div_rho_u) override
DoubleTab g_compo_z_dir_z_
void calculer(const IJK_Field_double &inputx, const IJK_Field_double &inputy, const IJK_Field_double &inputz, const IJK_Field_double &vx, const IJK_Field_double &vy, const IJK_Field_double &vz, IJK_Field_double &dvx, IJK_Field_double &dvy, IJK_Field_double &dvz)
int last_computed_klayer_for_div_rhou_
double get_delta_y() const
double get_delta_x() const
const ArrOfDouble_with_ghost & get_delta_z() const
void compute_set(IJK_Field_double &dvx, IJK_Field_double &dvy, IJK_Field_double &dvz)
void compute_add(IJK_Field_double &dvx, IJK_Field_double &dvy, IJK_Field_double &dvz)
void ajouter(const IJK_Field_double &inputx, const IJK_Field_double &inputy, const IJK_Field_double &inputz, const IJK_Field_double &vx, const IJK_Field_double &vy, const IJK_Field_double &vz, IJK_Field_double &dvx, IJK_Field_double &dvy, IJK_Field_double &dvz)
Operateur_IJK_data_channel channel_data_
const IJK_Field_double * inputy_
virtual void initialize(const Domaine_IJK &splitting)
const IJK_Field_double * inputz_
const IJK_Field_double * vz_
void calculer(const IJK_Field_double &inputx, const IJK_Field_double &inputy, const IJK_Field_double &inputz, const IJK_Field_double &vx, const IJK_Field_double &vy, const IJK_Field_double &vz, IJK_Field_double &dvx, IJK_Field_double &dvy, IJK_Field_double &dvz)
const IJK_Field_double * vy_
const IJK_Field_double * vx_
const IJK_Field_double * inputx_
Classe de base des flux de sortie.
void resize(_SIZE_ n, RESIZE_OPTIONS opt=RESIZE_OPTIONS::COPY_INIT)