Creating SCO2 properties by using NIST to RGP.
Hello!
I have to create an RGP file to input SCO2 properties to the CFX solver. I have found a program that converts a fluid database into the RGP file, but I have some problems handling this program. --------------------------------------------------------------------- # NIST-RGP.F iNPUT: # # IFLD=1 -> PH2 # IFLD=2 -> LOX # IFLD=3 -> PROPANE (C3H8) # IFLD=4 -> CO2 # IFLD=5 -> METHANE (CH4) # IFLD=6 -> ETHANE (C2H6) # IFLD=7 -> NITROGEN # IFLD=8 -> BUTANE (C4H10) # IFLD=9 -> R245FA # # NT NP NSAT IFLD # ______ _____ _____ _____ 810 810 810 4 # # # TMIN TMAX PMIN PMAX # [DEG R] [DEG R] [PSIA] [PSIA] # _______ _______ _________ ___________ 250. 400. 1015. 1232. --------------------------------------------------------------------- This is the setting properties of dat.txt file in the program. I want to calculate the fluid data between 7MPa and 8.5MPa, 0℃ and 100℃. I cannot understand how this file works. Based on the dimension in this file, I think the pressure input should be calculated as PSIA, and temperature as Kalvin. So I have entered those parameters because I want to get SCO2 properties. But as I activate this program, It turns out an error. --------------------------------------------------------------------- TPRHO failed so extrapolating saturation data IERR1 = 0 IERR2 = 202 J = 144 P/PC = 0.98445562506293216 Of course it didn't work in CFX solver. How can I convert the fluid database into RGP file? How can I use the dat.txt file perfectly? Anybody please help me. Thank you. |
Temperature is Rankine, not Kelvin. It states that explicitly: "[deg R]"
|
Quote:
Then how can I input the pressure and temperature data? As I input the data like below: # TMIN TMAX PMIN PMAX # [DEG R] [DEG R] [PSIA] [PSIA] # _______ _______ _________ ___________ 545. 650. 1069. 1232. It does not work. |
Works perfectly fine for me using your inputs (I changed 810 to 100 to make it quicker, but that shouldn't matter).
1.) Do You have all the .fld files from refprop placed in the fluids folder? 2.) Do you have tabs in between you temperature and pressure data? |
Quote:
2)Of course, I have. But it still have error TPRHO failed so extrapolating saturation data IERR1 = 0 IERR2 = 202 J = 2 P/PC = 0.99926348198524140 |
I Didn't realize you were right below the critical pressure of 1070 psia.
Reduce you # of points from 810 down to something lower (400 worked for me) Or raise your minimum pressure up to at least the critical pressure. |
Quote:
# NT NP NSAT IFLD # ______ _____ _____ _____ 400 400 400 4 # # # TMIN TMAX PMIN PMAX # [DEG R] [DEG R] [PSIA] [PSIA] # _______ _______ _________ ___________ 545. 650. 1080. 1232. But it still doesn't work. SATP failed so extrapolating vapor sat data J = 399 P/PC = 1.0000234477499255 [SATP error 141] pressure input to saturation routine is greater than critical pressure; P = 7.3775 MPa, Pcrit = 7.3773 MPa. It still comes out with error... |
This worked for me:
# NT NP NSAT IFLD # ______ _____ _____ _____ 400 400 400 4 # # # TMIN TMAX PMIN PMAX # [DEG R] [DEG R] [PSIA] [PSIA] # _______ _______ _________ ___________ 545. 650. 1069. 1232. |
Also, if you are only interested in supercritical properties, you can ignore that error, as there is no saturation curve in the supercritical region.
|
Quote:
I had made rgp files based on your values: NT~NSAT = 400 , and I also made rgp file NT~NSAT = 1000, It comes out with an error of failing of extrapolating sat data. ---------------------------------------------------------- SATP failed so extrapolating vapor sat data J = 1791 P/PC = 1.0000010211152017 [SATP error 141] pressure input to saturation routine is greater than critical pressure; P = 7.3773 MPa, Pcrit = 7.3773 MPa. --------------------------------------------------------- Based on your reply, I ignored the error and input the rgp file into CFX solver. But it didn't work. It comes out with error. +--------------------------------------------------------------------+ | ERROR #001100279 has occurred in subroutine ErrAction. | | Message: | | Could not find component in TASCflow RGP file. | | | | | | | | | | | +--------------------------------------------------------------------+ +--------------------------------------------------------------------+ | ERROR #001100279 has occurred in subroutine ErrAction. | | Message: | | Encountered problem reading the RGP file header. | | | | | | | | | | | +--------------------------------------------------------------------+ +--------------------------------------------------------------------+ | ERROR #001100279 has occurred in subroutine ErrAction. | | Message: | | Stopped in routine SU_PROPS_RGP | | | | | | | | | | | +--------------------------------------------------------------------+ +--------------------------------------------------------------------+ | An error has occurred in cfx5solve: | | | | The ANSYS CFX solver exited with return code 1. No results file | | has been created. | +--------------------------------------------------------------------+ I had input the temperature of 349K, pressure of 7.991MPa, which are all inside of the interpolation range. But it didn't work. Do you know how I can solve this problem? I am very upset with this error that annoying me about 3 weeks. |
Are you doing everything correctly in CFX-Pre? Sound's like it can't find the right component according to the error message.
What are you naming your component in Pre? I believe it should be "CO2Vap" You could try using one of the built in real gas equations of state for CO2 vapor if you can't get the rgp file to work. |
Quote:
I found the problem: component name. In CFX and RGP file, there are component names, so I must fit those two component names. By fitting the name, I have solved the problem and I can input the RGP file successfully. Thank you very much! :D |
Quote:
Could you please explain how did you fix the component name? we are encountering similar issue. Thank you |
It should say in your RGP file. Likely "CO2" for the liquid phase, and "CO2Vap" for the gas/supercritical phase. Gas/supercritical is when either the temperature OR pressure is above the critical point.
|
All times are GMT -4. The time now is 09:48. |