1 #ifndef AMREX_FILFC_1D_C_H_
2 #define AMREX_FILFC_1D_C_H_
3 #include <AMReX_Config.H>
15 const int dcomp,
const int numcomp,
16 Box const& domain_box,
const BCRec* bcr,
17 const int bcomp)
const noexcept
22 const auto& domain_lo = domain_box.loVect();
23 const auto& domain_hi = domain_box.hiVect();
24 const int ilo = domain_lo[0];
25 const int ihi = domain_hi[0];
27 for (
int n = dcomp; n < numcomp+dcomp; ++n)
29 const BCRec& bc = bcr[bcomp+n-dcomp];
34 if (bc.
lo(0) == BCType::reflect_odd) {
41 case (BCType::foextrap):
43 q(i,0,0,n) = q(ilo,0,0,n);
46 case (BCType::hoextrap):
50 q(i,0,0,n) = q(ilo,0,0,n);
55 q(i,0,0,n) = Real(2.0)*q(i+1,0,0,n) - q(i+2,0,0,n);
59 case (BCType::reflect_even):
61 q(i,0,0,n) = q(2*ilo-i,0,0,n);
64 case (BCType::reflect_odd):
66 q(i,0,0,n) = -q(2*ilo-i,0,0,n);
75 if (bc.
hi(0) == BCType::reflect_odd) {
82 case (BCType::foextrap):
84 q(i,0,0,n) = q(ihi,0,0,n);
87 case (BCType::hoextrap):
91 q(i,0,0,n) = q(ihi,0,0,n);
96 q(i,0,0,n) = Real(2.0)*q(i-1,0,0,n) - q(i-2,0,0,n);
100 case (BCType::reflect_even):
102 q(i,0,0,n) = q(2*ihi-i,0,0,n);
105 case (BCType::reflect_odd):
107 q(i,0,0,n) = -q(2*ihi-i,0,0,n);
#define AMREX_FORCE_INLINE
Definition: AMReX_Extension.H:119
#define AMREX_GPU_HOST_DEVICE
Definition: AMReX_GpuQualifiers.H:20
Boundary Condition Records. Necessary information and functions for computing boundary conditions.
Definition: AMReX_BCRec.H:17
AMREX_GPU_HOST_DEVICE AMREX_FORCE_INLINE const int * hi() const &noexcept
Return high-end boundary data.
Definition: AMReX_BCRec.H:106
AMREX_GPU_HOST_DEVICE AMREX_FORCE_INLINE const int * lo() const &noexcept
Return low-end boundary data.
Definition: AMReX_BCRec.H:100
Definition: AMReX_Amr.cpp:49
Definition: AMReX_Array4.H:61
Definition: AMReX_FilFC_1D_C.H:12
AMREX_GPU_HOST_DEVICE AMREX_FORCE_INLINE void operator()(const IntVect &iv, Array4< Real > const &q, const int dcomp, const int numcomp, Box const &domain_box, const BCRec *bcr, const int bcomp) const noexcept
Definition: AMReX_FilFC_1D_C.H:14