lib.SRK module¶
- class lib.EoS.Cubic.SRK.SRK(T, P, mezcla, **kwargs)[source]¶
Bases:
CubicEquation of state of Soave-Redlich-Kwong (1972)
\[\begin{split}\begin{array}[t]{l} P = \frac{RT}{V-b}-\frac{a}{V\left(V+b\right)}\\ a = 0.42747\frac{R^2T_c^2}{P_c}\alpha\\ b = 0.08664\frac{RT_c}{P_c}\\ \alpha^{0.5} = 1 + m\left(1-Tr^{0.5}\right)\\ m = 0.48 + 1.574\omega - 0.176\omega^2\\ \end{array}\end{split}\]In supercritical states, the α temperature dependence can use different extrapolation correlation:
Boston-Mathias expression, [3]
\[\begin{split}\begin{array}[t]{l} \alpha = \exp\left(c\left(1-T_r^d\right)\right)\\ d = 1+\frac{m}{2}\\ c = \frac{m}{d}\\ \end{array}\end{split}\]Nasrifar-Bolland expression, [4]
\[\begin{split}\begin{array}[t]{l} \alpha = \frac{b_1}{T_r} + \frac{b_2}{T_r^2} + \frac{b_3}{T_r^3}\\ b_1 = 0.25\left(12 - 11m + m^2\right)\\ b_2 = 0.5\left(-6 + 9m - m^2\right)\\ b_3 = 0.25\left(4 - 7m + m^2\right)\\ \end{array}\end{split}\]- Parameters:
- alphaint
- Correlation index for alpha expresion at supercritical temperatures:
0 - Original
1 - Boston
2 - Nasrifar
Examples
Example 4.3 from [2], Propane saturated at 300K
>>> from lib.mezcla import Mezcla >>> mix = Mezcla(5, ids=[4], caudalMolar=1, fraccionMolar=[1]) >>> eq = SRK(300, 9.9742e5, mix) >>> '%0.1f' % (eq.Vl.ccmol) '98.4' >>> eq = SRK(300, 42.477e5, mix) >>> '%0.1f' % (eq.Vg.ccmol) '95.1'
Helmholtz energy formulation example for supplementary documentatión from [4], the critical parameter are override for the valued used in paper to get the values of test with high precision
>>> from lib.mezcla import Mezcla >>> from lib import unidades >>> from lib.compuestos import Componente >>> ch4 = Componente(2) >>> ch4.Tc, ch4.Pc, ch4.f_acent = 190.564, 4599200, 0.011 >>> o2 = Componente(47) >>> o2.Tc, o2.Pc, o2.f_acent = 154.581, 5042800, 0.022 >>> ar = Componente(98) >>> ar.Tc, ar.Pc, ar.f_acent = 150.687, 4863000, -0.002 >>> mix = Mezcla(5, customCmp=[ch4, o2, ar], caudalMolar=1, ... fraccionMolar=[0.5, 0.3, 0.2]) >>> eq = SRK(800, 36451227.52066596, mix, R=8.3144598) >>> fir = eq._phir(800, 5000, eq.yi) >>> delta = 5000 >>> tau = 1/800 >>> print("fir: %0.14f" % (fir["fir"])) fir: 0.11586323513845 >>> print("fird: %0.14f" % (fir["fird"]*delta)) fird: 0.12741566551477 >>> print("firt: %0.15f" % (fir["firt"]*tau)) firt: -0.082603152680518 >>> print("firdd: %0.15f" % (fir["firdd"]*delta**2)) firdd: 0.024895937945147 >>> print("firdt: %0.15f" % (fir["firdt"]*delta*tau)) firdt: -0.077752734990782 >>> print("firtt: %0.14f" % (fir["firtt"]*tau**2)) firtt: -0.10404751064185 >>> print("firddd: %0.16f" % (fir["firddd"]*delta**3)) firddd: 0.0060986538256190 >>> print("firddt: %0.16f" % (fir["firddt"]*delta**2*tau)) firddt: 0.0089488831000362 >>> print("firdtt: %0.15f" % (fir["firdtt"]*delta*tau**2)) firdtt: -0.097937890490398 >>> print("firttt: %0.14f" % (fir["firttt"]*tau**3)) firttt: 0.15607126596277
- _GEOS(xi)[source]¶
Definition of parameters of generalized cubic equation of state, each child class must define in this procedure the values of mixture a, b, delta, epsilon. The returned values are not dimensionless.
- Parameters:
- xilist
Molar fraction of component in mixture, [-]
- Returns:
- parameterslist
Mixture parameters of equation, a, b, c, d
- _alfa(cmp, T)[source]¶
α parameter calculation procedure, separate of general procedure to let define derived equation where only change this term.
This method use the original alpha formulation for temperatures below the critical temperature and can choose by configuration between:
Boston-Mathias formulation
Nasrifar-Bolland formulation
- Parameters:
- cmpcomponente.Componente
Componente instance
- Tfloat
Temperature, [K]
- Returns:
- alphafloat
alpha parameter of equation, [-]