CoolProp.PropsSI('DMASS', 'T', T, 'P', p/1000, 'INCOMP::MEG-50%')
CoolProp.PropsSI('UMASS','T',T,'P',p/1000, 'INCOMP::MEG-50%)
CoolProp.PropsSI('VISCOSITY','T',T,'P',p/1000, 'INCOMP::MEG-50%')
CoolProp.PropsSI('ISOTHERMAL_COMPRESSIBILITY','T',T,'P',p/1000, 'INCOMP::MEG-50%')
CoolProp.PropsSI('ISOBARIC_EXPANSION_COEFFICIENT','T',T,'P',p/1000, 'INCOMP::MEG-50%')
Tom,
Hopefully Jorrit can chime in here, but those outputs are not defined for incompressible fluids, and I believe they cannot be defined for incompressible fluids. For "normal" fluids like propane, that should work fine. Did you try that first?
Ian
--
You received this message because you are subscribed to the Google Groups "coolprop-users" group.
To unsubscribe from this group and stop receiving emails from it, send an email to coolprop-user...@googlegroups.com.
To post to this group, send email to coolpro...@googlegroups.com.
Visit this group at http://groups.google.com/group/coolprop-users.
For more options, visit https://groups.google.com/d/optout.
Hi
The isothermal expansion coefficient is defined as “1/v * (dv/dT)|p”, which then can be converted to “-1/rho * (drho/dT)|p”. The latter is indeed defined in CoolProp, see the following example in Python:
import CoolProp.CoolProp as CP
rho = CP.PropsSI('D','T',273.15+25,'P',10e5,'INCOMP::MEG-50%')
drhodT = CP.PropsSI('d(Dmass)/d(T)|P','T',273.15+25,'P',10e5,'INCOMP::MEG-50%')
print(-1.0/rho * drhodT)
0.000521758207783
There are a few partial derivatives defined for incompressible fluids, but not all of them. They have not gotten all the love the deserve and the implementation is a little patchy, but the following functions should be available: drhodTatPx, dsdTatPx, dhdTatPx, dsdTatPxdT , dhdTatPxdT, dsdpatTx, dhdpatTx. Note that all partial derivatives require a constant concentration, which is denoted by the “x”, but this “x” is not included in the derivative string: “drhodTatPx” translates to “d(Dmass)/d(T)|P”
Regards,
Jorrit
--
To post to this group, send email to coolpr...@googlegroups.com.
To post to this group, send email to coolpro...@googlegroups.com.
Dear Tom,
Please have a look at my older email. Internally, incomrpessibles are not treated like the other fluids. In particular, they do not provide the exact same functionality.
You can use these steps to get the compressibility though:
import CoolProp.CoolProp as CP
rho = CP.PropsSI('D','T',273.15+25,'P',10e5,'INCOMP::MEG-50%')
drhodT = CP.PropsSI('d(Dmass)/d(T)|P','T',273.15+25,'P',10e5,'INCOMP::MEG-50%')
print(-1.0/rho * drhodT)
0.000521758207783
.. and the following functions should be available: drhodTatPx, dsdTatPx, dhdTatPx, dsdTatPxdT , dhdTatPxdT, dsdpatTx, dhdpatTx. Note that all partial derivatives require a constant concentration, which is denoted by the “x”, but this “x” is not included in the derivative string: “drhodTatPx” translates to “d(Dmass)/d(T)|P”
Jorrit,
Could you add a few small notes about derivatives in the docs? Would be useful for folks.
Ian
Jorrit is going to update the docs, but I am quite surprised that 'd(Dmass)/d(P)|P' didn't throw an error. The second P should be a T. It would be nice in general if you provided complete examples rather than a selection of lines.
Jorrit, could we also consider to actually implement the desired functions, overriding the base class functions for the isobaric expansion coefficient for instance?