#!pip install Thermobar
import numpy as np
import pandas as pd
import matplotlib.pyplot as plt
import Thermobar as pt
pd.options.display.max_columns = None
out=pt.import_excel('Amphibole_Liquids.xlsx', sheet_name="Amp-Liq")
my_input=out['my_input']
Amps=out['Amps']
Liqs=out['Liqs']
display(Amps.head())
display(Liqs.head())
SiO2_Amp | TiO2_Amp | Al2O3_Amp | FeOt_Amp | MnO_Amp | MgO_Amp | CaO_Amp | Na2O_Amp | K2O_Amp | Cr2O3_Amp | F_Amp | Cl_Amp | Sample_ID_Amp | |
---|---|---|---|---|---|---|---|---|---|---|---|---|---|
0 | 40.57 | 2.45 | 12.82 | 13.11 | 0.26 | 13.02 | 11.63 | 2.20 | 0.92 | 0.00 | 0.0 | 0.0 | probe1 |
1 | 39.45 | 1.88 | 10.80 | 11.85 | 0.00 | 11.32 | 10.94 | 2.04 | 0.75 | 0.00 | 0.0 | 0.0 | probe2 |
2 | 42.88 | 3.46 | 14.28 | 15.99 | 0.54 | 14.25 | 12.12 | 2.43 | 1.18 | 0.03 | 0.0 | 0.0 | probe3 |
3 | 42.20 | 2.75 | 11.10 | 13.10 | 0.39 | 13.55 | 11.07 | 2.27 | 0.95 | 0.01 | 0.0 | 0.0 | probe4 |
4 | 40.37 | 2.28 | 10.06 | 11.76 | 0.19 | 12.41 | 10.40 | 2.09 | 0.82 | 0.00 | 0.0 | 0.0 | probe5 |
SiO2_Liq | TiO2_Liq | Al2O3_Liq | FeOt_Liq | MnO_Liq | MgO_Liq | CaO_Liq | Na2O_Liq | K2O_Liq | Cr2O3_Liq | P2O5_Liq | H2O_Liq | Fe3Fet_Liq | NiO_Liq | CoO_Liq | CO2_Liq | Sample_ID_Liq | |
---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
0 | 62.317403 | 0.592583 | 17.015042 | 5.578974 | 0.147384 | 1.493784 | 5.199067 | 3.799517 | 3.840125 | 0 | 0.320967 | 5 | 0.0 | 0.0 | 0.0 | 0.0 | probe_s2_1 |
1 | 63.410655 | 0.567627 | 16.682223 | 5.211648 | 0.139473 | 1.343074 | 4.680291 | 3.797226 | 4.118336 | 0 | 0.320854 | 5 | 0.0 | 0.0 | 0.0 | 0.0 | probe_s2_2 |
2 | 64.978351 | 0.531840 | 16.204967 | 4.684912 | 0.128130 | 1.126960 | 3.936379 | 3.793940 | 4.517285 | 0 | 0.320691 | 5 | 0.0 | 0.0 | 0.0 | 0.0 | probe_s2_3 |
3 | 60.953715 | 0.623712 | 17.430191 | 6.037164 | 0.157251 | 1.681775 | 5.846172 | 3.802375 | 3.493093 | 0 | 0.321109 | 5 | 0.0 | 0.0 | 0.0 | 0.0 | probe_s2_4 |
4 | 60.188394 | 0.641183 | 17.663178 | 6.294307 | 0.162789 | 1.787278 | 6.209337 | 3.803979 | 3.298333 | 0 | 0.321189 | 5 | 0.0 | 0.0 | 0.0 | 0.0 | probe_s2_5 |
help(pt.calculate_amp_only_press)
Help on function calculate_amp_only_press in module Thermobar.amphibole: calculate_amp_only_press(amp_comps=None, equationP=None, T=None, deltaNNO=None, classification=False, Ridolfi_Filter=True) Amphibole-only barometry, returns pressure in kbar. Parameters ----------- amp_comps: pandas.DataFrame Amphibole compositions with column headings SiO2_Amp, MgO_Amp etc. EquationP: str | P_Mutch2016 (T-independent) | P_Ridolfi2012_1a (T-independent) | P_Ridolfi2012_1b (T-independent) | P_Ridolfi2012_1c (T-independent) | P_Ridolfi2012_1d (T-independent) | P_Ridolfi2012_1e (T-independent) | P_Ridolfi2021 - (T-independent)- Uses new algorithm in 2021 paper to select pressures from equations 1a-e. | P_Ridolfi2010 (T-independent) | P_Hammarstrom1986_eq1 (T-independent) | P_Hammarstrom1986_eq2 (T-independent) | P_Hammarstrom1986_eq3 (T-independent) | P_Hollister1987 (T-independent) | P_Johnson1989 (T-independent) | P_Blundy1990 (T-independent) | P_Schmidt1992 (T-independent) | P_Anderson1995 (*T-dependent*) T: float, int, pandas.Series, str ("Solve") Temperature in Kelvin Only needed for T-sensitive barometers. If enter T="Solve", returns a partial function Else, enter an integer, float, or panda series Returns ------- pandas series Pressure in kbar
P_Ridolfi2021=pt.calculate_amp_only_press(amp_comps=Amps, equationP="P_Ridolfi2021")
P_Ridolfi2021.head()
P_kbar_calc | Input_Check | Fail Msg | classification | equation | H2O_calc | Fe2O3_calc | FeO_calc | Total_recalc | Sum_input | SiO2_Amp_cat_prop | MgO_Amp_cat_prop | FeOt_Amp_cat_prop | CaO_Amp_cat_prop | Al2O3_Amp_cat_prop | Na2O_Amp_cat_prop | K2O_Amp_cat_prop | MnO_Amp_cat_prop | TiO2_Amp_cat_prop | Cr2O3_Amp_cat_prop | F_Amp_cat_prop | Cl_Amp_cat_prop | Si_Amp_13_cat | Mg_Amp_13_cat | Fet_Amp_13_cat | Ca_Amp_13_cat | Al_Amp_13_cat | Na_Amp_13_cat | K_Amp_13_cat | Mn_Amp_13_cat | Ti_Amp_13_cat | Cr_Amp_13_cat | F_Amp_13_cat | Cl_Amp_13_cat | cation_sum_Si_Mg | Si_T | Al_IV_T | Ti_T | Cr_C | Fe3_C | Mg_C | Fe2_C | Mn_C | Ca_B | Na_B | Na_A | K_A | Al_VI_C | Ti_C | Charge | Fe3_calc | Fe2_calc | O=F,Cl | Total | Mgno_Fe2 | Mgno_FeT | Na_calc | B_Sum | A_Sum | class | APE | |
---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
0 | 4.572174 | True | Mg-hastingsite | (1b+1c)/2 | 1.917780 | 7.000433 | 6.810921 | 99.599134 | 96.98 | 0.675221 | 0.323045 | 0.182474 | 0.207386 | 0.251469 | 0.070992 | 0.019534 | 0.003665 | 0.030664 | 0.000000 | 0.0 | 0.0 | 5.985442 | 2.863604 | 1.617522 | 1.838356 | 2.229123 | 0.629301 | 0.173157 | 0.032490 | 0.271819 | 0.000000 | 0.0 | 0.0 | 1.466538 | 5.985442 | 2.014558 | 0.000000 | 0.000000 | 0.777185 | 2.863604 | 0.840337 | 0.032490 | 1.838356 | 0.161644 | 0.467656 | 0.173157 | 0.214565 | 0.271819 | 45.222815 | 0.777185 | 0.840337 | -0.0 | NaN | 0.773124 | 0.639037 | 0.161644 | 2.0 | 0.640813 | N/A | 28.333126 | |
1 | NaN | False | Recalc Total<98.5 | Pargasite | 1b | 0.000000 | 0.000000 | 10.836615 | 88.016615 | 89.03 | 0.656581 | 0.280865 | 0.164936 | 0.195082 | 0.211846 | 0.065829 | 0.015924 | 0.000000 | 0.023530 | 0.000000 | 0.0 | 0.0 | 6.380489 | 2.729380 | 1.602808 | 1.895758 | 2.058664 | 0.639707 | 0.154749 | 0.000000 | 0.228659 | 0.000000 | 0.0 | 0.0 | 1.337758 | 6.380489 | 1.619511 | 0.000000 | 0.000000 | 0.137068 | 2.729380 | 1.465740 | 0.000000 | 1.895758 | 0.104242 | 0.535465 | 0.154749 | 0.439153 | 0.228659 | 45.862932 | 0.137068 | 1.465740 | 0.0 | 0.0 | 0.650608 | 0.630023 | 0.104242 | 2.0 | 0.690215 | N/A | NaN |
2 | NaN | False | Recalc Total>102 | Mg-hastingsite | 1c+1d | 2.120043 | 13.095088 | 4.206872 | 110.592004 | 107.16 | 0.713668 | 0.353563 | 0.222559 | 0.216124 | 0.280107 | 0.078414 | 0.025054 | 0.007612 | 0.043305 | 0.000395 | 0.0 | 0.0 | 5.722690 | 2.835117 | 1.784638 | 1.733032 | 2.246096 | 0.628776 | 0.200904 | 0.061042 | 0.347252 | 0.003165 | 0.0 | 0.0 | 1.621209 | 5.722690 | 2.246096 | 0.031214 | 0.003165 | 1.315111 | 2.835117 | 0.469527 | 0.061042 | 1.733032 | 0.266968 | 0.361808 | 0.200904 | 0.000000 | 0.316038 | 44.684889 | 1.315111 | 0.469527 | -0.0 | NaN | 0.857919 | 0.613694 | 0.266968 | 2.0 | 0.562712 | N/A | 53.674852 |
3 | NaN | False | APE >60 | Mg-hastingsite | 1b | 1.933630 | 7.604246 | 6.257602 | 100.085478 | 97.39 | 0.702350 | 0.336195 | 0.182334 | 0.197400 | 0.217730 | 0.073251 | 0.020171 | 0.005498 | 0.034419 | 0.000132 | 0.0 | 0.0 | 6.174890 | 2.955744 | 1.603040 | 1.735493 | 1.914232 | 0.644002 | 0.177338 | 0.048336 | 0.302602 | 0.001157 | 0.0 | 0.0 | 1.478658 | 6.174890 | 1.825110 | 0.000000 | 0.001157 | 0.837300 | 2.955744 | 0.765739 | 0.048336 | 1.735493 | 0.264507 | 0.379495 | 0.177338 | 0.089122 | 0.302602 | 45.162700 | 0.837300 | 0.765739 | -0.0 | NaN | 0.794238 | 0.648362 | 0.264507 | 2.0 | 0.556833 | N/A | 60.173092 |
4 | NaN | False | Recalc Total<98.5 | Mg-hastingsite | 1b | 1.794195 | 4.540852 | 7.674083 | 92.629130 | 90.38 | 0.671893 | 0.307910 | 0.163683 | 0.185453 | 0.197330 | 0.067442 | 0.017411 | 0.002678 | 0.028536 | 0.000000 | 0.0 | 0.0 | 6.366185 | 2.917447 | 1.550901 | 1.757165 | 1.869706 | 0.639015 | 0.164966 | 0.025378 | 0.270382 | 0.000000 | 0.0 | 0.0 | 1.372031 | 6.366185 | 1.633815 | 0.000000 | 0.000000 | 0.538848 | 2.917447 | 1.012053 | 0.025378 | 1.757165 | 0.242835 | 0.396180 | 0.164966 | 0.235891 | 0.270382 | 45.461152 | 0.538848 | 1.012053 | -0.0 | NaN | 0.742447 | 0.652914 | 0.242835 | 2.0 | 0.561146 | N/A | 36.692839 |
P_Ridolfi2021=pt.calculate_amp_only_press(amp_comps=Amps, equationP="P_Ridolfi2021",
Ridolfi_Filter=False)
P_Ridolfi2021.head()
P_kbar_calc | Input_Check | Fail Msg | classification | equation | H2O_calc | Fe2O3_calc | FeO_calc | Total_recalc | Sum_input | SiO2_Amp_cat_prop | MgO_Amp_cat_prop | FeOt_Amp_cat_prop | CaO_Amp_cat_prop | Al2O3_Amp_cat_prop | Na2O_Amp_cat_prop | K2O_Amp_cat_prop | MnO_Amp_cat_prop | TiO2_Amp_cat_prop | Cr2O3_Amp_cat_prop | F_Amp_cat_prop | Cl_Amp_cat_prop | Si_Amp_13_cat | Mg_Amp_13_cat | Fet_Amp_13_cat | Ca_Amp_13_cat | Al_Amp_13_cat | Na_Amp_13_cat | K_Amp_13_cat | Mn_Amp_13_cat | Ti_Amp_13_cat | Cr_Amp_13_cat | F_Amp_13_cat | Cl_Amp_13_cat | cation_sum_Si_Mg | Si_T | Al_IV_T | Ti_T | Cr_C | Fe3_C | Mg_C | Fe2_C | Mn_C | Ca_B | Na_B | Na_A | K_A | Al_VI_C | Ti_C | Charge | Fe3_calc | Fe2_calc | O=F,Cl | Total | Mgno_Fe2 | Mgno_FeT | Na_calc | B_Sum | A_Sum | class | APE | |
---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
0 | 4.572174 | True | Mg-hastingsite | (1b+1c)/2 | 1.917780 | 7.000433 | 6.810921 | 99.599134 | 96.98 | 0.675221 | 0.323045 | 0.182474 | 0.207386 | 0.251469 | 0.070992 | 0.019534 | 0.003665 | 0.030664 | 0.000000 | 0.0 | 0.0 | 5.985442 | 2.863604 | 1.617522 | 1.838356 | 2.229123 | 0.629301 | 0.173157 | 0.032490 | 0.271819 | 0.000000 | 0.0 | 0.0 | 1.466538 | 5.985442 | 2.014558 | 0.000000 | 0.000000 | 0.777185 | 2.863604 | 0.840337 | 0.032490 | 1.838356 | 0.161644 | 0.467656 | 0.173157 | 0.214565 | 0.271819 | 45.222815 | 0.777185 | 0.840337 | -0.0 | NaN | 0.773124 | 0.639037 | 0.161644 | 2.0 | 0.640813 | N/A | 28.333126 | |
1 | NaN | False | Recalc Total<98.5 | Pargasite | 1b | 0.000000 | 0.000000 | 10.836615 | 88.016615 | 89.03 | 0.656581 | 0.280865 | 0.164936 | 0.195082 | 0.211846 | 0.065829 | 0.015924 | 0.000000 | 0.023530 | 0.000000 | 0.0 | 0.0 | 6.380489 | 2.729380 | 1.602808 | 1.895758 | 2.058664 | 0.639707 | 0.154749 | 0.000000 | 0.228659 | 0.000000 | 0.0 | 0.0 | 1.337758 | 6.380489 | 1.619511 | 0.000000 | 0.000000 | 0.137068 | 2.729380 | 1.465740 | 0.000000 | 1.895758 | 0.104242 | 0.535465 | 0.154749 | 0.439153 | 0.228659 | 45.862932 | 0.137068 | 1.465740 | 0.0 | 0.0 | 0.650608 | 0.630023 | 0.104242 | 2.0 | 0.690215 | N/A | NaN |
2 | 6.203253 | False | Recalc Total>102 | Mg-hastingsite | 1c+1d | 2.120043 | 13.095088 | 4.206872 | 110.592004 | 107.16 | 0.713668 | 0.353563 | 0.222559 | 0.216124 | 0.280107 | 0.078414 | 0.025054 | 0.007612 | 0.043305 | 0.000395 | 0.0 | 0.0 | 5.722690 | 2.835117 | 1.784638 | 1.733032 | 2.246096 | 0.628776 | 0.200904 | 0.061042 | 0.347252 | 0.003165 | 0.0 | 0.0 | 1.621209 | 5.722690 | 2.246096 | 0.031214 | 0.003165 | 1.315111 | 2.835117 | 0.469527 | 0.061042 | 1.733032 | 0.266968 | 0.361808 | 0.200904 | 0.000000 | 0.316038 | 44.684889 | 1.315111 | 0.469527 | -0.0 | NaN | 0.857919 | 0.613694 | 0.266968 | 2.0 | 0.562712 | N/A | 53.674852 |
3 | 3.228704 | False | APE >60 | Mg-hastingsite | 1b | 1.933630 | 7.604246 | 6.257602 | 100.085478 | 97.39 | 0.702350 | 0.336195 | 0.182334 | 0.197400 | 0.217730 | 0.073251 | 0.020171 | 0.005498 | 0.034419 | 0.000132 | 0.0 | 0.0 | 6.174890 | 2.955744 | 1.603040 | 1.735493 | 1.914232 | 0.644002 | 0.177338 | 0.048336 | 0.302602 | 0.001157 | 0.0 | 0.0 | 1.478658 | 6.174890 | 1.825110 | 0.000000 | 0.001157 | 0.837300 | 2.955744 | 0.765739 | 0.048336 | 1.735493 | 0.264507 | 0.379495 | 0.177338 | 0.089122 | 0.302602 | 45.162700 | 0.837300 | 0.765739 | -0.0 | NaN | 0.794238 | 0.648362 | 0.264507 | 2.0 | 0.556833 | N/A | 60.173092 |
4 | 2.761702 | False | Recalc Total<98.5 | Mg-hastingsite | 1b | 1.794195 | 4.540852 | 7.674083 | 92.629130 | 90.38 | 0.671893 | 0.307910 | 0.163683 | 0.185453 | 0.197330 | 0.067442 | 0.017411 | 0.002678 | 0.028536 | 0.000000 | 0.0 | 0.0 | 6.366185 | 2.917447 | 1.550901 | 1.757165 | 1.869706 | 0.639015 | 0.164966 | 0.025378 | 0.270382 | 0.000000 | 0.0 | 0.0 | 1.372031 | 6.366185 | 1.633815 | 0.000000 | 0.000000 | 0.538848 | 2.917447 | 1.012053 | 0.025378 | 1.757165 | 0.242835 | 0.396180 | 0.164966 | 0.235891 | 0.270382 | 45.461152 | 0.538848 | 1.012053 | -0.0 | NaN | 0.742447 | 0.652914 | 0.242835 | 2.0 | 0.561146 | N/A | 36.692839 |
P_Mutch2016=pt.calculate_amp_only_press(amp_comps=Amps, equationP="P_Mutch2016")
P_Mutch2016.head()
P_kbar_calc | Si_T | Al_T | Al_C | Ti_C | Mg_C | Fe3_C | Fe2_C | Mn_C | Cr_C | Mg_B | Fe2_B | Mn_B | Na_B | Ca_B | Na_A | K_A | Al_tot | |
---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
0 | 6.252577 | 6.025054 | 1.974946 | 0.268940 | 0.273685 | 2.882541 | 0.477503 | 1.097331 | 0.000000e+00 | 0.00000 | 0.0 | 0.053392 | 0.032705 | 0.063319 | 1.850584 | 0.570150 | 0.174302 | 2.243886 |
1 | 5.416489 | 6.393160 | 1.606840 | 0.455922 | 0.229169 | 2.734787 | 0.045632 | 1.534490 | 0.000000e+00 | 0.00000 | 0.0 | 0.025869 | 0.000000 | 0.074545 | 1.899586 | 0.566437 | 0.155056 | 2.062763 |
2 | 6.380755 | 5.784745 | 2.215255 | 0.055209 | 0.351103 | 2.865846 | 0.830090 | 0.894551 | 0.000000e+00 | 0.00320 | 0.0 | 0.079348 | 0.061703 | 0.107065 | 1.751884 | 0.528533 | 0.203081 | 2.270464 |
3 | 4.867111 | 6.242718 | 1.757282 | 0.177987 | 0.306001 | 2.988196 | 0.340790 | 1.185856 | -8.881784e-16 | 0.00117 | 0.0 | 0.094001 | 0.048866 | 0.102516 | 1.754616 | 0.548564 | 0.179285 | 1.935268 |
4 | 4.662231 | 6.420595 | 1.579405 | 0.306290 | 0.272760 | 2.942367 | 0.149918 | 1.328664 | 0.000000e+00 | 0.00000 | 0.0 | 0.085573 | 0.025595 | 0.116590 | 1.772242 | 0.527891 | 0.166375 | 1.885695 |
P_Put2016_5kbar=pt.calculate_amp_only_temp(amp_comps=Amps, equationT="T_Put2016_eq6", P=5)
P_Put2016_5kbar.head()
0 1222.719936 1 1182.392756 2 1243.702036 3 1205.288448 4 1186.384118 dtype: float64
PT_Mutch=pt.calculate_amp_only_press_temp(amp_comps=Amps, equationT="T_Put2016_eq6",
equationP="P_Mutch2016")
PT_Mutch.head()
P_kbar_calc | T_K_calc | SiO2_Amp | TiO2_Amp | Al2O3_Amp | FeOt_Amp | MnO_Amp | MgO_Amp | CaO_Amp | Na2O_Amp | K2O_Amp | Cr2O3_Amp | F_Amp | Cl_Amp | Sample_ID_Amp | |
---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
0 | 6.252577 | 1225.530720 | 40.57 | 2.45 | 12.82 | 13.11 | 0.26 | 13.02 | 11.63 | 2.20 | 0.92 | 0.00 | 0.0 | 0.0 | probe1 |
1 | 5.416489 | 1183.327357 | 39.45 | 1.88 | 10.80 | 11.85 | 0.00 | 11.32 | 10.94 | 2.04 | 0.75 | 0.00 | 0.0 | 0.0 | probe2 |
2 | 6.380755 | 1246.800450 | 42.88 | 3.46 | 14.28 | 15.99 | 0.54 | 14.25 | 12.12 | 2.43 | 1.18 | 0.03 | 0.0 | 0.0 | probe3 |
3 | 4.867111 | 1204.990244 | 42.20 | 2.75 | 11.10 | 13.10 | 0.39 | 13.55 | 11.07 | 2.27 | 0.95 | 0.01 | 0.0 | 0.0 | probe4 |
4 | 4.662231 | 1185.626165 | 40.37 | 2.28 | 10.06 | 11.76 | 0.19 | 12.41 | 10.40 | 2.09 | 0.82 | 0.00 | 0.0 | 0.0 | probe5 |
PT_Ridolfi=pt.calculate_amp_only_press_temp(amp_comps=Amps, equationT="T_Ridolfi2012",
equationP="P_Ridolfi2021")
PT_Ridolfi.head()
P_kbar_calc | T_K_calc | Input_Check | Fail Msg | classification | equation | SiO2_Amp | TiO2_Amp | Al2O3_Amp | FeOt_Amp | MnO_Amp | MgO_Amp | CaO_Amp | Na2O_Amp | K2O_Amp | Cr2O3_Amp | F_Amp | Cl_Amp | Sample_ID_Amp | |
---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
0 | 4.572174 | 1214.531361 | True | Mg-hastingsite | (1b+1c)/2 | 40.57 | 2.45 | 12.82 | 13.11 | 0.26 | 13.02 | 11.63 | 2.20 | 0.92 | 0.00 | 0.0 | 0.0 | probe1 | |
1 | NaN | NaN | False | Recalc Total<98.5 | Pargasite | 1b | 39.45 | 1.88 | 10.80 | 11.85 | 0.00 | 11.32 | 10.94 | 2.04 | 0.75 | 0.00 | 0.0 | 0.0 | probe2 |
2 | NaN | NaN | False | Recalc Total>102 | Mg-hastingsite | 1c+1d | 42.88 | 3.46 | 14.28 | 15.99 | 0.54 | 14.25 | 12.12 | 2.43 | 1.18 | 0.03 | 0.0 | 0.0 | probe3 |
3 | NaN | NaN | False | APE >60 | Mg-hastingsite | 1b | 42.20 | 2.75 | 11.10 | 13.10 | 0.39 | 13.55 | 11.07 | 2.27 | 0.95 | 0.01 | 0.0 | 0.0 | probe4 |
4 | NaN | NaN | False | Recalc Total<98.5 | Mg-hastingsite | 1b | 40.37 | 2.28 | 10.06 | 11.76 | 0.19 | 12.41 | 10.40 | 2.09 | 0.82 | 0.00 | 0.0 | 0.0 | probe5 |
PT_Ridolfi=pt.calculate_amp_only_press_temp(amp_comps=Amps, equationT="T_Ridolfi2012",
equationP="P_Ridolfi2021", Ridolfi_Filter=False)
PT_Ridolfi.head()
P_kbar_calc | T_K_calc | Input_Check | Fail Msg | classification | equation | SiO2_Amp | TiO2_Amp | Al2O3_Amp | FeOt_Amp | MnO_Amp | MgO_Amp | CaO_Amp | Na2O_Amp | K2O_Amp | Cr2O3_Amp | F_Amp | Cl_Amp | Sample_ID_Amp | |
---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
0 | 4.572174 | 1214.531361 | True | Mg-hastingsite | (1b+1c)/2 | 40.57 | 2.45 | 12.82 | 13.11 | 0.26 | 13.02 | 11.63 | 2.20 | 0.92 | 0.00 | 0.0 | 0.0 | probe1 | |
1 | NaN | NaN | False | Recalc Total<98.5 | Pargasite | 1b | 39.45 | 1.88 | 10.80 | 11.85 | 0.00 | 11.32 | 10.94 | 2.04 | 0.75 | 0.00 | 0.0 | 0.0 | probe2 |
2 | 6.203253 | 1289.245454 | False | Recalc Total>102 | Mg-hastingsite | 1c+1d | 42.88 | 3.46 | 14.28 | 15.99 | 0.54 | 14.25 | 12.12 | 2.43 | 1.18 | 0.03 | 0.0 | 0.0 | probe3 |
3 | 3.228704 | 1212.306099 | False | APE >60 | Mg-hastingsite | 1b | 42.20 | 2.75 | 11.10 | 13.10 | 0.39 | 13.55 | 11.07 | 2.27 | 0.95 | 0.01 | 0.0 | 0.0 | probe4 |
4 | 2.761702 | 1165.913034 | False | Recalc Total<98.5 | Mg-hastingsite | 1b | 40.37 | 2.28 | 10.06 | 11.76 | 0.19 | 12.41 | 10.40 | 2.09 | 0.82 | 0.00 | 0.0 | 0.0 | probe5 |
help(pt.calculate_amp_liq_temp)
Help on function calculate_amp_liq_temp in module Thermobar.amphibole: calculate_amp_liq_temp(*, amp_comps=None, liq_comps=None, meltmatch=None, equationT=None, P=None, H2O_Liq=None, eq_tests=False) Amphibole-liquid thermometers. Returns temperature in Kelvin. Parameters ------- amp_comps: pandas DataFrame amphibole compositions (SiO2_Amp, TiO2_Amp etc.) liq_comps: pandas DataFrame liquid compositions (SiO2_Liq, TiO2_Liq etc.) equationT: str T_Put2016_eq4a_amp_sat (P-independent, H2O-dep through hydrous fractions) T_Put2016_eq4b (P-independent, H2O-dep) T_Put2016_eq9 (P-independent, H2O-dep through hydrous fractions) P: float, int, pandas.Series, str ("Solve") Pressure in kbar Only needed for P-sensitive thermometers. If enter P="Solve", returns a partial function Else, enter an integer, float, or panda series eq_tests: bool. Default False If True, also calcualtes Kd Fe-Mg, which Putirka (2016) suggest as an equilibrium test. Returns ------- pandas.core.series.Series Temperature in Kelvin
eq4a_T=pt.calculate_amp_liq_temp(liq_comps=Liqs, amp_comps=Amps, equationT="T_Put2016_eq4a_amp_sat")
eq4a_T.head()
0 1228.795223 1 1226.300156 2 1221.844038 3 1233.595436 4 1233.106477 dtype: float64
eq4a_T_EqTest=pt.calculate_amp_liq_temp(liq_comps=Liqs, amp_comps=Amps, equationT="T_Put2016_eq4a_amp_sat",
eq_tests=True)
eq4a_T_EqTest.head()
T_K_calc | Kd-Fe-Mg | Eq Putirka 2016? | |
---|---|---|---|
0 | 1228.795223 | 0.269594 | Y |
1 | 1226.300156 | 0.269763 | Y |
2 | 1221.844038 | 0.269914 | Y |
3 | 1233.595436 | 0.269310 | Y |
4 | 1233.106477 | 0.269070 | Y |
eq4a_T_1H2O=pt.calculate_amp_liq_temp(liq_comps=Liqs, amp_comps=Amps, equationT="T_Put2016_eq4a_amp_sat", H2O_Liq=1)
eq4a_T_1H2O.head()
0 1229.395340 1 1229.204834 2 1228.025620 3 1231.299927 4 1229.196688 dtype: float64
eq7a_T_1H2O=pt.calculate_amp_liq_press(liq_comps=Liqs, amp_comps=Amps, equationP="P_Put2016_eq7a", H2O_Liq=1)
eq7a_T_1H2O.head()
0 4.328014 1 2.960536 2 5.182170 3 3.167717 4 2.728212 dtype: float64
eq7a_eq4b=pt.calculate_amp_liq_press_temp(liq_comps=Liqs, amp_comps=Amps, equationP="P_Put2016_eq7a",
equationT="T_Put2016_eq4b")
eq7a_eq4b.head()
Youve selected a P-independent function Youve selected a T-independent function
P_kbar_calc | T_K_calc | |
---|---|---|
0 | 6.168027 | 1202.507284 |
1 | 4.801223 | 1189.376371 |
2 | 7.023825 | 1185.097051 |
3 | 5.006890 | 1216.975219 |
4 | 4.566914 | 1219.944334 |
eq7a_eq4b_1H2O=pt.calculate_amp_liq_press_temp(liq_comps=Liqs, amp_comps=Amps, equationP="P_Put2016_eq7a",
equationT="T_Put2016_eq4b", H2O_Liq=1)
eq7a_eq4b_1H2O.head()
Youve selected a P-independent function Youve selected a T-independent function
P_kbar_calc | T_K_calc | |
---|---|---|
0 | 4.328014 | 1192.934086 |
1 | 2.960536 | 1180.068037 |
2 | 5.182170 | 1175.871630 |
3 | 3.167717 | 1207.106379 |
4 | 2.728212 | 1210.015416 |
eq7a_eq4b_1H2O_EqTests=pt.calculate_amp_liq_press_temp(liq_comps=Liqs, amp_comps=Amps, equationP="P_Put2016_eq7a",
equationT="T_Put2016_eq4b", H2O_Liq=1, eq_tests=True)
eq7a_eq4b_1H2O_EqTests.head()
Youve selected a P-independent function Youve selected a T-independent function
P_kbar_calc | T_K_calc | Kd-Fe-Mg | Eq Putirka 2016? | |
---|---|---|---|---|
0 | 4.328014 | 1192.934086 | 0.269594 | Y |
1 | 2.960536 | 1180.068037 | 0.269763 | Y |
2 | 5.182170 | 1175.871630 | 0.269914 | Y |
3 | 3.167717 | 1207.106379 | 0.269310 | Y |
4 | 2.728212 | 1210.015416 | 0.269070 | Y |
Melt_Comps=pt.calculate_amp_only_melt_comps(amp_comps=Amps)
Melt_Comps.head()
c:\users\penny\onedrive - oregon state university\postdoc\pymme\mybarometers\thermobar_outer\src\Thermobar\amphibole.py:229: UserWarning: You must enter a value for T in Kelvin to get results from equation3 and 5 from Zhang, and SiO2 from Putrka (2016) w.warn('You must enter a value for T in Kelvin to get results from equation3 and 5 from Zhang, and SiO2 from Putrka (2016)')
SiO2_Eq1_Zhang17 | SiO2_Eq2_Zhang17 | SiO2_Eq4_Zhang17 | TiO2_Eq6_Zhang17 | FeO_Eq7_Zhang17 | MgO_Eq9_Zhang17 | CaO_Eq10_Zhang17 | CaO_Eq11_Zhang17 | K2O_Eq12_Zhang17 | K2O_Eq13_Zhang17 | Al2O3_Eq14_Zhang17 | H2O_Ridolfi21 | deltaNNO_Ridolfi21 | Si_Amp_cat_23ox | Mg_Amp_cat_23ox | Fet_Amp_cat_23ox | Ca_Amp_cat_23ox | Al_Amp_cat_23ox | Na_Amp_cat_23ox | K_Amp_cat_23ox | Mn_Amp_cat_23ox | Ti_Amp_cat_23ox | Cr_Amp_cat_23ox | oxy_renorm_factor | cation_sum_Si_Mg | cation_sum_Si_Ca | cation_sum_All | Mgno_Amp | Si_T | Al_T | Al_C | Ti_C | Mg_C | Fe_C | Mn_C | Cr_C | Mg_B | Fe_B | Mn_B | Na_B | Ca_B | Na_A | K_A | Sum_T | Sum_C | Sum_B | Sum_A | factor_8SiAl | factor_15eK | factor_13eCNK | All ferric | 8Si_Min | 16CAT_Min | 15eNK_Min | Min_MinFactor | Min_factor | Max_factor | Av_factor | Si_T_ideal | Al_IV_T_ideal | Ti_T_ideal | Al_VI_C_ideal | Ti_C_ideal | Cr_C_ideal | Fe3_C_ideal | Mg_C_ideal | Fe2_C_ideal | Mn_C_ideal | Mg_B_ideal | Fe2_B_ideal | Mn_B_ideal | Ca_B_ideal | Na_B_ideal | Na_A_ideal | K_A_ideal | FeO_Eq8_Zhang17 | |
---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
0 | 59.333654 | 60.645146 | 56.117080 | 0.685874 | 5.586412 | 2.128936 | 6.437242 | 4.935349 | 2.378780 | 2.334718 | 17.886312 | 6.221705 | 2.781062 | 6.088253 | 2.912777 | 1.645305 | 1.869995 | 2.267423 | 0.640114 | 0.176130 | 0.033048 | 0.276556 | 0.000000 | 0.0 | 13.223362 | 15.093357 | 15.909602 | 0.639036 | 6.088253 | 1.911747 | 0.355676 | 0.276556 | 2.912777 | 1.454991 | 0 | 0.000000 | 0.0 | 0.190314 | 0.033048 | 0.000000 | 1.869995 | 0.640114 | 0.176130 | 8.0 | 4.723444 | 2.093357 | 0.816245 | 0.957433 | 0.953381 | 0.861306 | 0.965468 | 1.314006 | 1.005682 | 0.993815 | 0.993815 | 0.993815 | 0.965468 | 0.979641 | 5.964303 | 2.035697 | 0 | 0.185564 | 0.270926 | 0.000000 | 0.936506 | 2.853476 | 0.675302 | 0.032375 | 0 | 0.00000 | 0.000000 | 1.831924 | 0.168076 | 0.459007 | 0.172544 | 5.949181 |
1 | 70.902522 | 70.515408 | 66.223315 | 0.273132 | 2.250664 | 0.846023 | 3.285068 | 3.603327 | 1.974113 | 2.730521 | 17.962779 | 9.282463 | 1.956064 | 6.399508 | 2.737503 | 1.607585 | 1.901472 | 2.064811 | 0.641619 | 0.155210 | 0.000000 | 0.229397 | 0.000000 | 0.0 | 13.038803 | 14.940276 | 15.737104 | 0.630022 | 6.399508 | 1.600492 | 0.464319 | 0.229397 | 2.737503 | 1.568782 | 0 | 0.000000 | 0.0 | 0.038803 | 0.000000 | 0.059724 | 1.901472 | 0.581894 | 0.155210 | 8.0 | 4.770603 | 2.000000 | 0.737104 | 0.945144 | 0.962656 | 0.870131 | 0.966233 | 1.250096 | 1.016705 | 1.003998 | 1.003998 | 1.000000 | 0.966233 | 0.983116 | 6.291461 | 1.708539 | 0 | 0.321410 | 0.225524 | 0.000000 | 0.776650 | 2.691284 | 0.803792 | 0.000000 | 0 | 0.00000 | 0.000000 | 1.869369 | 0.130631 | 0.500154 | 0.152589 | 2.686836 |
2 | 51.363763 | 52.107144 | 50.932554 | 1.245742 | 11.372546 | 3.023436 | 7.405270 | 5.178338 | 2.916734 | 2.438641 | 17.480366 | 4.148120 | 2.869497 | 5.891052 | 2.918512 | 1.837141 | 1.784078 | 2.312188 | 0.647279 | 0.206813 | 0.062837 | 0.357556 | 0.003258 | 0.0 | 13.382545 | 15.166623 | 16.020715 | 0.613693 | 5.891052 | 2.108948 | 0.203240 | 0.357556 | 2.918512 | 1.517434 | 0 | 0.003258 | 0.0 | 0.319708 | 0.062837 | 0.000000 | 1.784078 | 0.647279 | 0.206813 | 8.0 | 4.642444 | 2.166623 | 0.854092 | 0.975224 | 0.948533 | 0.857145 | 0.961596 | 1.357992 | 0.998707 | 0.989014 | 0.989014 | 0.989014 | 0.975224 | 0.982119 | 5.785715 | 2.214285 | 0 | 0.056559 | 0.351162 | 0.003200 | 0.822521 | 2.866326 | 0.900231 | 0.000000 | 0 | 0.08154 | 0.061714 | 1.752177 | 0.104570 | 0.531135 | 0.203115 | 9.665180 |
3 | 60.687647 | 62.268993 | 61.703644 | 0.690791 | 4.614921 | 1.239917 | 5.309611 | 3.706322 | 3.330558 | 2.619149 | 16.370036 | 4.303575 | 2.046019 | 6.289313 | 3.010500 | 1.632744 | 1.767712 | 1.949713 | 0.655939 | 0.180623 | 0.049231 | 0.308285 | 0.001178 | 0.0 | 13.240963 | 15.008675 | 15.845238 | 0.648361 | 6.289313 | 1.710687 | 0.239025 | 0.308285 | 3.010500 | 1.441011 | 0 | 0.001178 | 0.0 | 0.191732 | 0.049231 | 0.000000 | 1.767712 | 0.655939 | 0.180623 | 8.0 | 4.691715 | 2.008675 | 0.836562 | 0.970989 | 0.957572 | 0.866166 | 0.965722 | 1.271999 | 1.009767 | 0.999422 | 0.999422 | 0.999422 | 0.970989 | 0.985205 | 6.196264 | 1.803736 | 0 | 0.117131 | 0.303724 | 0.001161 | 0.680556 | 2.965960 | 0.928032 | 0.003435 | 0 | 0.00000 | 0.045067 | 1.741559 | 0.213373 | 0.432862 | 0.177951 | 4.298402 |
4 | 66.494122 | 68.100781 | 65.870371 | 0.454822 | 2.915419 | 0.863156 | 4.323992 | 3.348260 | 2.908677 | 2.620235 | 16.658488 | 5.642425 | 1.799559 | 6.441589 | 2.951988 | 1.569270 | 1.778037 | 1.891861 | 0.646588 | 0.166919 | 0.025679 | 0.273652 | 0.000000 | 0.0 | 13.154038 | 14.932075 | 15.745582 | 0.652913 | 6.441589 | 1.558411 | 0.333450 | 0.273652 | 2.951988 | 1.440910 | 0 | 0.000000 | 0.0 | 0.128359 | 0.025679 | 0.067925 | 1.778037 | 0.578663 | 0.166919 | 8.0 | 4.726348 | 2.000000 | 0.745582 | 0.959987 | 0.962855 | 0.870609 | 0.967011 | 1.241930 | 1.016158 | 1.004549 | 1.004549 | 1.000000 | 0.967011 | 0.983505 | 6.335338 | 1.664662 | 0 | 0.195993 | 0.269138 | 0.000000 | 0.758750 | 2.903296 | 0.784635 | 0.025255 | 0 | 0.00000 | 0.000000 | 1.748709 | 0.251291 | 0.384632 | 0.164166 | 3.109003 |
Melt_Comps2=pt.calculate_amp_only_melt_comps(amp_comps=Amps, T=1300)
Melt_Comps2.head()
SiO2_Eq10_Put2016 | SiO2_Eq1_Zhang17 | SiO2_Eq2_Zhang17 | SiO2_Eq4_Zhang17 | TiO2_Eq6_Zhang17 | SiO2_Eq3_Zhang17 | FeO_Eq7_Zhang17 | TiO2_Eq5_Zhang17 | MgO_Eq9_Zhang17 | CaO_Eq10_Zhang17 | CaO_Eq11_Zhang17 | K2O_Eq12_Zhang17 | K2O_Eq13_Zhang17 | Al2O3_Eq14_Zhang17 | H2O_Ridolfi21 | deltaNNO_Ridolfi21 | Si_Amp_cat_23ox | Mg_Amp_cat_23ox | Fet_Amp_cat_23ox | Ca_Amp_cat_23ox | Al_Amp_cat_23ox | Na_Amp_cat_23ox | K_Amp_cat_23ox | Mn_Amp_cat_23ox | Ti_Amp_cat_23ox | Cr_Amp_cat_23ox | oxy_renorm_factor | cation_sum_Si_Mg | cation_sum_Si_Ca | cation_sum_All | Mgno_Amp | Si_T | Al_T | Al_C | Ti_C | Mg_C | Fe_C | Mn_C | Cr_C | Mg_B | Fe_B | Mn_B | Na_B | Ca_B | Na_A | K_A | Sum_T | Sum_C | Sum_B | Sum_A | factor_8SiAl | factor_15eK | factor_13eCNK | All ferric | 8Si_Min | 16CAT_Min | 15eNK_Min | Min_MinFactor | Min_factor | Max_factor | Av_factor | Si_T_ideal | Al_IV_T_ideal | Ti_T_ideal | Al_VI_C_ideal | Ti_C_ideal | Cr_C_ideal | Fe3_C_ideal | Mg_C_ideal | Fe2_C_ideal | Mn_C_ideal | Mg_B_ideal | Fe2_B_ideal | Mn_B_ideal | Ca_B_ideal | Na_B_ideal | Na_A_ideal | K_A_ideal | FeO_Eq8_Zhang17 | |
---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
0 | 49.655108 | 59.333654 | 60.645146 | 56.117080 | 0.685874 | 56.992424 | 5.586412 | 0.649426 | 2.128936 | 6.437242 | 4.935349 | 2.378780 | 2.334718 | 17.886312 | 6.221705 | 2.781062 | 6.088253 | 2.912777 | 1.645305 | 1.869995 | 2.267423 | 0.640114 | 0.176130 | 0.033048 | 0.276556 | 0.000000 | 0.0 | 13.223362 | 15.093357 | 15.909602 | 0.639036 | 6.088253 | 1.911747 | 0.355676 | 0.276556 | 2.912777 | 1.454991 | 0 | 0.000000 | 0.0 | 0.190314 | 0.033048 | 0.000000 | 1.869995 | 0.640114 | 0.176130 | 8.0 | 4.723444 | 2.093357 | 0.816245 | 0.957433 | 0.953381 | 0.861306 | 0.965468 | 1.314006 | 1.005682 | 0.993815 | 0.993815 | 0.993815 | 0.965468 | 0.979641 | 5.964303 | 2.035697 | 0 | 0.185564 | 0.270926 | 0.000000 | 0.936506 | 2.853476 | 0.675302 | 0.032375 | 0 | 0.00000 | 0.000000 | 1.831924 | 0.168076 | 0.459007 | 0.172544 | 5.949181 |
1 | 51.515902 | 70.902522 | 70.515408 | 66.223315 | 0.273132 | 66.974467 | 2.250664 | 0.246485 | 0.846023 | 3.285068 | 3.603327 | 1.974113 | 2.730521 | 17.962779 | 9.282463 | 1.956064 | 6.399508 | 2.737503 | 1.607585 | 1.901472 | 2.064811 | 0.641619 | 0.155210 | 0.000000 | 0.229397 | 0.000000 | 0.0 | 13.038803 | 14.940276 | 15.737104 | 0.630022 | 6.399508 | 1.600492 | 0.464319 | 0.229397 | 2.737503 | 1.568782 | 0 | 0.000000 | 0.0 | 0.038803 | 0.000000 | 0.059724 | 1.901472 | 0.581894 | 0.155210 | 8.0 | 4.770603 | 2.000000 | 0.737104 | 0.945144 | 0.962656 | 0.870131 | 0.966233 | 1.250096 | 1.016705 | 1.003998 | 1.003998 | 1.000000 | 0.966233 | 0.983116 | 6.291461 | 1.708539 | 0 | 0.321410 | 0.225524 | 0.000000 | 0.776650 | 2.691284 | 0.803792 | 0.000000 | 0 | 0.00000 | 0.000000 | 1.869369 | 0.130631 | 0.500154 | 0.152589 | 2.686836 |
2 | 49.243987 | 51.363763 | 52.107144 | 50.932554 | 1.245742 | 51.883607 | 11.372546 | 1.191996 | 3.023436 | 7.405270 | 5.178338 | 2.916734 | 2.438641 | 17.480366 | 4.148120 | 2.869497 | 5.891052 | 2.918512 | 1.837141 | 1.784078 | 2.312188 | 0.647279 | 0.206813 | 0.062837 | 0.357556 | 0.003258 | 0.0 | 13.382545 | 15.166623 | 16.020715 | 0.613693 | 5.891052 | 2.108948 | 0.203240 | 0.357556 | 2.918512 | 1.517434 | 0 | 0.003258 | 0.0 | 0.319708 | 0.062837 | 0.000000 | 1.784078 | 0.647279 | 0.206813 | 8.0 | 4.642444 | 2.166623 | 0.854092 | 0.975224 | 0.948533 | 0.857145 | 0.961596 | 1.357992 | 0.998707 | 0.989014 | 0.989014 | 0.989014 | 0.975224 | 0.982119 | 5.785715 | 2.214285 | 0 | 0.056559 | 0.351162 | 0.003200 | 0.822521 | 2.866326 | 0.900231 | 0.000000 | 0 | 0.08154 | 0.061714 | 1.752177 | 0.104570 | 0.531135 | 0.203115 | 9.665180 |
3 | 52.572962 | 60.687647 | 62.268993 | 61.703644 | 0.690791 | 62.475868 | 4.614921 | 0.652253 | 1.239917 | 5.309611 | 3.706322 | 3.330558 | 2.619149 | 16.370036 | 4.303575 | 2.046019 | 6.289313 | 3.010500 | 1.632744 | 1.767712 | 1.949713 | 0.655939 | 0.180623 | 0.049231 | 0.308285 | 0.001178 | 0.0 | 13.240963 | 15.008675 | 15.845238 | 0.648361 | 6.289313 | 1.710687 | 0.239025 | 0.308285 | 3.010500 | 1.441011 | 0 | 0.001178 | 0.0 | 0.191732 | 0.049231 | 0.000000 | 1.767712 | 0.655939 | 0.180623 | 8.0 | 4.691715 | 2.008675 | 0.836562 | 0.970989 | 0.957572 | 0.866166 | 0.965722 | 1.271999 | 1.009767 | 0.999422 | 0.999422 | 0.999422 | 0.970989 | 0.985205 | 6.196264 | 1.803736 | 0 | 0.117131 | 0.303724 | 0.001161 | 0.680556 | 2.965960 | 0.928032 | 0.003435 | 0 | 0.00000 | 0.045067 | 1.741559 | 0.213373 | 0.432862 | 0.177951 | 4.298402 |
4 | 53.104275 | 66.494122 | 68.100781 | 65.870371 | 0.454822 | 66.590674 | 2.915419 | 0.428619 | 0.863156 | 4.323992 | 3.348260 | 2.908677 | 2.620235 | 16.658488 | 5.642425 | 1.799559 | 6.441589 | 2.951988 | 1.569270 | 1.778037 | 1.891861 | 0.646588 | 0.166919 | 0.025679 | 0.273652 | 0.000000 | 0.0 | 13.154038 | 14.932075 | 15.745582 | 0.652913 | 6.441589 | 1.558411 | 0.333450 | 0.273652 | 2.951988 | 1.440910 | 0 | 0.000000 | 0.0 | 0.128359 | 0.025679 | 0.067925 | 1.778037 | 0.578663 | 0.166919 | 8.0 | 4.726348 | 2.000000 | 0.745582 | 0.959987 | 0.962855 | 0.870609 | 0.967011 | 1.241930 | 1.016158 | 1.004549 | 1.004549 | 1.000000 | 0.967011 | 0.983505 | 6.335338 | 1.664662 | 0 | 0.195993 | 0.269138 | 0.000000 | 0.758750 | 2.903296 | 0.784635 | 0.025255 | 0 | 0.00000 | 0.000000 | 1.748709 | 0.251291 | 0.384632 | 0.164166 | 3.109003 |
PT_Rid=pt.calculate_amp_only_press_temp(amp_comps=Amps, equationP="P_Ridolfi2021",
equationT="T_Ridolfi2012", Ridolfi_Filter=False)
Melt_Comps3=pt.calculate_amp_only_melt_comps(amp_comps=Amps, T=PT_Rid['T_K_calc'])
Melt_Comps3.head()
SiO2_Eq10_Put2016 | SiO2_Eq1_Zhang17 | SiO2_Eq2_Zhang17 | SiO2_Eq4_Zhang17 | TiO2_Eq6_Zhang17 | SiO2_Eq3_Zhang17 | FeO_Eq7_Zhang17 | TiO2_Eq5_Zhang17 | MgO_Eq9_Zhang17 | CaO_Eq10_Zhang17 | CaO_Eq11_Zhang17 | K2O_Eq12_Zhang17 | K2O_Eq13_Zhang17 | Al2O3_Eq14_Zhang17 | H2O_Ridolfi21 | deltaNNO_Ridolfi21 | Si_Amp_cat_23ox | Mg_Amp_cat_23ox | Fet_Amp_cat_23ox | Ca_Amp_cat_23ox | Al_Amp_cat_23ox | Na_Amp_cat_23ox | K_Amp_cat_23ox | Mn_Amp_cat_23ox | Ti_Amp_cat_23ox | Cr_Amp_cat_23ox | oxy_renorm_factor | cation_sum_Si_Mg | cation_sum_Si_Ca | cation_sum_All | Mgno_Amp | Si_T | Al_T | Al_C | Ti_C | Mg_C | Fe_C | Mn_C | Cr_C | Mg_B | Fe_B | Mn_B | Na_B | Ca_B | Na_A | K_A | Sum_T | Sum_C | Sum_B | Sum_A | factor_8SiAl | factor_15eK | factor_13eCNK | All ferric | 8Si_Min | 16CAT_Min | 15eNK_Min | Min_MinFactor | Min_factor | Max_factor | Av_factor | Si_T_ideal | Al_IV_T_ideal | Ti_T_ideal | Al_VI_C_ideal | Ti_C_ideal | Cr_C_ideal | Fe3_C_ideal | Mg_C_ideal | Fe2_C_ideal | Mn_C_ideal | Mg_B_ideal | Fe2_B_ideal | Mn_B_ideal | Ca_B_ideal | Na_B_ideal | Na_A_ideal | K_A_ideal | FeO_Eq8_Zhang17 | |
---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
0 | 59.262728 | 59.333654 | 60.645146 | 56.117080 | 0.685874 | 56.082183 | 5.586412 | 0.713445 | 2.128936 | 6.437242 | 4.935349 | 2.378780 | 2.334718 | 17.886312 | 6.221705 | 2.781062 | 6.088253 | 2.912777 | 1.645305 | 1.869995 | 2.267423 | 0.640114 | 0.176130 | 0.033048 | 0.276556 | 0.000000 | 0.0 | 13.223362 | 15.093357 | 15.909602 | 0.639036 | 6.088253 | 1.911747 | 0.355676 | 0.276556 | 2.912777 | 1.454991 | 0 | 0.000000 | 0.0 | 0.190314 | 0.033048 | 0.000000 | 1.869995 | 0.640114 | 0.176130 | 8.0 | 4.723444 | 2.093357 | 0.816245 | 0.957433 | 0.953381 | 0.861306 | 0.965468 | 1.314006 | 1.005682 | 0.993815 | 0.993815 | 0.993815 | 0.965468 | 0.979641 | 5.964303 | 2.035697 | 0 | 0.185564 | 0.270926 | 0.000000 | 0.936506 | 2.853476 | 0.675302 | 0.032375 | 0 | 0.00000 | 0.000000 | 1.831924 | 0.168076 | 0.459007 | 0.172544 | 5.949181 |
1 | NaN | 70.902522 | 70.515408 | 66.223315 | 0.273132 | NaN | 2.250664 | NaN | 0.846023 | 3.285068 | 3.603327 | 1.974113 | 2.730521 | 17.962779 | 9.282463 | 1.956064 | 6.399508 | 2.737503 | 1.607585 | 1.901472 | 2.064811 | 0.641619 | 0.155210 | 0.000000 | 0.229397 | 0.000000 | 0.0 | 13.038803 | 14.940276 | 15.737104 | 0.630022 | 6.399508 | 1.600492 | 0.464319 | 0.229397 | 2.737503 | 1.568782 | 0 | 0.000000 | 0.0 | 0.038803 | 0.000000 | 0.059724 | 1.901472 | 0.581894 | 0.155210 | 8.0 | 4.770603 | 2.000000 | 0.737104 | 0.945144 | 0.962656 | 0.870131 | 0.966233 | 1.250096 | 1.016705 | 1.003998 | 1.003998 | 1.000000 | 0.966233 | 0.983116 | 6.291461 | 1.708539 | 0 | 0.321410 | 0.225524 | 0.000000 | 0.776650 | 2.691284 | 0.803792 | 0.000000 | 0 | 0.00000 | 0.000000 | 1.869369 | 0.130631 | 0.500154 | 0.152589 | 2.686836 |
2 | 50.680338 | 51.363763 | 52.107144 | 50.932554 | 1.245742 | 51.769071 | 11.372546 | 1.206181 | 3.023436 | 7.405270 | 5.178338 | 2.916734 | 2.438641 | 17.480366 | 4.148120 | 2.869497 | 5.891052 | 2.918512 | 1.837141 | 1.784078 | 2.312188 | 0.647279 | 0.206813 | 0.062837 | 0.357556 | 0.003258 | 0.0 | 13.382545 | 15.166623 | 16.020715 | 0.613693 | 5.891052 | 2.108948 | 0.203240 | 0.357556 | 2.918512 | 1.517434 | 0 | 0.003258 | 0.0 | 0.319708 | 0.062837 | 0.000000 | 1.784078 | 0.647279 | 0.206813 | 8.0 | 4.642444 | 2.166623 | 0.854092 | 0.975224 | 0.948533 | 0.857145 | 0.961596 | 1.357992 | 0.998707 | 0.989014 | 0.989014 | 0.989014 | 0.975224 | 0.982119 | 5.785715 | 2.214285 | 0 | 0.056559 | 0.351162 | 0.003200 | 0.822521 | 2.866326 | 0.900231 | 0.000000 | 0 | 0.08154 | 0.061714 | 1.752177 | 0.104570 | 0.531135 | 0.203115 | 9.665180 |
3 | 62.370970 | 60.687647 | 62.268993 | 61.703644 | 0.690791 | 61.541928 | 4.614921 | 0.718307 | 1.239917 | 5.309611 | 3.706322 | 3.330558 | 2.619149 | 16.370036 | 4.303575 | 2.046019 | 6.289313 | 3.010500 | 1.632744 | 1.767712 | 1.949713 | 0.655939 | 0.180623 | 0.049231 | 0.308285 | 0.001178 | 0.0 | 13.240963 | 15.008675 | 15.845238 | 0.648361 | 6.289313 | 1.710687 | 0.239025 | 0.308285 | 3.010500 | 1.441011 | 0 | 0.001178 | 0.0 | 0.191732 | 0.049231 | 0.000000 | 1.767712 | 0.655939 | 0.180623 | 8.0 | 4.691715 | 2.008675 | 0.836562 | 0.970989 | 0.957572 | 0.866166 | 0.965722 | 1.271999 | 1.009767 | 0.999422 | 0.999422 | 0.999422 | 0.970989 | 0.985205 | 6.196264 | 1.803736 | 0 | 0.117131 | 0.303724 | 0.001161 | 0.680556 | 2.965960 | 0.928032 | 0.003435 | 0 | 0.00000 | 0.045067 | 1.741559 | 0.213373 | 0.432862 | 0.177951 | 4.298402 |
4 | 66.077116 | 66.494122 | 68.100781 | 65.870371 | 0.454822 | 65.162647 | 2.915419 | 0.496739 | 0.863156 | 4.323992 | 3.348260 | 2.908677 | 2.620235 | 16.658488 | 5.642425 | 1.799559 | 6.441589 | 2.951988 | 1.569270 | 1.778037 | 1.891861 | 0.646588 | 0.166919 | 0.025679 | 0.273652 | 0.000000 | 0.0 | 13.154038 | 14.932075 | 15.745582 | 0.652913 | 6.441589 | 1.558411 | 0.333450 | 0.273652 | 2.951988 | 1.440910 | 0 | 0.000000 | 0.0 | 0.128359 | 0.025679 | 0.067925 | 1.778037 | 0.578663 | 0.166919 | 8.0 | 4.726348 | 2.000000 | 0.745582 | 0.959987 | 0.962855 | 0.870609 | 0.967011 | 1.241930 | 1.016158 | 1.004549 | 1.004549 | 1.000000 | 0.967011 | 0.983505 | 6.335338 | 1.664662 | 0 | 0.195993 | 0.269138 | 0.000000 | 0.758750 | 2.903296 | 0.784635 | 0.025255 | 0 | 0.00000 | 0.000000 | 1.748709 | 0.251291 | 0.384632 | 0.164166 | 3.109003 |
PT_Rid.head()
P_kbar_calc | T_K_calc | Input_Check | Fail Msg | classification | equation | SiO2_Amp | TiO2_Amp | Al2O3_Amp | FeOt_Amp | MnO_Amp | MgO_Amp | CaO_Amp | Na2O_Amp | K2O_Amp | Cr2O3_Amp | F_Amp | Cl_Amp | Sample_ID_Amp | |
---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
0 | 4.572174 | 1214.531361 | True | Mg-hastingsite | (1b+1c)/2 | 40.57 | 2.45 | 12.82 | 13.11 | 0.26 | 13.02 | 11.63 | 2.20 | 0.92 | 0.00 | 0.0 | 0.0 | probe1 | |
1 | NaN | NaN | False | Recalc Total<98.5 | Pargasite | 1b | 39.45 | 1.88 | 10.80 | 11.85 | 0.00 | 11.32 | 10.94 | 2.04 | 0.75 | 0.00 | 0.0 | 0.0 | probe2 |
2 | 6.203253 | 1289.245454 | False | Recalc Total>102 | Mg-hastingsite | 1c+1d | 42.88 | 3.46 | 14.28 | 15.99 | 0.54 | 14.25 | 12.12 | 2.43 | 1.18 | 0.03 | 0.0 | 0.0 | probe3 |
3 | 3.228704 | 1212.306099 | False | APE >60 | Mg-hastingsite | 1b | 42.20 | 2.75 | 11.10 | 13.10 | 0.39 | 13.55 | 11.07 | 2.27 | 0.95 | 0.01 | 0.0 | 0.0 | probe4 |
4 | 2.761702 | 1165.913034 | False | Recalc Total<98.5 | Mg-hastingsite | 1b | 40.37 | 2.28 | 10.06 | 11.76 | 0.19 | 12.41 | 10.40 | 2.09 | 0.82 | 0.00 | 0.0 | 0.0 | probe5 |
fig, (ax1, ax2) = plt.subplots(1, 2, figsize=(10,5))
ax1.plot(Melt_Comps3['SiO2_Eq1_Zhang17'], Melt_Comps3['SiO2_Eq10_Put2016'], 'ok')
ax1.set_xlabel('SiO$_2$ wt% Eq 1 Zhang17')
ax1.set_ylabel('SiO$_2$ wt% Eq 10 Putirka 2016')
ax2.plot(Melt_Comps3['SiO2_Eq1_Zhang17'], Melt_Comps3['TiO2_Eq6_Zhang17'], 'ok')
ax2.set_xlabel('SiO$_2$ wt% Eq 1 Zhang17')
ax2.set_ylabel('TiO$_2$ wt% Eq 6 Zhang17')
ax1.plot([50, 85], [50, 85], '-r')
[<matplotlib.lines.Line2D at 0x292b1c59f70>]