Skip to content

Commit 392dc09

Browse files
committed
BUG: ammend prev commit: IC's and BCs were missing some important cells.
1 parent 94fcdea commit 392dc09

File tree

2 files changed

+3
-3
lines changed

2 files changed

+3
-3
lines changed

src/neutrals_bcs.cpp

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -196,8 +196,8 @@ bool Neutrals::set_lower_bcs(Grid grid,
196196
// - This kind-of assumes nGCs=2, so may need to be updated.
197197
// - If the first_lower_gc is at iAlt = 1, this may cause issues.
198198
// - The equator-most (j-hat) grid cell will be entirely below min_alt!
199-
for (int iLon = nGCs; iLon < nLons - nGCs; iLon++) {
200-
for (int iLat = nGCs; iLat < nLats - nGCs; iLat++) {
199+
for (int iLon = 0; iLon < nLons; iLon++) {
200+
for (int iLat = 0; iLat < nLats; iLat++) {
201201
for (iSpecies = 0; iSpecies < nSpecies; iSpecies++) {
202202

203203
// k-index of 1st lower ghost cell is not constant on the dipole grid.

src/neutrals_ics.cpp

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -175,7 +175,7 @@ bool Neutrals::initial_conditions(Grid grid,
175175
for (iLat = 0; iLat < nLats; iLat++) {
176176
for (int iSpecies = 0; iSpecies < nSpecies; iSpecies++) {
177177
species[iSpecies].density_scgc.subcube(
178-
iLon, iLat, 0, iLon, iLat, grid.first_lower_gc(iLon, iLat)).fill(
178+
iLon, iLat, 0, iLon, iLat, grid.first_lower_gc(iLon, iLat)+1).fill(
179179
species[iSpecies].lower_bc_density);
180180
}
181181
}

0 commit comments

Comments
 (0)