Skip to content

Commit ada5eb5

Browse files
committed
make stencil_width a static constexpr member of NCIfilter
1 parent 1b75fb7 commit ada5eb5

File tree

2 files changed

+3
-1
lines changed

2 files changed

+3
-1
lines changed

Source/Filter/NCIGodfreyFilter.H

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -17,6 +17,8 @@ public:
1717

1818
void getGodfreyCoeffs(godfrey_coeff_set coeff_set_in);
1919

20+
static constexpr int stencil_width = 4;
21+
2022
private:
2123

2224
godfrey_coeff_set coeff_set;

Source/WarpX.cpp

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -633,7 +633,7 @@ WarpX::AllocLevelData (int lev, const BoxArray& ba, const DistributionMapping& d
633633
int ngz_nonci = (ngz_tmp % 2) ? ngz_tmp+1 : ngz_tmp; // Always even number
634634
int ngz;
635635
if (WarpX::use_fdtd_nci_corr) {
636-
int ng = ngz_tmp + 4;
636+
int ng = ngz_tmp + NCIGodfreyFilter::stencil_width;
637637
ngz = (ng % 2) ? ng+1 : ng;
638638
} else {
639639
ngz = ngz_nonci;

0 commit comments

Comments
 (0)