From 31b61f3a2a7a59038f040d83fb49e3c199e15e9d Mon Sep 17 00:00:00 2001 From: =?utf8?q?Michal=20Mal=C3=BD?= Date: Fri, 26 Dec 2014 04:22:51 +0100 Subject: [PATCH] Fix activity coefficient calculation in "Indifferent electrolyte" problem in solubility suite --- .../problem_generator-solubility_suite.adb | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/src/problem_generators/problem_generator-solubility_suite.adb b/src/problem_generators/problem_generator-solubility_suite.adb index 79f1f87..a99af41 100644 --- a/src/problem_generators/problem_generator-solubility_suite.adb +++ b/src/problem_generators/problem_generator-solubility_suite.adb @@ -410,8 +410,8 @@ package body Solubility_Suite is Ions_Other(1) := (Concentration => Prob_Data.C_EC, Charge => 1.0); Ions_Other(2) := (Concentration => Prob_Data.C_EC, Charge => 1.0); I := Calculate_Ionic_Strength(Ions_Other); - GM := Calculate_Activity_Coefficient(1.0, I); - GN := Calculate_Activity_Coefficient(1.0, I); + GM := Calculate_Activity_Coefficient(Prob_Data.N, I); + GN := Calculate_Activity_Coefficient(Prob_Data.M, I); C := Calculate_Sat_Concentration(Prob_Data.M, Prob_Data.N, Prob_Data.C_Ks, GM, GN); if Ionic_Strength then @@ -428,8 +428,8 @@ package body Solubility_Suite is Ions_All(4) := (Concentration => C * Prob_Data.N, Charge => Prob_Data.M); I_All := Calculate_Ionic_Strength(Ions_All); - GM := Calculate_Activity_Coefficient(Prob_Data.M, I_All); - GN := Calculate_Activity_Coefficient(Prob_Data.N, I_All); + GM := Calculate_Activity_Coefficient(Prob_Data.N, I_All); + GN := Calculate_Activity_Coefficient(Prob_Data.M, I_All); C := Calculate_Sat_Concentration(Prob_Data.M, Prob_Data.N, Prob_Data.C_Ks, GM, GN); end; -- 2.43.5