fixed bug in reprep when sit had surface species. Added capability of sit + edl, have not tested it

This commit is contained in:
David Parkhurst 2021-05-10 13:36:52 -06:00
parent 79956e3d9f
commit 2212f9ccb1
3 changed files with 5 additions and 3 deletions

View File

@ -1398,6 +1398,7 @@ protected:
*---------------------------------------------------------------------- */ *---------------------------------------------------------------------- */
std::vector<class unknown*> x; std::vector<class unknown*> x;
size_t count_unknowns; size_t count_unknowns;
size_t sit_aqueous_unknowns;
size_t max_unknowns; size_t max_unknowns;
class unknown* ah2o_unknown; class unknown* ah2o_unknown;

View File

@ -1240,8 +1240,7 @@ build_model(void)
} }
if (dl_type_x != cxxSurface::NO_DL && (/*pitzer_model == TRUE || */sit_model == TRUE)) //DL_pitz if (dl_type_x != cxxSurface::NO_DL && (/*pitzer_model == TRUE || */sit_model == TRUE)) //DL_pitz
{ {
error_msg("-diffuse_layer option not available for Pizer or SIT model", warning_msg("-diffuse_layer option not tested for SIT model");
STOP);
} }
/* /*
* Sum diffuse layer water into hydrogen and oxygen mass balances * Sum diffuse layer water into hydrogen and oxygen mass balances
@ -1285,6 +1284,7 @@ build_model(void)
k++; k++;
count_unknowns++; count_unknowns++;
} }
sit_aqueous_unknowns = count_unknowns - j0;
} }
/* /*
* Rewrite phases to current master species * Rewrite phases to current master species

View File

@ -1117,7 +1117,8 @@ model_sit(void)
{ {
count_basis_change++; count_basis_change++;
count_unknowns -= (int)this->s_x.size(); //count_unknowns -= (int)this->s_x.size();
count_unknowns -= sit_aqueous_unknowns;
reprep(); reprep();
full_pitzer = false; full_pitzer = false;
} }