Skip to content

Commit

Permalink
some nse_test cleaning
Browse files Browse the repository at this point in the history
quiet clang-tidy warnings
redirect convergence output into files
  • Loading branch information
zingale committed Nov 18, 2023
1 parent b720d68 commit a151e25
Show file tree
Hide file tree
Showing 2 changed files with 10 additions and 11 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -10,13 +10,13 @@ problem.u0=1.e8
problem.v0=1.e8
"

mpiexec -n 8 ${EXEC} inputs.64 ${RUNPARAMS} >& /dev/null
mpiexec -n 8 ${EXEC} inputs.128 ${RUNPARAMS} >& /dev/null
mpiexec -n 8 ${EXEC} inputs.256 ${RUNPARAMS} >& /dev/null
mpiexec -n 8 ${EXEC} inputs.64 ${RUNPARAMS} >& 64.out
mpiexec -n 8 ${EXEC} inputs.128 ${RUNPARAMS} >& 128.out
mpiexec -n 8 ${EXEC} inputs.256 ${RUNPARAMS} >& 256.out

RichardsonConvergenceTest2d.gnu.ex coarFile=nse_test_64_plt00125 mediFile=nse_test_128_plt00250 fineFile=nse_test_256_plt00500 >& nse_convergence_simple_sdc_lo.out

mpiexec -n 8 ${EXEC} inputs.512 ${RUNPARAMS} >& /dev/null
mpiexec -n 8 ${EXEC} inputs.512 ${RUNPARAMS} >& 512.out

RichardsonConvergenceTest2d.gnu.ex coarFile=nse_test_128_plt00250 mediFile=nse_test_256_plt00500 fineFile=nse_test_512_plt01000 >& nse_convergence_simple_sdc_hi.out

Expand Down
13 changes: 6 additions & 7 deletions Exec/reacting_tests/nse_test/problem_initialize_state_data.H
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,6 @@ void problem_initialize_state_data (int i, int j, int k,
Array4<Real> const& state,
const GeometryData& geomdata)
{
int coord_type = geomdata.Coord();

const Real* dx = geomdata.CellSize();
const Real* problo = geomdata.ProbLo();
Expand Down Expand Up @@ -99,18 +98,18 @@ void problem_initialize_state_data (int i, int j, int k,
// since the species are interpolated, normalize them

Real sumX = 0.0_rt;
for (int n = 0; n < NumSpec; n++) {
sumX += burn_state.xn[n];
for (auto X : burn_state.xn) {
sumX += X;
}
for (int n = 0; n < NumSpec; n++) {
burn_state.xn[n] /= sumX;
for (auto & X : burn_state.xn) {
X /= sumX;
}

#ifdef NSE_NET
state(i,j,k,UMUP) = burn_state.mu_p;
state(i,j,k,UMUN) = burn_state.mu_n;
#endif

#ifdef AUX_THERMO
burn_state.aux[AuxZero::iye] = ye;
burn_state.aux[AuxZero::iabar] = abar;
Expand Down

0 comments on commit a151e25

Please sign in to comment.