by jasper » 15 October 2014, 14:12
First please run CUP to update COUSCOUS, to resolve a string allocation bug in the Gibbs reactor that causes problems elsewhere in the simulation.
Next, the problem you are seeing is caused by the fact that the actual system (given the selected thermodynamic model, which surely is not accurate; a cubic equation of state is selected without binary interaction parameters to describe the non-ideal behaviour of the compounds involved) has a phase equilibrium at 500 kPa and 28.626775 C (which are the solution conditions of the adiabatic flash) with 2 liquid phases.
TEA does not support two liquid phases. So it finds an incorrect phase equilibrium where it splits off a single liquid phase from the vapor; please note that this is an incorrect solution; at the actual solution a second liquid phase takes part in the equilibrium, changing the compositions and fugacities of all phases involved. A split off vapor would normally be in equilibrium with a liquid at the same conditions as the liquid that was split off, with zero liquid phase fraction. However, another liquid phase exists that is in equilibrium with this vapor phase, which is found in the exit flash of the vapor stream, causing the 9% liquid to appear.
Using TEA I do not think there is a correct solution for this problem. To treat this problem correctly, thermodynamics need to be used that support 2 liquid phases. There are many such thermodynamic servers around, but TEA is not one of them. TEA is restricted to systems that form a single liquid phase.
For completeness, below is the TEA solution compared to the actual solution (given Peng Robinson without binary interaction parameters) of stream3, flashed at 500 kPa, adiabatically:
[table]
[tr] [th] [/th] [th] TEA [/th] [th] Actual solution [/th] [th] unit [/th] [/tr]
[tr] [td] Overall pressure [/td] [td] 500 [/td] [td] 500 [/td] [td] kPa [/td] [/tr]
[tr] [td] Overall temperature [/td] [td] 28.626775 [/td] [td] 28.626775 [/td] [td] °C [/td] [/tr]
[tr] [td] Overall mole fraction [Ethylene] [/td] [td] 35.921661 [/td] [td] 35.921661 [/td] [td] % [/td] [/tr]
[tr] [td] Overall mole fraction [Water] [/td] [td] 59.047568 [/td] [td] 59.047568 [/td] [td] % [/td] [/tr]
[tr] [td] Overall mole fraction [Ethanol] [/td] [td] 5.0307707 [/td] [td] 5.0307707 [/td] [td] % [/td] [/tr]
[tr] [td] Overall flow [/td] [td] 1574.9004 [/td] [td] 1574.9004 [/td] [td] kmol / s [/td] [/tr]
[tr] [td] Overall MW [/td] [td] 0.023032508 [/td] [td] 0.023032508 [/td] [td] kg / mol [/td] [/tr]
[tr] [td] Vapor mole fraction [Ethylene] [/td] [td] 88.633487 [/td] [td] 97.410387 [/td] [td] % [/td] [/tr]
[tr] [td] Vapor mole fraction [Water] [/td] [td] 0.71590845 [/td] [td] 0.71941453 [/td] [td] % [/td] [/tr]
[tr] [td] Vapor mole fraction [Ethanol] [/td] [td] 10.650604 [/td] [td] 1.8701983 [/td] [td] % [/td] [/tr]
[tr] [td] Liquid mole fraction [Ethylene] [/td] [td] 0.001119511 [/td] [td] 0.000842379 [/td] [td] % [/td] [/tr]
[tr] [td] Liquid mole fraction [Water] [/td] [td] 98.797753 [/td] [td] 99.854636 [/td] [td] % [/td] [/tr]
[tr] [td] Liquid mole fraction [Ethanol] [/td] [td] 1.2011278 [/td] [td] 0.14452166 [/td] [td] % [/td] [/tr]
[tr] [td] Liquid 2 mole fraction [Ethylene] [/td] [td] N/A [/td] [td] 2.6717359 [/td] [td] % [/td] [/tr]
[tr] [td] Liquid 2 mole fraction [Water] [/td] [td] N/A [/td] [td] 14.630337 [/td] [td] % [/td] [/tr]
[tr] [td] Liquid 2 mole fraction [Ethanol] [/td] [td] N/A [/td] [td] 82.697927 [/td] [td] % [/td] [/tr]
[/table]