2828
2929DEFAULT_CO2_MOLAR_MASS = 44.0
3030DEFAULT_WATER_MOLAR_MASS = 18.0
31- PROPERTIES_NEEDED_PFLOTRAN = ["SGAS" , "DGAS" , "DWAT" ]
31+ PROPERTIES_NEEDED_CIRRUS = ["SGAS" , "DGAS" , "DWAT" ]
3232PROPERTIES_NEEDED_ECLIPSE = ["SGAS" , "BGAS" , "BWAT" , "XMF2" , "YMF2" ]
3333
3434RELEVANT_PROPERTIES = [
@@ -747,7 +747,7 @@ def _set_calc_type_from_input_string(calc_type_input: str) -> CalculationType:
747747 return CalculationType [calc_type_input ]
748748
749749
750- def _pflotran_co2mass (
750+ def _cirrus_co2mass (
751751 source_data ,
752752 scenario : Scenario ,
753753 pore_volume_prop : str ,
@@ -757,7 +757,7 @@ def _pflotran_co2mass(
757757 oil_molar_mass : Optional [float ] = None ,
758758) -> Dict [str , List [np .ndarray ]]:
759759 """
760- Calculates CO2 mass based on the existing properties in PFlotran
760+ Calculates CO2 mass based on the existing properties in Cirrus
761761
762762 Args:
763763 source_data (SourceData): Data with the information of the necessary properties
@@ -918,7 +918,7 @@ def _compositional_co2mass(
918918 soil = source_data .SOIL
919919 eff_vols = source_data .RPORV if pore_volume_prop == "RPORV" else source_data .PORV
920920 conv_fact = co2_molar_mass
921- if co2_position is not None and source != "PFlotran COMP" :
921+ if co2_position is not None and source != "Cirrus COMP" :
922922 xmf_co2 = getattr (source_data , f"XMF{ co2_position } " )
923923 ymf_co2 = getattr (source_data , f"YMF{ co2_position } " )
924924 else :
@@ -945,7 +945,7 @@ def _compositional_co2mass(
945945 else :
946946 zmf_co2 = (
947947 getattr (source_data , f"ZMF{ co2_position } " )
948- if co2_position is not None and source != "PFlotran COMP"
948+ if co2_position is not None and source != "Cirrus COMP"
949949 else source_data .ZMF2
950950 )
951951 phase_moles [date ].extend ([boil [date ] * soil [date ] * eff_vols [date ]])
@@ -970,7 +970,7 @@ def _compositional_co2mass(
970970 return co2_mass
971971
972972
973- def _pflotran_co2_molar_volume (
973+ def _cirrus_co2_molar_volume (
974974 source_data ,
975975 scenario : Scenario ,
976976 water_density : np .ndarray ,
@@ -982,7 +982,7 @@ def _pflotran_co2_molar_volume(
982982 oil_molar_mass : Optional [float ] = None ,
983983) -> Dict :
984984 """
985- Calculates CO2 molar volume (mol/m3) based on the existing properties in PFlotran
985+ Calculates CO2 molar volume (mol/m3) based on the existing properties in Cirrus
986986
987987 Args:
988988 source_data (SourceData): Data with the information of the necessary properties
@@ -1322,17 +1322,17 @@ def _calculate_co2_data_from_source_data(
13221322 gas_molar_mass = None
13231323 oil_molar_mass = None
13241324 comp_molar_masses = None
1325- if source == "PFlotran COMP" :
1325+ if source == "Cirrus COMP" :
13261326 if cirrus_info_file is None :
1327- error_text = "Source: PFlotran COMP"
1327+ error_text = "Source: Cirrus EOS COMP"
13281328 error_text += f"\n Scenario: { scenario .name } ."
13291329 error_text += (
13301330 "\n To compute mass or actual volume in this scenario "
13311331 "path to cirrus INFO file must be provided."
13321332 )
13331333 raise ValueError (format_error (error_text ))
13341334 comp_molar_masses = _extract_comp_molar_masses (cirrus_info_file )
1335- elif source == "PFlotran " :
1335+ elif source == "Cirrus " :
13361336 gas_molar_mass , oil_molar_mass = _extract_molar_masses (
13371337 scenario , cirrus_info_file
13381338 )
@@ -1393,21 +1393,21 @@ def _find_pore_volume_prop(active_props: List[str]) -> str:
13931393def _find_source_and_scenario (
13941394 residual_trapping : bool , active_props : List [str ]
13951395) -> Tuple [str , Scenario ]:
1396- props_needed_pflotran = PROPERTIES_NEEDED_PFLOTRAN .copy ()
1396+ props_needed_cirrus = PROPERTIES_NEEDED_CIRRUS .copy ()
13971397 props_needed_eclipse = PROPERTIES_NEEDED_ECLIPSE .copy ()
13981398 if residual_trapping :
1399- props_needed_pflotran .append ("SGSTRAND" )
1399+ props_needed_cirrus .append ("SGSTRAND" )
14001400 props_needed_eclipse .append ("SGTRH" )
1401- if is_subset (props_needed_pflotran , active_props ):
1402- source = "PFlotran "
1401+ if is_subset (props_needed_cirrus , active_props ):
1402+ source = "Cirrus "
14031403 if is_subset (["AMFS" , "YMFO" ], active_props ):
14041404 scenario = Scenario .DEPLETED_OIL_GAS_FIELD
14051405 elif is_subset (["AMFS" ], active_props ):
14061406 scenario = Scenario .DEPLETED_GAS_FIELD
14071407 elif is_subset (["AMFG" , "YMFG" ], active_props ):
14081408 scenario = Scenario .AQUIFER
14091409 elif is_subset (["XMF2" ], active_props ):
1410- source = "PFlotran COMP"
1410+ source = "Cirrus COMP"
14111411 if _n_components (active_props ) <= 3 :
14121412 scenario = Scenario .AQUIFER
14131413 elif is_subset (["SOIL" ], active_props ):
@@ -1429,7 +1429,7 @@ def _find_source_and_scenario(
14291429 scenario = Scenario .DEPLETED_GAS_FIELD
14301430 else :
14311431 _raise_missing_props_error (
1432- active_props , props_needed_pflotran , props_needed_eclipse
1432+ active_props , props_needed_cirrus , props_needed_eclipse
14331433 )
14341434 return source , scenario
14351435
@@ -1447,8 +1447,8 @@ def _calc_co2_amount(
14471447 oil_molar_mass : Optional [float ],
14481448 comp_molar_masses : Optional [Dict [str , Tuple [int , float ]]],
14491449) -> Co2Data :
1450- if source == "PFlotran " :
1451- co2_mass_cell = _pflotran_co2mass (
1450+ if source == "Cirrus " :
1451+ co2_mass_cell = _cirrus_co2mass (
14521452 source_data ,
14531453 scenario ,
14541454 pore_volume_prop ,
@@ -1459,7 +1459,7 @@ def _calc_co2_amount(
14591459 )
14601460 else :
14611461 co2_position = None
1462- if source == "PFlotran COMP" and comp_molar_masses is not None :
1462+ if source == "Cirrus COMP" and comp_molar_masses is not None :
14631463 bwat , bgas , boil = _convert_phase_density_from_mass_to_mole (
14641464 source_data ,
14651465 comp_molar_masses ,
@@ -1576,7 +1576,7 @@ def _calculate_molar_vols_co2(
15761576 gas_molar_mass : Optional [float ],
15771577 oil_molar_mass : Optional [float ],
15781578):
1579- if source == "PFlotran " :
1579+ if source == "Cirrus " :
15801580 y_prop = source_data .AMFG if scenario == Scenario .AQUIFER else source_data .AMFS
15811581 y = y_prop [source_data .DATES [0 ]]
15821582 where_min_amf_co2 = np .where (y < THRESHOLD_DISSOLVED )[0 ]
@@ -1629,7 +1629,7 @@ def _calculate_molar_vols_co2(
16291629 for x in enumerate (doil )
16301630 ]
16311631 )
1632- molar_vols_co2 = _pflotran_co2_molar_volume (
1632+ molar_vols_co2 = _cirrus_co2_molar_volume (
16331633 source_data ,
16341634 scenario ,
16351635 water_density ,
@@ -1721,13 +1721,13 @@ def _calc_co2_amount_cell_volume(
17211721
17221722def _raise_missing_props_error (
17231723 active_props : List [str ],
1724- props_needed_pflotran : List [str ],
1724+ props_needed_cirrus : List [str ],
17251725 props_needed_eclipse : List [str ],
17261726):
1727- if any (prop in props_needed_pflotran for prop in active_props ):
1728- missing_props = [x for x in props_needed_pflotran if x not in active_props ]
1727+ if any (prop in props_needed_cirrus for prop in active_props ):
1728+ missing_props = [x for x in props_needed_cirrus if x not in active_props ]
17291729 error_text = "Lacking some required properties to compute CO2 mass/volume."
1730- error_text += "\n Assumed source: PFlotran "
1730+ error_text += "\n Assumed source: Cirrus "
17311731 error_text += "\n Missing properties: "
17321732 error_text += ", " .join (missing_props )
17331733 raise ValueError (format_error (error_text ))
@@ -1740,8 +1740,8 @@ def _raise_missing_props_error(
17401740 raise ValueError (format_error (error_text ))
17411741 error_text = "Lacking all required properties to compute CO2 mass/volume."
17421742 error_text += "\n Need either:"
1743- error_text += f"\n PFlotran : \
1744- { ', ' .join (props_needed_pflotran )} "
1743+ error_text += f"\n Cirrus : \
1744+ { ', ' .join (props_needed_cirrus )} "
17451745 error_text += f"\n Eclipse : \
17461746 { ', ' .join (props_needed_eclipse )} "
17471747 raise ValueError (format_error (error_text ))
0 commit comments