releasedExamples/AMRINS/projection/CCProjector.cpp
// -------------------------------------------------------------
// note that this function assumes all BC's on eSync have been set
// also only returns valid grad(eSync) in valid regions of grids
note that this function assumes all BC's on eSync have been set
also only returns valid grad(eSync) in valid regions of grids
note that this function assumes all BC ' s on eSync have been set also only returns valid grad ( eSync ) in valid regions of grids
void CCProjector::grad_eSync(LevelData<FArrayBox>& a_grad_eSync) const
{
  if (m_fineProjPtr != NULL)
    {
      const LevelData<FArrayBox>& fine_eSync = m_fineProjPtr->eSync();
      int nRefFine = m_fineProjPtr->nRefCrse();
      Gradient::compGradientCC(a_grad_eSync, m_eSync,  &fine_eSync,
                               m_dx, nRefFine, m_domain);
    }
  else
    {
      Gradient::levelGradientCC(a_grad_eSync, m_eSync, m_dx);
    }
}
void CCProjector :: grad_eSync ( LevelData < FArrayBox > & a_grad_eSync ) const { if ( m_fineProjPtr != NULL ) { const LevelData < FArrayBox > & fine_eSync = m_fineProjPtr -> eSync ( ) ; int nRefFine = m_fineProjPtr -> nRefCrse ( ) ; Gradient :: compGradientCC ( a_grad_eSync , m_eSync , & fine_eSync , m_dx , nRefFine , m_domain ) ; } else { Gradient :: levelGradientCC ( a_grad_eSync , m_eSync , m_dx ) ; } }
note that this function assumes all BC's on eSync have been set
also only returns valid grad(eSync) in valid regions of grids
note that this function assumes all BC ' s on eSync have been set also only returns valid grad ( eSync ) in valid regions of grids
// no finer level -- can do level-operator gradient