diff -u prop_conv-0.2/_manual.txt prop_conv-0.2.1/_manual.txt --- prop_conv-0.2/_manual.txt 2009-06-16 12:09:28.000000000 +0200 +++ prop_conv-0.2.1/_manual.txt 2009-07-16 17:30:28.000000000 +0200 @@ -7,15 +7,23 @@ prop_conv is released under the BSD license see the file LICENSE for more information -released: 16. June 2009 -version: 0.2 -second release (first public) +released: 16. July 2009 +version: 0.2.1 prop_conv is a utility for converting concentrations, densities and osmotic (and even activity) coefficients of electrolyte solutions this file is collection of data from all source files of this utility +the electrolyte database was checked for internal consistency, namely the conversion + molarity->molality->molarity +was done for all supported salts and the initial and final values were checked. +reasonable agreement was found for all salts that currently support both conversions. + +anyway *always check* the validity of the conversions you are using and consult the +original papers for the information on the range of concentrations where the parameters +are applicable! + usage: ====== prop_conv.py -s salt -a action [-h -t temp-kelvin -d water-density -o output_file input_file ] @@ -35,14 +43,6 @@ supported salts see prop_db.py or run program w/ -h switch -temperature: -============ -set your temperature on kelvin scale. please note, that if the conversion method -doesn't include temperature-based parameters (most of them at the moment) and the -specified temperature doesn't agree with the temperature for which the fit was -done, an approximate result taken into account only the changes in water density with -temperature will be reported - water density: ============== water density is normally calculated from the temperature using @@ -63,19 +63,20 @@ ======== c2d/m2d - convert concentration to density several options are available, the best one is always used (methods ordered with increasing quality) - concentration to density using fit to experimental data (cubic fit) + (vrbka) concentration to density using fit to experimental data (cubic fit) 4 parameters, temperature ignored or - molality to density using equation from J Phys Chem B 2002, 106, 1403-1420 + (abbas) molality to density using equation from J Phys Chem B 2002, 106, 1403-1420 1 parameter, temperature ignored or - molarity to density using equation from J Chem Eng Data 1988, 33, 49-55 + (novotny) molarity to density using equation from J Chem Eng Data 1988, 33, 49-55 2 parameters, temperature ignored, mass as well or - molarity to density using equation from J Chem Eng Data 1988, 33, 49-55 + (novotny2) molarity to density using equation from J Chem Eng Data 1988, 33, 49-55 6 parameters, temperature effect taken into account m2c/c2m - convert molality to molarity or vice versa + lr2mm/mm2lr - convert LR or MM osmotic coefficients to MM or LR level, respectively can be used for activity coefficients as well is using the simplest possible equation @@ -83,4 +84,3 @@ where m and c are molality and molarity of the solution, respectively this approach is questionable for high concentrations and polyvalent ions check the work of zareen abbas on the topic for more information - diff -u prop_conv-0.2/_notes.txt prop_conv-0.2.1/_notes.txt --- prop_conv-0.2/_notes.txt 2009-06-16 12:24:44.000000000 +0200 +++ prop_conv-0.2.1/_notes.txt 2009-07-16 17:33:36.000000000 +0200 @@ -1,9 +1,9 @@ release notes for prop_conv =========================== -released: 16. June 2009 -version: 0.2 -second release (first public) +released: 16. July 2009 +version: 0.2.1 +first update to second release downloadable through @@ -11,16 +11,16 @@ http://pyoz.vrbka.net/down -changes from the previous release (0.1) - - simplified algorithm - - support for 2 more methods for density calculation (abbas,novotny) - - support for more salts, acids, bases (molality) +changes from the previous release (0.2) + - bugfixes + - error checking - handling of (unsupported) temperatures below zero + - updated electrolyte database revisions/descriptions of individual source files -prop_conv.py ........................................... 0.2.1 +prop_conv.py ........................................... 0.2.2 main program prop_db.py ............................................. 0.2.1 electrolyte database -pyoz_func.py ........................................... 0.2.1 +pyoz_func.py ........................................... 0.2.2 helper functions diff -u prop_conv-0.2/prop_conv.py prop_conv-0.2.1/prop_conv.py --- prop_conv-0.2/prop_conv.py 2009-06-16 09:32:06.000000000 +0200 +++ prop_conv-0.2.1/prop_conv.py 2009-07-10 15:41:43.000000000 +0200 @@ -9,7 +9,7 @@ """ Program for conversion of properties of electrolyte solutins -revision of this file 0.2.1 +revision of this file 0.2.2 usage: prop_conv.py -s salt -a action [-h -t temp-kelvin -d water-density -o output_file input_file ] @@ -141,6 +141,10 @@ else: temp = default_temp fe.write("using default temperature (%.2f K / %.2f C)\n" % (temp, temp - 273.15)) + + if (temp < 273.15): + fe.write("\ttemperature below freezing point entered\n") + fe.write("\tusing density at freezing point (fit done for T >= 273.15K)\n") # %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% @@ -222,7 +226,8 @@ if (salt_db[cmdline['salt']]['m-conv']): # conversion supported fe.write("using the following method for molality->density calculation\n") - fe.write("\t%s\n" % salt_db[cmdline['salt']]['m-desc']) + fe.write("\tinternal name %s\n" % salt_db[cmdline['salt']]['m-desc'][0]) + fe.write("\t%s\n" % salt_db[cmdline['salt']]['m-desc'][1]) fe.write("\tref: %s\n" % salt_db[cmdline['salt']]['m-ref']) # set the function and data that will be used for the procedure dens_func = salt_db[cmdline['salt']]['m2d-func'] @@ -238,7 +243,7 @@ # will just correct density of water, i.e., we expect that the change in the density is mainly due to water # change in water density is dens_corr = dens_water(T) - dens_water(T_fit) # the salt density is then salt(exp) = salt(fit) + dens_corr - dens_corr = dens_water - wat_temp2dens(fe, salt_db[cmdline['salt']]['m-temp']) + dens_corr = wat_dens - wat_temp2dens(fe, salt_db[cmdline['salt']]['m-temp']) fe.write("\tusing correction to water density only: %f\n" % dens_corr) # end if - in other cases, the temperature dependence of density is included in the fit else: @@ -251,7 +256,8 @@ if (salt_db[cmdline['salt']]['c-conv']): # conversion supported fe.write("using the following method for molarity->density calculation\n") - fe.write("\t%s\n" % salt_db[cmdline['salt']]['c-desc']) + fe.write("\tinternal name %s\n" % salt_db[cmdline['salt']]['c-desc'][0]) + fe.write("\t%s\n" % salt_db[cmdline['salt']]['c-desc'][1]) fe.write("\tref: %s\n" % salt_db[cmdline['salt']]['c-ref']) # set the function and data that will be used for the procedure dens_func = salt_db[cmdline['salt']]['c2d-func'] @@ -267,7 +273,7 @@ # will just correct density of water, i.e., we expect that the change in the density is mainly due to water # change in water density is dens_corr = dens_water(T) - dens_water(T_fit) # the salt density is then salt(exp) = salt(fit) + dens_corr - dens_corr = dens_water - wat_temp2dens(fe, salt_db[cmdline['salt']]['c-temp']) + dens_corr = wat_dens - wat_temp2dens(fe, salt_db[cmdline['salt']]['c-temp']) fe.write("\tusing correction to water density only: %f\n" % dens_corr) # end if - in other cases, the temperature dependence of density is included in the fit else: @@ -353,7 +359,7 @@ # print the resulting molarity/molality and jump to the end of the cycle - nothing more is needed if (cmdline['action'] == 'm2c'): fo.write("%f\n" % molar) - elif(cmdline['action'] == 'm2c'): + elif(cmdline['action'] == 'c2m'): fo.write("%f\n" % molal) else: # this cannot happen - the possible actions are treated before diff -u prop_conv-0.2/prop_db.py prop_conv-0.2.1/prop_db.py --- prop_conv-0.2/prop_db.py 2009-06-16 09:32:03.000000000 +0200 +++ prop_conv-0.2.1/prop_db.py 2009-07-16 17:22:34.000000000 +0200 @@ -27,13 +27,15 @@ rho_salt = rho_water + A c + B c t + C c t**2 + D c**3/2 + E c**3/2 t + F c**3/2 t**2 where c and t are molarity and temperature (in degrees centigrade!) the fit parameters A-F are stored in the database in the c2d-data array + the parameters are stored as published in article and given in the respective table + they need to be multiplied with some constants! - done in the respective function novotny2: c2d, no temperature dependence rho_salt = rho_water + A c + B c**3/2 where c is molarity the fit parameters A, B are stored in the database in the c2d-data array - - + the parameters are stored as published in article and given in the respective table + they need to be multiplied with some constants! - done in the respective function '' : { 'name' : "", @@ -63,10 +65,10 @@ # descriptions of the methods for converting concentration to density method = { - 'vrbka': "3rd order polynomial fit to density data, no temperature", - 'abbas': "c->rho expr. involving 1 fitting parameter (w/o temperature)", - 'novotny': "m->rho expr. involving 5 fitting parameters (w/ temperature)", - 'novotny2': "m->rho expr. involving 2 fitting parameters (w/o temperature)", + 'vrbka': ["vrbka", "3rd order polynomial fit to density data, no temperature"], + 'abbas': ["abbas", "c->rho expr. involving 1 fitting parameter (w/o temperature)"], + 'novotny': ["novotny", "m->rho expr. involving 2 fitting parameters (w/o temperature)"], + 'novotny2': ["novotny2", "m->rho expr. involving 5 fitting parameters (w/ temperature)"], } # literature references (if frequently present) @@ -86,16 +88,16 @@ prints out supported salts """ - fe.write("supported salts and actions:\n") + fe.write("supported salts and concentration types with used method for density:\n") for i in (sorted(salt_db.keys())): fe.write("\t%-20s" % salt_db[i]['name']) if (salt_db[i]['c-conv']): - fe.write("molarity") + fe.write("molarity/%-10s" % salt_db[i]['c-desc'][0]) else: - fe.write("\t") + fe.write("\t%s" % str(10*" ") ) # end if if (salt_db[i]['m-conv']): - fe.write("\tmolality") + fe.write("\tmolality/%-10s" % salt_db[i]['m-desc'][0]) else: fe.write("") # end if @@ -119,7 +121,7 @@ # # m-conv - is any method for molality->density available? # m-temp - temperature of the molality->denstity data (in K); if "fit", then temperature is a parameter -# m-desc - description of the molality->density conversion method +# m-desc - description of the molality->density conversion method (array - name, description) # m-ref - reference of the method or of the experimental data # m2d-func - the function for the molality->density conversion # m2d-data - fit data for the conversion function @@ -132,12 +134,12 @@ 'agno3' : { 'name' : "AgNO3", 'mass' : 169.8732, - 'c-conv': False, - #'c-temp': , - #'c-desc': method[''], - #'c-ref' : ref['robinson'], - #'c2d-func' : func_c2d_, - #'c2d-data' : , + 'c-conv': True, + 'c-temp': 'fit', + 'c-desc': method['novotny2'], + 'c-ref' : ref['novotny1988'], + 'c2d-func' : func_c2d_novotny2, + 'c2d-data' : [1.473, 3.442, 2.869, 4.298, 11.74, 9.798], 'm-conv': True, 'm-temp': 298.15, 'm-desc': method['abbas'], @@ -151,12 +153,12 @@ 'alcl3' : { 'name' : "AlCl3", 'mass' : 133.3411, - 'c-conv': False, - #'c-temp': , - #'c-desc': method[''], - #'c-ref' : ref['robinson'], - #'c2d-func' : func_c2d_, - #'c2d-data' : , + 'c-conv': True, + 'c-temp': 298.15, + 'c-desc': method['novotny'], + 'c-ref' : ref['novotny1988'], + 'c2d-func' : func_c2d_novotny, + 'c2d-data' : [1.183, 0.8182], 'm-conv': True, 'm-temp': 298.15, 'm-desc': method['abbas'], @@ -170,12 +172,12 @@ 'babr2' : { 'name' : "BaBr2", 'mass' : 297.1359, - 'c-conv': False, - #'c-temp': , - #'c-desc': method[''], - #'c-ref' : ref['robinson'], - #'c2d-func' : func_c2d_, - #'c2d-data' : , + 'c-conv': True, + 'c-temp': 'fit', + 'c-desc': method['novotny2'], + 'c-ref' : ref['novotny1988'], + 'c2d-func' : func_c2d_novotny2, + 'c2d-data' : [2.569, 4.798, 1.387, 3.546, 24.33, -2.784], 'm-conv': True, 'm-temp': 298.15, 'm-desc': method['abbas'], @@ -186,28 +188,28 @@ 'bacl2' : { 'name' : "BaCl2", 'mass' : 208.2341, - 'c-conv': False, - #'c-temp': , - #'c-desc': method[''], - #'c-ref' : ref['robinson'], - #'c2d-func' : func_c2d_, - #'c2d-data' : , - 'm-conv': True, - 'm-temp': 298.15, - 'm-desc': method['abbas'], - 'm-ref' : ref['abbas2002'], - 'm2d-func' : func_m2d_abbas, - 'm2d-data' : 0.9275, + 'c-conv': True, + 'c-temp': 'fit', + 'c-desc': method['novotny2'], + 'c-ref' : ref['novotny1988'], + 'c2d-func' : func_c2d_novotny2, + 'c2d-data' : [1.878, 1.535, -3.400, 7.075, -84.98, -47.04], + 'm-conv': False, + #'m-temp': 298.15, + #'m-desc': method['abbas'], + #'m-ref' : ref['abbas2002'], + #'m2d-func' : func_m2d_abbas, + #'m2d-data' : 0.9275, }, 'ba(clo4)2' : { 'name' : "Ba(ClO4)2", 'mass' : 336.2295, - 'c-conv': False, - #'c-temp': , - #'c-desc': method[''], - #'c-ref' : ref['robinson'], - #'c2d-func' : func_c2d_, - #'c2d-data' : , + 'c-conv': True, + 'c-temp': 298.15, + 'c-desc': method['novotny'], + 'c-ref' : ref['novotny1988'], + 'c2d-func' : func_c2d_novotny, + 'c2d-data' : [2.621, 0.8486], 'm-conv': True, 'm-temp': 298.15, 'm-desc': method['abbas'], @@ -218,12 +220,12 @@ 'bai2' : { 'name' : "BaI2", 'mass' : 391.1366, - 'c-conv': False, - #'c-temp': , - #'c-desc': method[''], - #'c-ref' : ref['robinson'], - #'c2d-func' : func_c2d_, - #'c2d-data' : , + 'c-conv': True, + 'c-temp': 'fit', + 'c-desc': method['novotny2'], + 'c-ref' : ref['novotny1988'], + 'c2d-func' : func_c2d_novotny2, + 'c2d-data' : [3.379, 5.313, 3.887, 8.130, 23.12, 16.67], 'm-conv': True, 'm-temp': 298.15, 'm-desc': method['abbas'], @@ -234,12 +236,12 @@ 'ba(no3)2' : { 'name' : "Ba(NO3)2", 'mass' : 261.3377, - 'c-conv': False, - #'c-temp': , - #'c-desc': method[''], - #'c-ref' : ref['robinson'], - #'c2d-func' : func_c2d_, - #'c2d-data' : , + 'c-conv': True, + 'c-temp': 'fit', + 'c-desc': method['novotny2'], + 'c-ref' : ref['novotny1988'], + 'c2d-func' : func_c2d_novotny2, + 'c2d-data' : [2.738, 28.04, 5.422, 123.8, 625.2, 424.1], 'm-conv': True, 'm-temp': 298.15, 'm-desc': method['abbas'], @@ -253,12 +255,12 @@ 'cabr2' : { 'name' : "CaBr2", 'mass' : 199.8866, - 'c-conv': False, - #'c-temp': , - #'c-desc': method[''], - #'c-ref' : ref['robinson'], - #'c2d-func' : func_c2d_, - #'c2d-data' : , + 'c-conv': True, + 'c-temp': 'fit', + 'c-desc': method['novotny2'], + 'c-ref' : ref['novotny1988'], + 'c2d-func' : func_c2d_novotny2, + 'c2d-data' : [1.740, 2.575, 2.359, 8.300, 7.635, 7.212], 'm-conv': True, 'm-temp': 298.15, 'm-desc': method['abbas'], @@ -269,28 +271,28 @@ 'cacl2' : { 'name' : "CaCl2", 'mass' : 110.9848, - 'c-conv': False, - #'c-temp': , - #'c-desc': method[''], - #'c-ref' : ref['robinson'], - #'c2d-func' : func_c2d_, - #'c2d-data' : , - 'm-conv': True, - 'm-temp': 298.15, - 'm-desc': method['abbas'], - 'm-ref' : ref['abbas2002'], - 'm2d-func' : func_m2d_abbas, - 'm2d-data' : 0.8214, - }, - 'cacl04' : { - 'name' : "CaClO4", - 'mass' : 139.5293, - 'c-conv': False, - #'c-temp': , - #'c-desc': method[''], - #'c-ref' : ref['robinson'], - #'c2d-func' : func_c2d_, - #'c2d-data' : , + 'c-conv': True, + 'c-temp': 'fit', + 'c-desc': method['novotny2'], + 'c-ref' : ref['novotny1988'], + 'c2d-func' : func_c2d_novotny2, + 'c2d-data' : [1.012, 61.56, 1.028, 9.749, 96.94, 3.165], + 'm-conv': False, + #'m-temp': 298.15, + #'m-desc': method['abbas'], + #'m-ref' : ref['abbas2002'], + #'m2d-func' : func_m2d_abbas, + #'m2d-data' : 0.8214, + }, + 'ca(clo4)2' : { + 'name' : "Ca(ClO4)2", + 'mass' : 238.9792, + 'c-conv': True, + 'c-temp': 298.15, + 'c-desc': method['novotny'], + 'c-ref' : ref['novotny1988'], + 'c2d-func' : func_c2d_novotny, + 'c2d-data' : [1.720, 1.047], 'm-conv': True, 'm-temp': 298.15, 'm-desc': method['abbas'], @@ -301,12 +303,12 @@ 'cai2' : { 'name' : "CaI2", 'mass' : 293.8873, - 'c-conv': False, - #'c-temp': , - #'c-desc': method[''], - #'c-ref' : ref['robinson'], - #'c2d-func' : func_c2d_, - #'c2d-data' : , + 'c-conv': True, + 'c-temp': 'fit', + 'c-desc': method['novotny2'], + 'c-ref' : ref['novotny1988'], + 'c2d-func' : func_c2d_novotny2, + 'c2d-data' : [2.696, 12.66, 10.85, 25.46, 99.78, 86.93], 'm-conv': True, 'm-temp': 298.15, 'm-desc': method['abbas'], @@ -317,6 +319,25 @@ 'ca(no3)2' : { 'name' : "Ca(NO3)2", 'mass' : 164.0884, + 'c-conv': True, + 'c-temp': 'fit', + 'c-desc': method['novotny2'], + 'c-ref' : ref['novotny1988'], + 'c2d-func' : func_c2d_novotny2, + 'c2d-data' : [1.298, 2.052, 1.023, 8.426, 0.776, -4.225], + 'm-conv': True, + 'm-temp': 298.15, + 'm-desc': method['abbas'], + 'm-ref' : ref['abbas2002'], + 'm2d-func' : func_m2d_abbas, + 'm2d-data' : 0.7616, + }, + # *************************************************************************** + # *************************************************************************** + # Cd - "salts" **************************************** + 'cd(clo4)2' : { + 'name' : "Cd(ClO4)2", + 'mass' : 311.3136, 'c-conv': False, #'c-temp': , #'c-desc': method[''], @@ -328,7 +349,39 @@ 'm-desc': method['abbas'], 'm-ref' : ref['abbas2002'], 'm2d-func' : func_m2d_abbas, - 'm2d-data' : 0.7616, + 'm2d-data' : 0.8246, + }, + 'cd(no3)2' : { + 'name' : "Cd(NO3)2", + 'mass' : 236.4218, + 'c-conv': True, + 'c-temp': 'fit', + 'c-desc': method['novotny2'], + 'c-ref' : ref['novotny1988'], + 'c2d-func' : func_c2d_novotny2, + 'c2d-data' : [1.948, -0.09302, -0.03925, 5.591, -6.808, -5.439], + 'm-conv': True, + 'm-temp': 298.15, + 'm-desc': method['abbas'], + 'm-ref' : ref['abbas2002'], + 'm2d-func' : func_m2d_abbas, + 'm2d-data' : 0.8930, + }, + 'cdso4' : { + 'name' : "CdSO4", + 'mass' : 208.4750, + 'c-conv': True, + 'c-temp': 'fit', + 'c-desc': method['novotny2'], + 'c-ref' : ref['novotny1988'], + 'c2d-func' : func_c2d_novotny2, + 'c2d-data' : [3.706, 1.409, 286.6, 102.4, 775.1, 1579.0], + 'm-conv': False, + #'m-temp': 298.15, + #'m-desc': method['abbas'], + #'m-ref' : ref['abbas2002'], + #'m2d-func' : func_m2d_abbas, + #'m2d-data' : 1.0640, }, # *************************************************************************** # *************************************************************************** @@ -337,11 +390,15 @@ 'name' : "CsBr", 'mass' : 212.814, 'c-conv': True, - 'c-temp': 298.15, - 'c-desc': method['vrbka'], - 'c-ref' : ref['robinson'], - 'c2d-func' : func_c2d_vrbka, - 'c2d-data' : [0.99710, 0.16586, -0.0010059, 6.8566E-05], + 'c-temp': 'fit', + 'c-desc': method['novotny2'], + 'c-ref' : ref['novotny1988'], + 'c2d-func' : func_c2d_novotny2, + 'c2d-data' : [1.693, 1.123, 0.9765, 2.066, 0.000, 0.000], + #'c-desc': method['vrbka'], + #'c-ref' : ref['robinson'], + #'c2d-func' : func_c2d_vrbka, + #'c2d-data' : [0.99710, 0.16586, -0.0010059, 6.8566E-05], 'm-conv': True, 'm-temp': 298.15, #'m-desc': method['vrbka'], @@ -357,11 +414,15 @@ 'name' : "CsCl", 'mass' : 168.3584, 'c-conv': True, - 'c-temp': 298.15, - 'c-desc': method['vrbka'], - 'c-ref' : ref['unk'], - 'c2d-func' : func_c2d_vrbka, - 'c2d-data' : [0.9979, 0.12536, 0.00067675, -0.00021554], + 'c-temp': 'fit', + 'c-desc': method['novotny2'], + 'c-ref' : ref['novotny1988'], + 'c2d-func' : func_c2d_novotny2, + 'c2d-data' : [1.327, 1.511, 1.251, 3.113, 4.181, 3.319], + #'c-desc': method['vrbka'], + #'c-ref' : ref['unk'], + #'c2d-func' : func_c2d_vrbka, + #'c2d-data' : [0.9979, 0.12536, 0.00067675, -0.00021554], 'm-conv': True, 'm-temp': 298.15, #'m-desc': method['vrbka'], @@ -377,51 +438,51 @@ 'name' : "CsF", 'mass' : 151.9038, 'c-conv': True, - 'c-temp': 298.15, - 'c-desc': method['vrbka'], - 'c-ref' : ref['hamer1972'], - 'c2d-func' : func_c2d_vrbka, - 'c2d-data' : [0.99711, 0.131440, -0.00224570, 6.9129E-04], + 'c-temp': 'fit', + 'c-desc': method['novotny2'], + 'c-ref' : ref['novotny1988'], + 'c2d-func' : func_c2d_novotny2, + 'c2d-data' : [1.352, 1.535, 1.837, 3.569, 3.856, 4.391], 'm-conv': True, 'm-temp': 298.15, - #'m-desc': method['vrbka'], - #'m-ref' : ref['hamer1972'], - #'m2d-func' : func_m2d_vrbka, - #'m2d-data' : [0.99711, 0.131060, -0.00493170, 6.0014E-04], - 'm-desc': method['abbas'], - 'm-ref' : ref['abbas2002'], - 'm2d-func' : func_m2d_abbas, - 'm2d-data' : 1.2595, + 'm-desc': method['vrbka'], + 'm-ref' : ref['hamer1972'], + 'm2d-func' : func_m2d_vrbka, + 'm2d-data' : [0.99711, 0.131060, -0.00493170, 6.0014E-04], }, 'csi' : { 'name' : "CsI", 'mass' : 259.8099, 'c-conv': True, - 'c-temp': 298.15, - 'c-desc': method['vrbka'], - 'c-ref' : ref['robinson'], - 'c2d-func' : func_c2d_vrbka, - 'c2d-data' : [0.99707, 0.201930, -0.00144700, 2.5822E-04], + 'c-temp': 'fit', + 'c-desc': method['novotny2'], + 'c-ref' : ref['novotny1988'], + 'c2d-func' : func_c2d_novotny2, + 'c2d-data' : [2.051, 1.521, 1.193, 1.306, 0.000, 0.000], + #'c-desc': method['vrbka'], + #'c-ref' : ref['robinson'], + #'c2d-func' : func_c2d_vrbka, + #'c2d-data' : [0.99707, 0.201930, -0.00144700, 2.5822E-04], 'm-conv': True, 'm-temp': 298.15, - #'m-desc': method['vrbka'], - #'m-ref' : ref['robinson'], - #'m2d-func' : func_m2d_vrbka, - #'m2d-data' : [0.99708, 0.201270, -0.01296500, 7.4278E-04], - 'm-desc': method['abbas'], - 'm-ref' : ref['abbas2002'], - 'm2d-func' : func_m2d_abbas, - 'm2d-data' : 0.6420, + 'm-desc': method['vrbka'], + 'm-ref' : ref['robinson'], + 'm2d-func' : func_m2d_vrbka, + 'm2d-data' : [0.99708, 0.201270, -0.01296500, 7.4278E-04], + #'m-desc': method['abbas'], + #'m-ref' : ref['abbas2002'], + #'m2d-func' : func_m2d_abbas, + #'m2d-data' : 0.6420, }, 'csoh' : { 'name' : "CsOH", 'mass' : 149.9128, - 'c-conv': False, - #'c-temp': , - #'c-desc': method[''], - #'c-ref' : ref['robinson'], - #'c2d-func' : func_c2d_, - #'c2d-data' : , + 'c-conv': True, + 'c-temp': 298.15, + 'c-desc': method['novotny'], + 'c-ref' : ref['novotny1988'], + 'c2d-func' : func_c2d_novotny, + 'c2d-data' : [1.303, 0.0900], 'm-conv': True, 'm-temp': 298.15, 'm-desc': method['abbas'], @@ -431,83 +492,32 @@ }, # *************************************************************************** # *************************************************************************** - # Cd - "salts" **************************************** - 'cd(clo4)2' : { - 'name' : "Cd(ClO4)2", - 'mass' : 311.3136, - 'c-conv': False, - #'c-temp': , - #'c-desc': method[''], - #'c-ref' : ref['robinson'], - #'c2d-func' : func_c2d_, - #'c2d-data' : , - 'm-conv': True, - 'm-temp': 298.15, - 'm-desc': method['abbas'], - 'm-ref' : ref['abbas2002'], - 'm2d-func' : func_m2d_abbas, - 'm2d-data' : 0.8246, - }, - 'cd(no3)2' : { - 'name' : "Cd(NO3)2", - 'mass' : 236.4218, - 'c-conv': False, - #'c-temp': , - #'c-desc': method[''], - #'c-ref' : ref['robinson'], - #'c2d-func' : func_c2d_, - #'c2d-data' : , - 'm-conv': True, - 'm-temp': 298.15, - 'm-desc': method['abbas'], - 'm-ref' : ref['abbas2002'], - 'm2d-func' : func_m2d_abbas, - 'm2d-data' : 0.8930, - }, - 'cdso4' : { - 'name' : "CdSO4", - 'mass' : 208.4750, - 'c-conv': False, - #'c-temp': , - #'c-desc': method[''], - #'c-ref' : ref['robinson'], - #'c2d-func' : func_c2d_, - #'c2d-data' : , - 'm-conv': True, - 'm-temp': 298.15, - 'm-desc': method['abbas'], - 'm-ref' : ref['abbas2002'], - 'm2d-func' : func_m2d_abbas, - 'm2d-data' : 1.0640, - }, - # *************************************************************************** - # *************************************************************************** # Cu - "salts" **************************************** 'cu(clo4)2' : { 'name' : "Cu(ClO4)2", 'mass' : 262.4481, - 'c-conv': False, - #'c-temp': , - #'c-desc': method[''], - #'c-ref' : ref['robinson'], - #'c2d-func' : func_c2d_, - #'c2d-data' : , - 'm-conv': True, - 'm-temp': 298.15, - 'm-desc': method['abbas'], - 'm-ref' : ref['abbas2002'], - 'm2d-func' : func_m2d_abbas, - 'm2d-data' : 0.7636, + 'c-conv': True, + 'c-temp': 293.15, + 'c-desc': method['novotny'], + 'c-ref' : ref['novotny1988'], + 'c2d-func' : func_c2d_novotny, + 'c2d-data' : [2.137, 1.365], + 'm-conv': False, + #'m-temp': 298.15, + #'m-desc': method['abbas'], + #'m-ref' : ref['abbas2002'], + #'m2d-func' : func_m2d_abbas, + #'m2d-data' : 0.7636, }, 'cu(no3)2' : { 'name' : "Cu(NO3)2", 'mass' : 187.5563, - 'c-conv': False, - #'c-temp': , - #'c-desc': method[''], - #'c-ref' : ref['robinson'], - #'c2d-func' : func_c2d_, - #'c2d-data' : , + 'c-conv': True, + 'c-temp': 'fit', + 'c-desc': method['novotny2'], + 'c-ref' : ref['novotny1988'], + 'c2d-func' : func_c2d_novotny2, + 'c2d-data' : [1.470, -21.33, -68.82, 0.4527, -126.0, -376.3], 'm-conv': True, 'm-temp': 298.15, 'm-desc': method['abbas'], @@ -521,12 +531,12 @@ 'hbr' : { 'name' : "HBr", 'mass' : 80.9120, - 'c-conv': False, - #'c-temp': , - #'c-desc': method[''], - #'c-ref' : ref['robinson'], - #'c2d-func' : func_c2d_, - #'c2d-data' : , + 'c-conv': True, + 'c-temp': 'fit', + 'c-desc': method['novotny2'], + 'c-ref' : ref['novotny1988'], + 'c2d-func' : func_c2d_novotny2, + 'c2d-data' : [0.5998, 1.300, 1.061, 1.263, 2.160, 1.647], 'm-conv': True, 'm-temp': 298.15, 'm-desc': method['abbas'], @@ -537,12 +547,12 @@ 'hcl' : { 'name' : "HCl", 'mass' : 36.4611, - 'c-conv': False, - #'c-temp': , - #'c-desc': method[''], - #'c-ref' : ref['robinson'], - #'c2d-func' : func_c2d_, - #'c2d-data' : , + 'c-conv': True, + 'c-temp': 'fit', + 'c-desc': method['novotny2'], + 'c-ref' : ref['novotny1988'], + 'c2d-func' : func_c2d_novotny2, + 'c2d-data' : [0.2046, 0.9435, 1.090, 1.227, 1.269, 1.980], 'm-conv': True, 'm-temp': 298.15, 'm-desc': method['abbas'], @@ -553,12 +563,12 @@ 'hclo4' : { 'name' : "HClO4", 'mass' : 100.4589, - 'c-conv': False, - #'c-temp': , - #'c-desc': method[''], - #'c-ref' : ref['robinson'], - #'c2d-func' : func_c2d_, - #'c2d-data' : , + 'c-conv': True, + 'c-temp': 'fit', + 'c-desc': method['novotny2'], + 'c-ref' : ref['novotny1988'], + 'c2d-func' : func_c2d_novotny2, + 'c2d-data' : [0.5985, 3.334, 3.190, -0.05668, 8.249, 9.076], 'm-conv': True, 'm-temp': 298.15, 'm-desc': method['abbas'], @@ -569,12 +579,12 @@ 'hi' : { 'name' : "HI", 'mass' : 127.9124, - 'c-conv': False, - #'c-temp': , - #'c-desc': method[''], - #'c-ref' : ref['robinson'], - #'c2d-func' : func_c2d_, - #'c2d-data' : , + 'c-conv': True, + 'c-temp': 'fit', + 'c-desc': method['novotny2'], + 'c-ref' : ref['novotny1988'], + 'c2d-func' : func_c2d_novotny2, + 'c2d-data' : [0.9397, 2.176, 2.343, 0.08738, 5.792, 7.778], 'm-conv': True, 'm-temp': 298.15, 'm-desc': method['abbas'], @@ -585,12 +595,12 @@ 'hno3' : { 'name' : "HNO3", 'mass' : 63.0130, - 'c-conv': False, - #'c-temp': , - #'c-desc': method[''], - #'c-ref' : ref['robinson'], - #'c2d-func' : func_c2d_, - #'c2d-data' : , + 'c-conv': True, + 'c-temp': 'fit', + 'c-desc': method['novotny2'], + 'c-ref' : ref['novotny1988'], + 'c2d-func' : func_c2d_novotny2, + 'c2d-data' : [0.4063, 1.554, 1.096, 2.798, 2.478, 2.761], 'm-conv': True, 'm-temp': 298.15, 'm-desc': method['abbas'], @@ -606,10 +616,10 @@ 'mass' : 98.1428, 'c-conv': True, 'c-temp': 298.15, - 'c-desc': method['vrbka'], - 'c-ref' : ref['robinson'], - 'c2d-func' : func_c2d_vrbka, - 'c2d-data' : [0.99710, 0.048809, 0.01561400, -9.1866E-03], + 'c-desc': method['novotny'], + 'c-ref' : ref['novotny1988'], + 'c2d-func' : func_c2d_novotny, + 'c2d-data' : [0.5101, 0.3385], 'm-conv': True, 'm-temp': 298.15, 'm-desc': method['vrbka'], @@ -620,12 +630,12 @@ 'kbr' : { 'name' : "KBr", 'mass' : 119.0023, - 'c-conv': True, - 'c-temp': 298.15, - 'c-desc': method['vrbka'], - 'c-ref' : ref['hamer1972'], - 'c2d-func' : func_c2d_vrbka, - 'c2d-data' : [0.99704, 0.084272, -0.0012244, 3.8114e-05], + 'c-conv': True, + 'c-temp': 'fit', + 'c-desc': method['novotny2'], + 'c-ref' : ref['novotny1988'], + 'c2d-func' : func_c2d_novotny2, + 'c2d-data' : [0.9057, 1.876, 1.425, 4.019, 5.985, 4.092], 'm-conv': True, 'm-temp': 298.15, #'m-desc': method['vrbka'], @@ -641,11 +651,11 @@ 'name' : "KCl", 'mass' : 74.5513, 'c-conv': True, - 'c-temp': 298.15, - 'c-desc': method['vrbka'], - 'c-ref' : ref['hamer1972'], - 'c2d-func' : func_c2d_vrbka, - 'c2d-data' : [0.99704, 0.046641, -0.00088941, 3.0898e-05], + 'c-temp': 'fit', + 'c-desc': method['novotny2'], + 'c-ref' : ref['novotny1988'], + 'c2d-func' : func_c2d_novotny2, + 'c2d-data' : [0.4971, 0.7150, 0.6506, 2.376, 0.000, 0.000], 'm-conv': True, 'm-temp': 298.15, #'m-desc': method['vrbka'], @@ -661,11 +671,11 @@ 'name' : "KF", 'mass' : 58.09670, 'c-conv': True, - 'c-temp': 298.15, - 'c-desc': method['vrbka'], - 'c-ref' : ref['heydweiller1909'], - 'c2d-func' : func_c2d_vrbka, - 'c2d-data' : [0.99726, 0.049297, -0.00049012, 1.9243e-05], + 'c-temp': 'fit', + 'c-desc': method['novotny2'], + 'c-ref' : ref['novotny1988'], + 'c2d-func' : func_c2d_novotny2, + 'c2d-data' : [0.5364, 1.208, 1.317, 3.790, 3.121, 3.399], 'm-conv': True, 'm-temp': 298.15, #'m-desc': method['vrbka'], @@ -681,11 +691,11 @@ 'name' : "KI", 'mass' : 166.00280, 'c-conv': True, - 'c-temp': 298.15, - 'c-desc': method['vrbka'], - 'c-ref' : ref['heydweiller1909'], - 'c2d-func' : func_c2d_vrbka, - 'c2d-data' : [0.99716, 0.12105, 0.00452350, -0.00028173], + 'c-temp': 'fit', + 'c-desc': method['novotny2'], + 'c-ref' : ref['novotny1988'], + 'c2d-func' : func_c2d_novotny2, + 'c2d-data' : [1.256, 2.125, 1.515, 3.022, 5.980, 4.090], 'm-conv': True, 'm-temp': 298.15, #'m-desc': method['vrbka'], @@ -700,12 +710,12 @@ 'kno3' : { 'name' : "KNO3", 'mass' : 101.1033, - 'c-conv': False, - #'c-temp': , - #'c-desc': method[''], - #'c-ref' : ref['robinson'], - #'c2d-func' : func_c2d_, - #'c2d-data' : , + 'c-conv': True, + 'c-temp': 'fit', + 'c-desc': method['novotny2'], + 'c-ref' : ref['novotny1988'], + 'c2d-func' : func_c2d_novotny2, + 'c2d-data' : [0.6553, 1.477, 0.9596, 2.323, 2.364, 1.500], 'm-conv': True, 'm-temp': 298.15, 'm-desc': method['abbas'], @@ -716,12 +726,12 @@ 'koh' : { 'name' : "KOH", 'mass' : 56.1057, - 'c-conv': False, - #'c-temp': , - #'c-desc': method[''], - #'c-ref' : ref['robinson'], - #'c2d-func' : func_c2d_, - #'c2d-data' : , + 'c-conv': True, + 'c-temp': 'fit', + 'c-desc': method['novotny2'], + 'c-ref' : ref['novotny1988'], + 'c2d-func' : func_c2d_novotny2, + 'c2d-data' : [0.5459, 1.156, 1.009, 4.383, 2.343, 1.865], 'm-conv': True, 'm-temp': 298.15, 'm-desc': method['abbas'], @@ -735,12 +745,12 @@ 'lacl3' : { 'name' : "LaCl3", 'mass' : 245.2651, - 'c-conv': False, - #'c-temp': , - #'c-desc': method[''], - #'c-ref' : ref['robinson'], - #'c2d-func' : func_c2d_, - #'c2d-data' : , + 'c-conv': True, + 'c-temp': 'fit', + 'c-desc': method['novotny2'], + 'c-ref' : ref['novotny1988'], + 'c2d-func' : func_c2d_novotny2, + 'c2d-data' : [2.139, 0.8064, 1.110, 12.30, 0.000, 0.000], 'm-conv': True, 'm-temp': 298.15, 'm-desc': method['abbas'], @@ -751,15 +761,31 @@ # *************************************************************************** # *************************************************************************** # Li - salts **************************************** + 'liac': { + 'name' : "LiAc", + 'mass' : 65.98502, + 'c-conv': True, + 'c-temp': 291.15, + 'c-desc': method['novotny'], + 'c-ref' : ref['novotny1988'], + 'c2d-func' : func_c2d_novotny, + 'c2d-data' : [0.2587, 0.08703], + 'm-conv': False, + #'m-temp': 291.15, + #'m-desc': method['vrbka'], + #'m-ref' : ref['heydweiller1909'], + #'m2d-func' : func_m2d_vrbka, + #'m2d-data' : [0.99708, 0.099510, 0.00256850, -7.0137e-05], + }, 'libr': { 'name' : "LiBr", 'mass' : 86.845, 'c-conv': True, - 'c-temp': 298.15, - 'c-desc': method['vrbka'], - 'c-ref' : ref['heydweiller1909'], - 'c2d-func' : func_c2d_vrbka, - 'c2d-data' : [0.99711, 0.062673, 0.00088955, -4.5490e-06], + 'c-temp': 'fit', + 'c-desc': method['novotny2'], + 'c-ref' : ref['novotny1988'], + 'c2d-func' : func_c2d_novotny2, + 'c2d-data' : [0.6032, 0.00444, 0.2329, 0.6188, -2.448, -1.773], 'm-conv': True, 'm-temp': 298.15, #'m-desc': method['vrbka'], @@ -775,11 +801,11 @@ 'name' : "LiCl", 'mass' : 42.394, 'c-conv': True, - 'c-temp': 298.15, - 'c-desc': method['vrbka'], - 'c-ref' : ref['unk'], - 'c2d-func' : func_c2d_vrbka, - 'c2d-data' : [0.99708, 0.024400, -0.00046846, -1.3699e-05], + 'c-temp': 'fit', + 'c-desc': method['novotny2'], + 'c-ref' : ref['novotny1988'], + 'c2d-func' : func_c2d_novotny2, + 'c2d-data' : [0.2446, 0.5505, 0.8671, 0.7927, 1.169, 1.761], 'm-conv': True, 'm-temp': 298.15, #'m-desc': method['vrbka'], @@ -794,12 +820,12 @@ 'liclo4' : { 'name' : "LiClO4", 'mass' : 106.3921, - 'c-conv': False, - #'c-temp': , - #'c-desc': method[''], - #'c-ref' : ref['robinson'], - #'c2d-func' : func_c2d_, - #'c2d-data' : , + 'c-conv': True, + 'c-temp': 'fit', + 'c-desc': method['novotny2'], + 'c-ref' : ref['novotny1988'], + 'c2d-func' : func_c2d_novotny2, + 'c2d-data' : [0.6957, 3.280, 2.913, 3.409, 12.42, 12.88], 'm-conv': True, 'm-temp': 298.15, 'm-desc': method['abbas'], @@ -811,11 +837,11 @@ 'name' : "LiI", 'mass' : 133.8455, 'c-conv': True, - 'c-temp': 298.15, - 'c-desc': method['vrbka'], - 'c-ref' : ref['heydweiller1909'], - 'c2d-func' : func_c2d_vrbka, - 'c2d-data' : [0.99708, 0.099510, 0.00256850, -7.0137e-05], + 'c-temp': 'fit', + 'c-desc': method['novotny2'], + 'c-ref' : ref['novotny1988'], + 'c2d-func' : func_c2d_novotny2, + 'c2d-data' : [0.9992, 1.486, 1.304, 0.5602, 3.721, 3.197], 'm-conv': True, 'm-temp': 298.15, #'m-desc': method['vrbka'], @@ -830,12 +856,12 @@ 'lino3' : { 'name' : "LiNO3", 'mass' : 68.9462, - 'c-conv': False, - #'c-temp': , - #'c-desc': method[''], - #'c-ref' : ref['robinson'], - #'c2d-func' : func_c2d_, - #'c2d-data' : , + 'c-conv': True, + 'c-temp': 'fit', + 'c-desc': method['novotny2'], + 'c-ref' : ref['novotny1988'], + 'c2d-func' : func_c2d_novotny2, + 'c2d-data' : [0.4303, 1.242, 1.002, 1.389, 2.096, 1.810], 'm-conv': True, 'm-temp': 298.15, 'm-desc': method['abbas'], @@ -846,12 +872,12 @@ 'lioh' : { 'name' : "LiOH", 'mass' : 23.9486, - 'c-conv': False, - #'c-temp': , - #'c-desc': method[''], - #'c-ref' : ref['robinson'], - #'c2d-func' : func_c2d_, - #'c2d-data' : , + 'c-conv': True, + 'c-temp': 'fit', + 'c-desc': method['novotny2'], + 'c-ref' : ref['novotny1988'], + 'c2d-func' : func_c2d_novotny2, + 'c2d-data' : [0.3016, -0.4827, -0.6976, 2.786, -4.538, -5.916], 'm-conv': True, 'm-temp': 298.15, 'm-desc': method['abbas'], @@ -865,12 +891,12 @@ 'mgbr2' : { 'name' : "MgBr2", 'mass' : 184.1133, - 'c-conv': False, - #'c-temp': , - #'c-desc': method[''], - #'c-ref' : ref['robinson'], - #'c2d-func' : func_c2d_, - #'c2d-data' : , + 'c-conv': True, + 'c-temp': 'fit', + 'c-desc': method['novotny2'], + 'c-ref' : ref['novotny1988'], + 'c2d-func' : func_c2d_novotny2, + 'c2d-data' : [1.585, 1.676, 1.987, 7.343, 5.026, 5.966], 'm-conv': True, 'm-temp': 298.15, 'm-desc': method['abbas'], @@ -881,12 +907,12 @@ 'mgcl2' : { 'name' : "MgCl2", 'mass' : 95.2115, - 'c-conv': False, - #'c-temp': , - #'c-desc': method[''], - #'c-ref' : ref['robinson'], - #'c2d-func' : func_c2d_, - #'c2d-data' : , + 'c-conv': True, + 'c-temp': 'fit', + 'c-desc': method['novotny2'], + 'c-ref' : ref['novotny1988'], + 'c2d-func' : func_c2d_novotny2, + 'c2d-data' : [0.8099, 1.887, 2.315, 6.029, 7.449, 8.305], 'm-conv': True, 'm-temp': 298.15, 'm-desc': method['abbas'], @@ -897,12 +923,12 @@ 'mg(clo4)2' : { 'name' : "Mg(ClO4)2", 'mass' : 223.2069, - 'c-conv': False, - #'c-temp': , - #'c-desc': method[''], - #'c-ref' : ref['robinson'], - #'c2d-func' : func_c2d_, - #'c2d-data' : , + 'c-conv': True, + 'c-temp': 'fit', + 'c-desc': method['novotny2'], + 'c-ref' : ref['novotny1988'], + 'c2d-func' : func_c2d_novotny2, + 'c2d-data' : [1.694, 3.138, 1.278, 9.611, 8.639, 0.000], 'm-conv': True, 'm-temp': 298.15, 'm-desc': method['abbas'], @@ -913,12 +939,12 @@ 'mgi2' : { 'name' : "MgI2", 'mass' : 278.1140, - 'c-conv': False, - #'c-temp': , - #'c-desc': method[''], - #'c-ref' : ref['robinson'], - #'c2d-func' : func_c2d_, - #'c2d-data' : , + 'c-conv': True, + 'c-temp': 'fit', + 'c-desc': method['novotny2'], + 'c-ref' : ref['novotny1988'], + 'c2d-func' : func_c2d_novotny2, + 'c2d-data' : [2.357, 3.178, 2.723, 6.551, 12.35, 9.773], 'm-conv': True, 'm-temp': 298.15, 'm-desc': method['abbas'], @@ -929,12 +955,12 @@ 'mg(no3)2' : { 'name' : "Mg(NO3)2", 'mass' : 148.3151, - 'c-conv': False, - #'c-temp': , - #'c-desc': method[''], - #'c-ref' : ref['robinson'], - #'c2d-func' : func_c2d_, - #'c2d-data' : , + 'c-conv': True, + 'c-temp': 'fit', + 'c-desc': method['novotny2'], + 'c-ref' : ref['novotny1988'], + 'c2d-func' : func_c2d_novotny2, + 'c2d-data' : [1.190, 1.440, 0.1877, 8.257, -7.177, -16.99], 'm-conv': True, 'm-temp': 298.15, 'm-desc': method['abbas'], @@ -945,12 +971,12 @@ 'mgso4' : { 'name' : "MgSO4", 'mass' : 120.3683, - 'c-conv': False, - #'c-temp': , - #'c-desc': method[''], - #'c-ref' : ref['robinson'], - #'c2d-func' : func_c2d_, - #'c2d-data' : , + 'c-conv': True, + 'c-temp': 'fit', + 'c-desc': method['novotny2'], + 'c-ref' : ref['novotny1988'], + 'c2d-func' : func_c2d_novotny2, + 'c2d-data' : [1.437, 6.531, 5.263, 23.28, 39.11, 27.83], 'm-conv': True, 'm-temp': 298.15, 'm-desc': method['abbas'], @@ -965,11 +991,11 @@ 'name' : "NaAc", 'mass' : 82.03427, 'c-conv': True, - 'c-temp': 298.15, - 'c-desc': method['vrbka'], - 'c-ref' : ref['hamer1972'], - 'c2d-func' : func_c2d_vrbka, - 'c2d-data' : [0.99705, 0.038439, -7.9726e-06, -4.5312e-05], + 'c-temp': 'fit', + 'c-desc': method['novotny2'], + 'c-ref' : ref['novotny1988'], + 'c2d-func' : func_c2d_novotny2, + 'c2d-data' : [0.4364, 0.6740, 0.6482, 2.113, -0.9843, 0.000], 'm-conv': True, 'm-temp': 298.15, 'm-desc': method['vrbka'], @@ -981,11 +1007,11 @@ 'name' : "NaBr", 'mass' : 102.89377, 'c-conv': True, - 'c-temp': 298.15, - 'c-desc': method['vrbka'], - 'c-ref' : ref['heydweiller1909'], - 'c2d-func' : func_c2d_vrbka, - 'c2d-data' : [0.99713, 0.079414, 0.00093917, -9.3942e-06], + 'c-temp': 'fit', + 'c-desc': method['novotny2'], + 'c-ref' : ref['novotny1988'], + 'c2d-func' : func_c2d_novotny2, + 'c2d-data' : [0.8362, 1.872, 1.353, 2.847, 4.791, 3.413], 'm-conv': True, 'm-temp': 298.15, #'m-desc': method['vrbka'], @@ -1001,11 +1027,11 @@ 'name' : "NaCl", 'mass' : 58.44277, 'c-conv': True, - 'c-temp': 298.15, - 'c-desc': method['vrbka'], - 'c-ref' : ref['hamer1972'], - 'c2d-func' : func_c2d_vrbka, - 'c2d-data' : [0.99734, 0.039838, -0.00040913, -2.3178e-05], + 'c-temp': 'fit', + 'c-desc': method['novotny2'], + 'c-ref' : ref['novotny1988'], + 'c2d-func' : func_c2d_novotny2, + 'c2d-data' : [0.4485, 0.9634, 0.6136, 2.712, 1.009, 0.000], 'm-conv': True, 'm-temp': 298.15, #'m-desc': method['vrbka'], @@ -1020,12 +1046,12 @@ 'naclo4' : { 'name' : "NaClO4", 'mass' : 122.4407, - 'c-conv': False, - #'c-temp': , - #'c-desc': method[''], - #'c-ref' : ref['robinson'], - #'c2d-func' : func_c2d_, - #'c2d-data' : , + 'c-conv': True, + 'c-temp': 'fit', + 'c-desc': method['novotny2'], + 'c-ref' : ref['novotny1988'], + 'c2d-func' : func_c2d_novotny2, + 'c2d-data' : [0.8462, 3.788, 3.966, 3.025, 9.968, 11.13], 'm-conv': True, 'm-temp': 298.15, 'm-desc': method['abbas'], @@ -1038,11 +1064,11 @@ 'desc' : "25C; Robinson-Stokes; density up to 0.7M", 'mass' : 41.98817, 'c-conv': True, - 'c-temp': 298.15, - 'c-desc': method['vrbka'], - 'c-ref' : ref['robinson'], - 'c2d-func' : func_c2d_vrbka, - 'c2d-data' : [0.99715, 0.043573, -0.00165660, -1.0572E-04], + 'c-temp': 'fit', + 'c-desc': method['novotny2'], + 'c-ref' : ref['novotny1988'], + 'c2d-func' : func_c2d_novotny2, + 'c2d-data' : [0.4940, 2.985, 3.365, 4.752, 16.22, 18.72], 'm-conv': True, 'm-temp': 298.15, #'m-desc': method['vrbka'], @@ -1058,11 +1084,11 @@ 'name' : "NaI", 'mass' : 149.89427, 'c-conv': True, - 'c-temp': 298.15, - 'c-desc': method['vrbka'], - 'c-ref' : ref['hamer1972'], - 'c2d-func' : func_c2d_vrbka, - 'c2d-data' : [0.99692, 0.111910, 0.00068270, -0.00015616], + 'c-temp': 'fit', + 'c-desc': method['novotny2'], + 'c-ref' : ref['novotny1988'], + 'c2d-func' : func_c2d_novotny2, + 'c2d-data' : [1.196, 2.120, 1.396, 2.502, 5.095, 3.346], 'm-conv': True, 'm-temp': 298.15, #'m-desc': method['vrbka'], @@ -1077,12 +1103,12 @@ 'nano3' : { 'name' : "NaNO3", 'mass' : 84.9948, - 'c-conv': False, - #'c-temp': , - #'c-desc': method[''], - #'c-ref' : ref['robinson'], - #'c2d-func' : func_c2d_, - #'c2d-data' : , + 'c-conv': True, + 'c-temp': 'fit', + 'c-desc': method['novotny2'], + 'c-ref' : ref['novotny1988'], + 'c2d-func' : func_c2d_novotny2, + 'c2d-data' : [0.6298, 2.382, 1.520, 4.138, 6.626, 4.208], 'm-conv': True, 'm-temp': 298.15, 'm-desc': method['abbas'], @@ -1093,12 +1119,12 @@ 'naoh' : { 'name' : "NaOH", 'mass' : 39.9971, - 'c-conv': False, - #'c-temp': , - #'c-desc': method[''], - #'c-ref' : ref['robinson'], - #'c2d-func' : func_c2d_, - #'c2d-data' : , + 'c-conv': True, + 'c-temp': 'fit', + 'c-desc': method['novotny2'], + 'c-ref' : ref['novotny1988'], + 'c2d-func' : func_c2d_novotny2, + 'c2d-data' : [0.4916, 0.9064, 0.6308, 4.907, 1.633, 1.041], 'm-conv': True, 'm-temp': 298.15, 'm-desc': method['abbas'], @@ -1112,12 +1138,12 @@ 'nh4br' : { 'name' : "NH4Br", 'mass' : 97.9426, - 'c-conv': False, - #'c-temp': , - #'c-desc': method[''], - #'c-ref' : ref['robinson'], - #'c2d-func' : func_c2d_, - #'c2d-data' : , + 'c-conv': True, + 'c-temp': 298.15, + 'c-desc': method['novotny'], + 'c-ref' : ref['novotny1988'], + 'c2d-func' : func_c2d_novotny, + 'c2d-data' : [0.5498, 0.1038], 'm-conv': True, 'm-temp': 298.15, 'm-desc': method['abbas'], @@ -1128,12 +1154,12 @@ 'nh4cl' : { 'name' : "NH4Cl", 'mass' : 53.4917, - 'c-conv': False, - #'c-temp': , - #'c-desc': method[''], - #'c-ref' : ref['robinson'], - #'c2d-func' : func_c2d_, - #'c2d-data' : , + 'c-conv': True, + 'c-temp': 'fit', + 'c-desc': method['novotny2'], + 'c-ref' : ref['novotny1988'], + 'c2d-func' : func_c2d_novotny2, + 'c2d-data' : [0.2061, 1.577, 1.533, 2.556, 5.670, 5.082], 'm-conv': True, 'm-temp': 298.15, 'm-desc': method['abbas'], @@ -1144,12 +1170,12 @@ 'nh4clo4' : { 'name' : "NH4ClO4", 'mass' : 117.4894, - 'c-conv': False, - #'c-temp': , - #'c-desc': method[''], - #'c-ref' : ref['robinson'], - #'c2d-func' : func_c2d_, - #'c2d-data' : , + 'c-conv': True, + 'c-temp': 'fit', + 'c-desc': method['novotny2'], + 'c-ref' : ref['novotny1988'], + 'c2d-func' : func_c2d_novotny2, + 'c2d-data' : [0.6375, 5.744, 13.22, 2.497, 10.09, 46.34], 'm-conv': True, 'm-temp': 298.15, 'm-desc': method['abbas'], @@ -1160,12 +1186,12 @@ 'nh4i' : { 'name' : "NH4I", 'mass' : 144.9430, - 'c-conv': False, - #'c-temp': , - #'c-desc': method[''], - #'c-ref' : ref['robinson'], - #'c2d-func' : func_c2d_, - #'c2d-data' : , + 'c-conv': True, + 'c-temp': 'fit', + 'c-desc': method['novotny2'], + 'c-ref' : ref['novotny1988'], + 'c2d-func' : func_c2d_novotny2, + 'c2d-data' : [0.963, -0.8591, -3.218, -0.4009, -19.70, -30.20], 'm-conv': True, 'm-temp': 298.15, 'm-desc': method['abbas'], @@ -1176,12 +1202,12 @@ 'nh4no3' : { 'name' : "NH4NO3", 'mass' : 80.0435, - 'c-conv': False, - #'c-temp': , - #'c-desc': method[''], - #'c-ref' : ref['robinson'], - #'c2d-func' : func_c2d_, - #'c2d-data' : , + 'c-conv': True, + 'c-temp': 'fit', + 'c-desc': method['novotny2'], + 'c-ref' : ref['novotny1988'], + 'c2d-func' : func_c2d_novotny2, + 'c2d-data' : [0.3614, 1.446, 1.009, 1.898, 2.918, 1.870], 'm-conv': True, 'm-temp': 298.15, 'm-desc': method['abbas'], @@ -1196,11 +1222,11 @@ 'name' : "RbBr", 'mass' : 165.3718, 'c-conv': True, - 'c-temp': 298.15, - 'c-desc': method['vrbka'], - 'c-ref' : ref['unk'], - 'c2d-func' : func_c2d_vrbka, - 'c2d-data' : [0.99712, 0.125980, -0.00053707, -1.7308E-03], + 'c-temp': 'fit', + 'c-desc': method['novotny2'], + 'c-ref' : ref['novotny1988'], + 'c2d-func' : func_c2d_novotny2, + 'c2d-data' : [1.303, 1.609, 1.190, 2.820, 2.544, 0.000], 'm-conv': True, 'm-temp': 298.15, #'m-desc': method['vrbka'], @@ -1216,11 +1242,11 @@ 'name' : "RbCl", 'mass' : 120.9208, 'c-conv': True, - 'c-temp': 298.15, - 'c-desc': method['vrbka'], - 'c-ref' : ref['heydweiller1909'], - 'c2d-func' : func_c2d_vrbka, - 'c2d-data' : [0.99711, 0.089435, 0.00067859, 0.00022430], + 'c-temp': 'fit', + 'c-desc': method['novotny2'], + 'c-ref' : ref['novotny1988'], + 'c2d-func' : func_c2d_novotny2, + 'c2d-data' : [0.9251, 1.051, 0.3060, 3.330, 2.809, 0.000], 'm-conv': True, 'm-temp': 298.15, #'m-desc': method['vrbka'], @@ -1236,11 +1262,11 @@ 'name' : "RbF", 'mass' : 104.4662, 'c-conv': True, - 'c-temp': 298.15, - 'c-desc': method['vrbka'], - 'c-ref' : ref['hamer1972'], - 'c2d-func' : func_c2d_vrbka, - 'c2d-data' : [0.99712, 0.091253, -0.00227760, 3.5858E-04], + 'c-temp': 'fit', + 'c-desc': method['novotny2'], + 'c-ref' : ref['novotny1988'], + 'c2d-func' : func_c2d_novotny2, + 'c2d-data' : [0.9859, 1.589, 1.940, 3.972, 4.153, 4.878], 'm-conv': True, 'm-temp': 298.15, #'m-desc': method['vrbka'], @@ -1256,11 +1282,11 @@ 'name' : "RbI", 'mass' : 212.3723, 'c-conv': True, - 'c-temp': 298.15, - 'c-desc': method['vrbka'], - 'c-ref' : ref['unk'], - 'c2d-func' : func_c2d_vrbka, - 'c2d-data' : [0.99710, 0.162070, -0.00356030, 3.5235E-03], + 'c-temp': 'fit', + 'c-desc': method['novotny2'], + 'c-ref' : ref['novotny1988'], + 'c2d-func' : func_c2d_novotny2, + 'c2d-data' : [1.665, 0.8912, -0.7021, 2.708, -3.551, -12.94], 'm-conv': True, 'm-temp': 298.15, #'m-desc': method['vrbka'], @@ -1275,12 +1301,12 @@ 'rbno3' : { 'name' : "RbNO3", 'mass' : 147.4728, - 'c-conv': False, - #'c-temp': , - #'c-desc': method[''], - #'c-ref' : ref['robinson'], - #'c2d-func' : func_c2d_, - #'c2d-data' : , + 'c-conv': True, + 'c-temp': 'fit', + 'c-desc': method['novotny2'], + 'c-ref' : ref['novotny1988'], + 'c2d-func' : func_c2d_novotny2, + 'c2d-data' : [1.044, 1.294, 1.640, 0.7562, -0.1728, 2.592], 'm-conv': True, 'm-temp': 298.15, 'm-desc': method['abbas'], @@ -1294,12 +1320,12 @@ 'srbr2' : { 'name' : "SrBr2", 'mass' : 247.4292, - 'c-conv': False, - #'c-temp': , - #'c-desc': method[''], - #'c-ref' : ref['robinson'], - #'c2d-func' : func_c2d_, - #'c2d-data' : , + 'c-conv': True, + 'c-temp': 'fit', + 'c-desc': method['novotny2'], + 'c-ref' : ref['novotny1988'], + 'c2d-func' : func_c2d_novotny2, + 'c2d-data' : [2.200, 2.770, 2.119, 8.825, 7.717, 4.571], 'm-conv': True, 'm-temp': 298.15, 'm-desc': method['abbas'], @@ -1310,12 +1336,12 @@ 'srcl2' : { 'name' : "SrCl2", 'mass' : 158.5274, - 'c-conv': False, - #'c-temp': , - #'c-desc': method[''], - #'c-ref' : ref['robinson'], - #'c2d-func' : func_c2d_, - #'c2d-data' : , + 'c-conv': True, + 'c-temp': 'fit', + 'c-desc': method['novotny2'], + 'c-ref' : ref['novotny1988'], + 'c2d-func' : func_c2d_novotny2, + 'c2d-data' : [1.536, 4.157, 3.586, 14.63, 23.11, 18.94], 'm-conv': True, 'm-temp': 298.15, 'm-desc': method['abbas'], @@ -1326,12 +1352,12 @@ 'sr(clo4)2' : { 'name' : "Sr(ClO4)2", 'mass' : 286.5228, - 'c-conv': False, - #'c-temp': , - #'c-desc': method[''], - #'c-ref' : ref['robinson'], - #'c2d-func' : func_c2d_, - #'c2d-data' : , + 'c-conv': True, + 'c-temp': 298.15, + 'c-desc': method['novotny'], + 'c-ref' : ref['novotny1988'], + 'c2d-func' : func_c2d_novotny, + 'c2d-data' : [2.192, 0.9658], 'm-conv': True, 'm-temp': 298.15, 'm-desc': method['abbas'], @@ -1342,12 +1368,12 @@ 'sr(no3)2' : { 'name' : "Sr(NO3)2", 'mass' : 211.6310, - 'c-conv': False, - #'c-temp': , - #'c-desc': method[''], - #'c-ref' : ref['robinson'], - #'c2d-func' : func_c2d_, - #'c2d-data' : , + 'c-conv': True, + 'c-temp': 'fit', + 'c-desc': method['novotny2'], + 'c-ref' : ref['novotny1988'], + 'c2d-func' : func_c2d_novotny2, + 'c2d-data' : [1.800, 4.794, 3.631, 12.14, 18.35, 14.25], 'm-conv': True, 'm-temp': 298.15, 'm-desc': method['abbas'], diff -u prop_conv-0.2/prop_func.py prop_conv-0.2.1/prop_func.py --- prop_conv-0.2/prop_func.py 2009-06-16 09:31:54.000000000 +0200 +++ prop_conv-0.2.1/prop_func.py 2009-07-11 18:54:10.000000000 +0200 @@ -9,7 +9,7 @@ """ Module defining the conversion functions -revision of this file: 0.2.1 +revision of this file: 0.2.2 wat_temp2dens(stderr, T, unit) calculate water density at temperature T on K or C scale @@ -30,11 +30,11 @@ func_c2d_novotny(fe, molar, salt, rho_w, temp, mass) convert molarity to density using equation from J Chem Eng Data 1988, 33, 49-55 - 6 parameters, temperature effect taken into account, mass ignored + 2 parameters, temperature ignored, mass as well func_c2d_novotny2(fe, molar, salt, rho_w, temp, mass) convert molarity to density using equation from J Chem Eng Data 1988, 33, 49-55 - 2 parameters, temperature ignored, mass as well + 6 parameters, temperature effect taken into account, mass ignored """ from math import log as ln, exp @@ -84,6 +84,11 @@ # convert temperature to celsius t = T - 273.15 + + if (t < 0.0): + # fit works only for non-netagive temperatures due to the square root! + # set temperature to zero in such case + t = 0.0 rho_w = 999.65 + 2.0438 * 1e-1 * t - 6.174 * 1e-2 * t**1.5 @@ -169,6 +174,7 @@ phi_lr = 1.0 else: phi_lr = phi_mm * molar / (rho_w * molal) + #print("mm %f lr %f w %f c %f m %f" % (phi_mm, phi_lr, rho_w, molar, molal)) return(phi_lr) # ************************************************************************************************ @@ -228,45 +234,48 @@ # ************************************************************************************************ # ************************************************************************************************ -# conversion methods novotny & novotny2 - def func_c2d_novotny(fe, molar, fit_data, rho_w, temp, mass): """ converts molarity to density using the following formula - rho_salt = rho_water + A c + B c t + C c t**2 + D c**3/2 + E c**3/2 t + F c**3/2 t**2 - where A-F are parameters stored in this order in fit_data - T is temperature in degrees centigrade and the density is in kg/m**3 - temperature is taken into account, mass ignored + rho_salt = rho_water + A c + B c**3/2 + where A,B are parameters stored in this order in fit_data + density is in kg/m**3 + temperature is ignored, as well as mass + the parameters are stored as published in article and given in the respective table + they need to be multiplied with some constants! """ - + # convert water density to kg/m**3 rw = rho_w * 1000.0 - # and temperature to centigrades - t = temp - 273.15 - # calculate the solution density - rho_salt = rw + fit_data[0] * molar + fit_data[1] * molar * t + fit_data[2] * molar * t**2 + fit_data[3] * molar**1.5 + fit_data[4] * molar**1.5 * t + fit_data[5] * molar**1.5 * t**2 + # calculate the solution density + rho_salt = rw + 100.0 * fit_data[0] * molar - 10.0 * fit_data[1] * molar**1.5 # convert back to kg/l or g/cm**3 - rho_salt /= 1000. + rho_salt /= 1000 return(rho_salt) # ************************************************************************************************ +# conversion methods novotny & novotny2 def func_c2d_novotny2(fe, molar, fit_data, rho_w, temp, mass): """ converts molarity to density using the following formula - rho_salt = rho_water + A c + B c**3/2 - where A,B are parameters stored in this order in fit_data - density is in kg/m**3 - temperature is ignored, as well as mass + rho_salt = rho_water + A c + B c t + C c t**2 + D c**3/2 + E c**3/2 t + F c**3/2 t**2 + where A-F are parameters stored in this order in fit_data + T is temperature in degrees centigrade and the density is in kg/m**3 + temperature is taken into account, mass ignored + the parameters are stored as published in article and given in the respective table + they need to be multiplied with some constants! """ - + # convert water density to kg/m**3 rw = rho_w * 1000.0 - # calculate the solution density - rho_salt = rw + fit_data[0] * molar + fit_data[1] * molar**1.5 + # and temperature to centigrades + t = temp - 273.15 + # calculate the solution density + rho_salt = rw + 100.0 * fit_data[0] * molar - 0.1 * fit_data[1] * molar * t + 0.001 * fit_data[2] * molar * t**2 - fit_data[3] * molar**1.5 + 0.01 * fit_data[4] * molar**1.5 * t - 0.0001 * fit_data[5] * molar**1.5 * t**2 # convert back to kg/l or g/cm**3 - rho_salt /= 1000 + rho_salt /= 1000. return(rho_salt)