CoolProp

CoolProp is a free and open-source library/calculator of fluid thermodynamic properties – essentially a free REFProp. CoolProp is a fantastic project and I really enjoyed using it – thank you CoolProp team!

I used CoolProp with Matlab for my Rheomega work. Wherever I had 2 fluid properties (options being: pressure, temperature, enthalpy, entropy, specific volume), and wanted the rest, I called on CoolProp. Example code calls:

stateFour.wf.V = 1./CoolProp.PropsSI(‘D’,’T’,stateFour.wf.T,’P’,stateFour.wf.P,fluid.working);
stateFour.wf.H = CoolProp.PropsSI(‘H’,’T’,stateFour.wf.T,’P’,stateFour.wf.P,fluid.working);
stateFour.wf.S = CoolProp.PropsSI(‘S’,’T’,stateFour.wf.T,’P’,stateFour.wf.P,fluid.working);

For instance, I calculated how a foam (mixed-phase gas-liquid) expander would work step-by-step (see the blue and magenta dots on the graph below) by doing an energy balance at each step and using CoolProp calls to give me the fluid properties.