NREL / GEOPHIRES-v2

GEOPHIRES v2.0: a free and open-source geothermal techno-economic simulator
GNU General Public License v3.0
45 stars 22 forks source link

Help wanted: Splicing in a power plant #1

Open NicholasFry opened 2 years ago

NicholasFry commented 2 years ago

@NRELAdmin @kfbeckers @kmccabe1990 I am trying to see if it is possible to splice our custom ORC combined heat and power plant into GEOPHIRES. If I recall correctly, these ORC values are drawn from curve correlations, therefore the formulas at line 1783. Would it be possible to stick a power plant into this section? What happens to the power plant is we use a user-defined reservoir thermal drawdown curve? How is GEOPHIRES handling the reinjection temperatures from line 1813, for example, if the thermal drawdown curve is already defined?

I am looking for comments and variable definitions for etaull (lower limit of efficiency), etauul, etau, reinjtll, reinjtul, and reinjtemp. Basically, what do I need to give back to GEOPHIRES from our power plant to keep it from breaking the code? I have a heat fraction and an electricity quantity from a subcritical ORC, and the thermal drawdown curve should be defined by our external numerical model and imported via .csv. Thank you for any input you can offer.

etaull = C1*TenteringPP + C0
etauul = D1*TenteringPP + D0
etau = (1-Tfraction)*etaull + Tfraction*etauul

reinjtll = C1*TenteringPP + C0
reinjtul = D1*TenteringPP + D0
ReinjTemp = (1.-Tfraction)*reinjtll + Tfraction*reinjtul
kfbeckers commented 2 years ago

Yes, the formulas starting on line 1783 represent the utilization efficiency curves shown in Figure 2 of the GEOPHIRES paper (https://doi.org/10.1186/s40517-019-0119-6). You could bypass or overwrite these correlations and use your own correlation for utilization efficiency. E.g., provide your equation for etau on line 1946. Alternatively, you can directly provide the produced electricity. E.g., in case of enduseoption = 1, you would provide an array of the produced electricity on line 1949 for "ElectricityProduced". If you provide a reservoir thermal drawdown curve, GEOPHIRES will use that data for calculating the production temperature ("ProducedTemperature"), which is used to calculate the produced heat (e.g., on line 1950 for enduseoption = 1), exergy (line 1781), and utilization efficiency (starting on line 1783). Depending on the type of power plant, ambient temperature, and the production temperature, the reinjection temperature gets calculated using correlations provide on line 1783 to 1926. These correlations are plotted in Figure 4.3 in https://doi.org/10.7298/X4736NTC. Etau is the utilization efficiency (see equation 19 in the GEOPHIRES paper). Reinjtemp is the temperature of the geofluid leaving the power plant (in deg. C). etaull and etauul, as well as reinjtll and reinjtul are auxiliary variables representing the utilization efficiency and reinjection temperature at 5, 15 or 25 degrees C ambient temperature. The actual utilization efficiency and reinjection temperature are then calculated using interpolation based on "Tfraction". You can bypass all these correlations and directly provide your results for electricity production (in MWe) and heat production (in MWt) as a numpy array on lines 1948 to 1966 depending on your enduseoption chosen. In case of a cogen topping cycle, Reinjtemp (= geofluid temperature leaving the power plant) is used as the supply temperature to the direct-use heat application (line 1955). This line can be overwritten manually to directly provide your heat production. On lines 1929 to 1945, reinjtemp is compared with the user-provided injection temperature. If Reinjtemp is lower than the user-provided temperature, it gets overwritten and a warning message is shown. You may need to remove this entire section when not relying on the built-in GEOPHIRES power plant models but when providing your own power plant data.

NicholasFry commented 2 years ago

Very helpful. Thank you. I will work on a mock-up and keep the issue open until I have solved.

NicholasFry commented 2 years ago

@kfbeckers This probably does not factor into the final code I will use, but what does "availability" mean from GEOPHIRES v1.0, appearing around line 1784 of v2.0 (my lines are different than the original, right now)? It is a measure of enthalpy, but I do not see documentation on its many other constants. I looked for it in https://pangea.stanford.edu/ERE/pdf/IGAstandard/SGW/2013/Beckers.pdf but could not find it. Is there a reason it is called availability?

kfbeckers commented 2 years ago

Availability is another term for exergy (https://en.wikipedia.org/wiki/Exergy). It is a thermodynamic property of the fluid (in this case water) that describes the maximum amount of work (electricity) that can be performed.

NicholasFry commented 2 years ago

Ok, thank you. I did not realize these were the same things.