16#include <OpConvCentre2IJK.h>
17#include <Perf_counters.h>
20OpConvCentre2IJK_double::OpConvCentre2IJK_double()
55 const ArrOfDouble_with_ghost& delta_z,
bool is_z_component,
bool is_z_periodic)
58 for (
int i = 0; i < nb_values; i++)
60 if ((!is_z_periodic) && (i + offset < istart || i + offset > iend))
81 d1 = (delta_z[i-2] + delta_z[i-1]) * 0.5;
82 d2 = (delta_z[i-1] + delta_z[i]) * 0.5;
83 d3 = (delta_z[i] + delta_z[i+1]) * 0.5;
85 calcul_g(d1, d2, d3, g(i,0), g(i,1), g(i,2), g(i,3));
100 const int offset_to_global_k_layer =
channel_data_.offset_to_global_k_layer();
101 const ArrOfDouble_with_ghost& delta_z =
channel_data_.get_delta_z();
108 istart =
channel_data_.first_global_k_layer_flux(0 , 2 ) + 1;
112 istart =
channel_data_.first_global_k_layer_flux(2 , 2 ) + 1;
118 const IJK_Field_double& vx,
const IJK_Field_double& vy,
const IJK_Field_double& vz,
119 IJK_Field_double& dvx, IJK_Field_double& dvy, IJK_Field_double& dvz)
128 const IJK_Field_double& vx,
const IJK_Field_double& vy,
const IJK_Field_double& vz,
129 IJK_Field_double& dvx, IJK_Field_double& dvy, IJK_Field_double& dvz)
139void OpConvCentre2IJK_double::calculer_div_rhou(
const IJK_Field_double& rhovx,
const IJK_Field_double& rhovy,
const IJK_Field_double& rhovz,
142 statistics().begin_count(STD_COUNTERS::convection,statistics().get_last_opened_counter_level()+1);
146 const int ni = resu.
ni();
147 const int nj = resu.
nj();
149 for (
int j = -1; j < nj; j++)
150 for (
int i = -1; i < ni; i++)
153 (rhovx(i+1,j,k_layer) - rhovx(i,j,k_layer)) * surface_x
154 + (rhovy(i,j+1,k_layer) - rhovy(i,j,k_layer)) * surface_y
155 + (rhovz(i,j,k_layer+1) - rhovz(i,j,k_layer)) * surface_z;
156 resu(i,j,k_layer) = divergence;
158 statistics().
end_count(STD_COUNTERS::convection);
163 const IJK_Field_double& vx,
const IJK_Field_double& vy,
const IJK_Field_double& vz,
164 IJK_Field_double& dvx, IJK_Field_double& dvy, IJK_Field_double& dvz,
165 IJK_Field_double& div_rho_u)
167 statistics().begin_count(STD_COUNTERS::convection,statistics().get_last_opened_counter_level()+1);
183 statistics().end_count(STD_COUNTERS::convection);
188 const IJK_Field_double& vx,
const IJK_Field_double& vy,
const IJK_Field_double& vz,
189 IJK_Field_double& dvx, IJK_Field_double& dvy, IJK_Field_double& dvz,
190 IJK_Field_double& div_rho_u)
192 statistics().begin_count(STD_COUNTERS::convection,statistics().get_last_opened_counter_level()+1);
208 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.
DoubleTab g_compo_xy_dir_z_
DoubleTab g_compo_z_dir_z_
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
int last_computed_klayer_for_div_rhou_
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 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)
void initialize(const Domaine_IJK &splitting) override
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)
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
void calcul_g(const double &dxam, const double &dx, const double &dxav, double &g1, double &g2, double &g3, double &g4)
IJK_Field_double * div_rho_u_
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_
void end_count(const std::string &custom_count_name, int count_increment=1, long int quantity_increment=0)
End the count of a counter and update the counter values.
Classe de base des flux de sortie.
void resize(_SIZE_ n, RESIZE_OPTIONS opt=RESIZE_OPTIONS::COPY_INIT)