src/coordinates/coordinates.cpp
//----------------------------------------------------------------------------------------
// Cell Volume function: compute volume of cell as vector
Cell Volume function: compute volume of cell as vector
Cell Volume function : compute volume of cell as vector
void Coordinates::CellVolume(const int k, const int j, const int il, const int iu,
  AthenaArray<Real> &vol)
{
#pragma simd
  for (int i=il; i<=iu; ++i){
    Real& vol_i = vol(i);
    vol_i = dx1f(i)*dx2f(j)*dx3f(k);
  }
  return;
}
void Coordinates :: CellVolume ( const int k , const int j , const int il , const int iu , AthenaArray < Real > & vol ) { #pragma  simd for ( int i = il ; i <= iu ; ++ i ) { Real & vol_i = vol ( i ) ; vol_i = dx1f ( i ) * dx2f ( j ) * dx3f ( k ) ; } return ; }
Cell Volume function: compute volume of cell as vector
Cell Volume function : compute volume of cell as vector
// volume = dx dy dz