PRODE, ideas that work !

 

Prode Properties
Properties of pure fluids and mixtures,
multiphase equilibria, process simulation

Download New release 1.16-31 Nov. 09
Free with limited database.
Properties Documentation
Properties Licence, prices and conditions

Excel application example : phase envelope

Prode Properties can calculate many different types of phase equilibria, the base version has a specific method which permits to print a phase envelope (pressure-temperature vapor-liquid phase diagram with a specified liquid or vapor fraction curve / curves) directly in Excel, Matlab or any compatible application including custom software.

Before to use Properties from Excel you must load the add-in (file properties.xla) which instructs Excel about Prode Properties library, you need to go through this procedure only once, to load the add-in open Excel and choose the Tools/Add-ins menu item, you’ll see a list of add-ins, some checked, some not checked. If Prode Properties isn’t listed (and it won’t be unless you went through this procedure earlier) browse for the properties.xla file in \PROPERTIES\Excel folder then back your way out. Now Prode Properties should be listed in the list of add-ins, its box should be checked, and you should see a Prode Properties menu in Excel. If you close Excel and then reopen it Prode Properties menu must still be there. Once you installed the add-in you'll be able to access Prode Properties from within Excel.

First step: define the stream (components, compositions etc.)

Properties includes a Stream editor which permits to access all informations (as compositions, operating conditions, models, options) for all streams which you need to define, to access the Stream editor from Excel Properties menu select Edit Properties

The Stream editor includes several pages, from the first page you can select a stream (Properties can store all the streams required to define a medium size plant) solve a series of flash operations and see the resulting compositions in the different phases, in this page select the stream you wish to define, for example the first.

In the second page you can define a new composition or modify an existing composition, in this example we define C1 0.7 CO2 0.15 H2S 0.15 as molar fractions

In the third page you can define the thermodynamic model and related options for the different calc's, here we define API Soave Redlick Kwong (for all calc's).

The fourth page provides access to BIP (Binary Interaction Parameters) for the different models, you can enter specific values or click on "Load BIPs" button to get the predefined BIPs from databank.

Finally we must save the new data, in the first page click on "Save" button, note that you can redefine the name of the stream as you wish (editing the cell near the button "Save"), you can define / modify many streams following the procedure described.
Once defined the stream you may wish to define the units which we wish to utilize in our problem, in stream editor go then to the "Units" dialog

here you can select the units which you need for a specific problem, in this example for the pressure (first row) select Bar.a , notice that unit for temperature is K (but you can set the units which you prefer) then click on Ok button to accept new values and leave the Properties editor.
Now you are ready to use Properties for calculating all the properties which you need, however there is still a last thing to do if you do not wish to lose all data when leaving a Excel page, precisely to save data to a file, to save data to a file from Excel Properties menu select "Save a Archive"

then select the file "def.ppp" if you wish that Properties utilizes this data as default (this is the normal , recommended option), differently set a different name (you can for example define different names for different projects) but you will need to load that specific Archive before to make calc's for that project and since Excel reloads Properties with any new page this may result tedious...
Properties saves on the file also the units of measurement so you can define different streams and different units in different projects.

Now you can calculate all the properties which you need with the units which you prefer for all the streams defined in that project.

Second step: print a phase envelope in Excel.

For calculating and printing the phase envelope we’ll use a predefined Excel page distributed with Prode Properties, from Excel menu File->open , in Excel folder (Prode Properties installation) select the file phasenv.xls

This page contains a little VBA code to tranfer the calculated equilibrium values (the dew line, bubble line and a line with specified liquid fraction) from Prode Properties to Excel, if required you can easily modify the code for printing a series of lines with specified liquid or vapor fraction. To print a phase envelope you must define the stream (we select the first stream, which we defined with composition C1 0.7 CO2 0.15 H2S 0.15 and API SRK as model) and the specified liquid (or vapor) fraction (we define 0.6 as value) then select the button "calculate phase diagram".
Properties does all the work and the calculated equilibrium points including critical points, cricondentherm and cricondenbar are printed in Excel page for your analysis.

Here the phase diagram shows the critical point, the CricondenBar and the CricondenTherm

In the diagram the red line is the dew line, the black line is the bubble line and the blue line is the line of specified phase fraction, we can require the procedure to plot any value from 0 -dew line- to 1 -bubble line-, herebelow the example of a line with 0.05 liquid fraction.

Note that Prode Properties includes methods for calculating critical points, CricondenBar and CricondenTherm in Excel cells, see the paragraph "Methods for thermodynamic calc’s" in operating manual for the details.

  • methods StrPc() and StrTc() returns the critical pressure (or temperature) of the nth (from 1 to 5) critical point found.
  • methods StrCBp() and StrCBt() returns the pressure (or temperature) of the CricondenBar (the equilibrium point with maximum pressure).
  • methods StrCTp() and StrCTt() returns the pressure (or temperature) of the CricondenTherm (the equilibrium point with maximum temperature).

