polykin.thermo.flash¤
residual_Rachford_Rice ¤
residual_Rachford_Rice(
beta: float,
K: FloatVector,
z: FloatVector,
derivative: bool = False,
) -> tuple[float, ...]
Rachford-Rice flash residual function and its derivative.
The residual function is defined as:
and the derivative with respect to \(\beta\) is:
where \(K\) is the vector of K-values, \(z\) is the vector of feed mole fractions, and \(\beta\) is the vapor phase fraction.
References
- Rachford, H.H., and J.D. Rice. "Procedure for Use of Electronic Digital Computers in Calculating Flash Vaporization Hydrocarbon Equilibrium", J. Pet. Technol. 4 (1952): 19-3.
| PARAMETER | DESCRIPTION |
|---|---|
beta
|
Vapor phase fraction [mol/mol].
TYPE:
|
K
|
K-values.
TYPE:
|
z
|
Feed mole fractions [mol/mol].
TYPE:
|
derivative
|
Flag specifying if the derivative should be returned.
TYPE:
|
| RETURNS | DESCRIPTION |
|---|---|
tuple[float, ...]
|
Tuple with residual and derivative, |
See Also
solve_Rachford_Rice: related method to solve the equation.
Source code in src/polykin/thermo/flash/vle.py
560 561 562 563 564 565 566 567 568 569 570 571 572 573 574 575 576 577 578 579 580 581 582 583 584 585 586 587 588 589 590 591 592 593 594 595 596 597 598 599 600 601 602 603 604 605 606 607 608 609 610 611 612 613 | |