For getting mixing ratios of a particular species, we sometimes use the index information twice. For example the following code in src/mam4xx/hetfrz.hpp:
const int accum_idx = int(ModeIndex::Accumulation);
const int pcarbon_idx = int(ModeIndex::PrimaryCarbon);
auto &accum_bc = progs.q_aero_i[accum_idx][aerosol_index_for_mode(ModeIndex::Accumulation, AeroId::BC)];
The code above uses ModeIndex::Accumulation twice. We should look into ways to avoid its repeated use.
For getting mixing ratios of a particular species, we sometimes use the index information twice. For example the following code in
src/mam4xx/hetfrz.hpp
:The code above uses
ModeIndex::Accumulation
twice. We should look into ways to avoid its repeated use.