To get the value of critical pressure enter the macro =StrPc(1,1) where (1,1) refers to the stream 1 and first critical point detected, we enter this macro in B1, in B2 we enter the macro =StrTc(1,1) to calculate the critical temperature in the same way, in cells B3 and B4 we enter the macros = StrCBp(1) for CricodenBar pressure and = StrCTt(1) for CricodenTherm temperature.

Note that as default Properties doesn't calculate the true critical points but estimates the values, the estimate is reasonably accurate and the procedure runs fast, for calculating the "true" critical points in Stream->Models you must change the option for Critical points calculation to Calculate all critical points detected and save the stream

The calculated values for critical point are 7954697 Pa versus 7954726 Pa estimated and 232.496 K versus 232.496 K estimated, a very little difference in this case, the errors are usually small but in some cases they may be large.
Note that even simple compositions can show a complex behaviour, herebelow is the example of the mixture with composition Methane 0.9 H2S 0.1 model API Soave Redlick Kwong. The blue line shows a liquid fraction of 0.05

For the above mentioned mixture Prode Properties calculates the critical pressure as 6114984 Pa (versus an estimated value of 6116029 Pa) and the critical temperature as 209.77 K (versus an estimated value of 209.78 K).
The Newton solver included in the base version of Prode Properties is reasonably fast (different versions based on simplified models are available on request), for a ten components natural gas mixture (see below) it calculates the phase envelope (with estimated values for critical point) in about 4 seconds (i.5 GHZ Pentium), however it takes about 10 seconds to complete when the true critical points calculation is required.

For this 10 components mixture the procedure calculates the critical pressure as 14419395 Pa (versus an estimated value of 14594802 Pa) and the critical temperature as 271.335 K (versus an estimated value of 269.8 K).

Technical features overview (Windows version)

  • Entirely written in C++, Microsoft MFC provides Microsoft Windows functionalities.
  • Up to 100 different streams with up to 50 components per stream (user can redefine)
  • Several compilations of chemical data and BIPs are available, the user can add new components and BIPs
    • free proprietary compilation with data on 1000+ chemicals
    • flexible database format works with all majour standards including DIPPR.
  • Comprehensive set of thermodynamic models, base version includes Regular, Wilson, NRTL, UNIQUAC, UNIFAC, Soave-Redlich-Kwong, Peng-Robinson, Benedict Webb Rubin (Starling) BWRS, Steam Tables IAPWS 95, AGA 8, Lee-Kesler (Plocker) LKP , models as PC-SAFT etc. are available on request.
  • Selectable units of measurement
  • Procedure for fitting BIP to measured VLE / LLE data points (data regression)
  • Procedure for fitting BIP to VLE values calculated with UNIFAC
  • Functions for simulating operating blocks (mixer, gas separator, liquid separator) **
  • Functions for accessing component data in database (the user can define mixing rules)
  • vapor-liquid-solid fugacity plus derivatives vs. temperature pressure composition
  • vapor-liquid-solid enthalpy plus derivatives vs. temperature pressure composition
  • vapor-liquid-solid entropy plus derivatives vs. temperature pressure composition
  • vapor-liquid-solid molar volume plus derivatives vs. temperature pressure composition
  • Flash at Bubble and Dew point specifications and P (or T)
  • Flash at given temperature (T) and pressure (P) multiphase vapor-liquid-solid
  • Flash at given liquid fraction (vaporization ratio) and P (or T)
  • Flash at given enthalpy (H) and P multiphase vapor-liquid-solid **
  • Flash at given entropy (S) and P multiphase vapor-liquid-solid **
  • Rigorous (True) critical point plus Cricondentherm and Cricondenbar
  • vapor-liquid-solid density
  • vapor-liquid Isobaric specific heat (Cp) and Isochoric specific heat (Cv) plus cp/cv
  • Gas heating value
  • Gas Wobbe index
  • Gas Specific gravity
  • vapor-liquid Joule Thomson coefficients
  • vapor-liquid Isothermal compressibility
  • vapor-liquid Speed of sound
  • vapor-liquid Viscosity
  • vapor-liquid Thermal conductivity
  • vapor compressibility factor
  • liquid Surface tension
  • ** some methods are available in extended / custom versions

Typical applications

  • Properties of pure fluids and mixtures
  • Thermodynamics, physical, thermophysical properties
  • Process simulation
  • Heat / Material Balance
  • Process Control
  • Process Optimization
  • Equipment's Design
  • Separations
  • Instrument's Design
  • Realtime applications
  • petroleum, refining, natural gas, hydrocarbon, chemical, petrochemical, pharmaceutical, air conditioning, energy, mechanical industry
Prode Engineering Perspective users are invited to contact Prode for discussing the applications of Prode Properties