Skip to content

Commit

Permalink
Add consistency tests for DebyeHuckel
Browse files Browse the repository at this point in the history
  • Loading branch information
speth authored and ischoegl committed Jun 10, 2022
1 parent b48bfd3 commit 97e078c
Show file tree
Hide file tree
Showing 2 changed files with 81 additions and 0 deletions.
51 changes: 51 additions & 0 deletions test/data/consistency-cases.yaml
Expand Up @@ -137,3 +137,54 @@ plasma:
- {T: 300, P: 1 atm, X: {O2: 1.0, O2-: 1e-5, E: 1e-5}}
- {T: 300, P: 1 atm, X: {E: 1.0}}
- {T: 3500, P: 10 atm, X: {O2: 1.0, O2-: 2e-5, E: 2e-5}}

debye-huckel-dilute:
setup:
file: debye-huckel-all.yaml
phase: debye-huckel-dilute
known-failures: &debye-huckel-failures
cv_eq_.+: cv not implemented
u_eq_sum_uk_Xk: partialMolarIntEnergies not implemented
hk_eq_uk_plus_P_times_vk: partialMolarIntEnergies not implemented
states: &debye-huckel-states
- {T: 300, P: 1 atm,
molalities: {Na+: 9.3549, Cl-: 9.3549, H+: 1.05e-08, OH-: 1.3765e-06,
NaCl(aq): 0.98492, NaOH(aq): 3.8836e-06, NaH3SiO4(aq): 6.8798e-05,
SiO2(aq): 3.0179e-05, H3SiO4-: 1.0231e-06}}
- {T: 300, P: 1 atm,
molalities: {Na+: 4.1, Cl-: 4.1, H+: 1.05e-07, OH-: 1.3765e-05,
NaCl(aq): 2.2, NaOH(aq): 3.8836e-03}}
- {T: 320, P: 1 atm,
molalities: {Na+: 9.3549, Cl-: 9.3549, H+: 1.05e-06, OH-: 2.0e-05,
NaCl(aq): 0.98492, NaOH(aq): 3.8836e-06}}
- {T: 320, P: 20 atm,
molalities: {Na+: 9.3549, Cl-: 9.3549, H+: 1.05e-08, OH-: 1.3765e-06,
NaCl(aq): 0.98492, NaOH(aq): 3.8836e-06}}

debye-huckel-B-dot-ak:
setup:
file: debye-huckel-all.yaml
phase: debye-huckel-B-dot-ak
known-failures: *debye-huckel-failures
states: *debye-huckel-states

debye-huckel-B-dot-a:
setup:
file: debye-huckel-all.yaml
phase: debye-huckel-B-dot-a
known-failures: *debye-huckel-failures
states: *debye-huckel-states

debye-huckel-pitzer-beta_ij:
setup:
file: debye-huckel-all.yaml
phase: debye-huckel-pitzer-beta_ij
known-failures: *debye-huckel-failures
states: *debye-huckel-states

debye-huckel-beta_ij:
setup:
file: debye-huckel-all.yaml
phase: debye-huckel-beta_ij
known-failures: *debye-huckel-failures
states: *debye-huckel-states
30 changes: 30 additions & 0 deletions test/thermo/consistency.cpp
Expand Up @@ -280,4 +280,34 @@ INSTANTIATE_TEST_SUITE_P(PlasmaPhase, TestConsistency,
testing::ValuesIn(getStates("plasma")))
);

INSTANTIATE_TEST_SUITE_P(DebyeHuckelDilute, TestConsistency,
testing::Combine(
testing::Values(getSetup("debye-huckel-dilute")),
testing::ValuesIn(getStates("debye-huckel-dilute")))
);

INSTANTIATE_TEST_SUITE_P(DebyeHuckel_b_dot_ak, TestConsistency,
testing::Combine(
testing::Values(getSetup("debye-huckel-B-dot-ak")),
testing::ValuesIn(getStates("debye-huckel-B-dot-ak")))
);

INSTANTIATE_TEST_SUITE_P(DebyeHuckel_b_dot_a, TestConsistency,
testing::Combine(
testing::Values(getSetup("debye-huckel-B-dot-a")),
testing::ValuesIn(getStates("debye-huckel-B-dot-a")))
);

INSTANTIATE_TEST_SUITE_P(DebyeHuckel_pitzer_beta_ij, TestConsistency,
testing::Combine(
testing::Values(getSetup("debye-huckel-pitzer-beta_ij")),
testing::ValuesIn(getStates("debye-huckel-pitzer-beta_ij")))
);

INSTANTIATE_TEST_SUITE_P(DebyeHuckel_beta_ij, TestConsistency,
testing::Combine(
testing::Values(getSetup("debye-huckel-beta_ij")),
testing::ValuesIn(getStates("debye-huckel-beta_ij")))
);

}

0 comments on commit 97e078c

Please sign in to comment.