1 #include "../coordinates/coordinates.hpp"
2 #include "../globals.hpp"
3 #include "../thermodynamics/thermodynamics.hpp"
10 long_name =
"horizontally averaged mass flux,";
11 units =
"kg/(m^2.s),";
13 for (
int n = 1; n <= NVAPOR; ++n) {
14 varname +=
"v1q" + std::to_string(n) +
",";
15 units +=
"kg/(kg.m^2.s),";
16 long_name +=
"horizontally averaged vapor mass flux,";
18 for (
int n = 0; n < 3; ++n) {
20 varname +=
"v1v" + std::to_string(n + 1) +
",";
21 long_name +=
"horizontally averaged momentum flux,";
25 long_name +=
"horizontally averaged heat flux";
35 int is = pmb->is, js = pmb->js, ks = pmb->ks;
36 int ie = pmb->ie, je = pmb->je, ke = pmb->ke;
41 for (
int k = ks; k <= ke; ++k)
42 for (
int j = js;
j <= je; ++
j) {
43 pcoord->CellVolume(k,
j, is, ie,
vol_);
44 for (
int i = is; i <= ie; ++i) {
45 data(0, i) +=
vol_(i) * w(IDN, k,
j, i) * w(IVX, k,
j, i);
46 for (
int n = 1; n < IPR; ++n)
47 data(n, i) +=
vol_(i) * w(n, k,
j, i) * w(IVX, k,
j, i);
63 for (
int n = 0; n < NHYDRO; ++n)
64 for (
int i = pmb->is; i <= pmb->ie; ++i)
void gatherAllData23_(AthenaArray< Real > &total_vol, AthenaArray< Real > &total_data)
AthenaArray< Real > total_vol_
void Progress(AthenaArray< Real > const &w)
HydroFlux(MeshBlock *pmb)
void Finalize(AthenaArray< Real > const &w)
Real GetTemp(MeshBlock const *pmb, int k, int j, int i) const
Calculate temperature from primitive variable.