SIMULIS® THERMODYNAMICSA CAPE-OPEN COMPLIANT FRAMEWORK
FOR USERS AND DEVELOPERS
2007 AIChE Annual MeetingSalt Lake City, Utah
#459e CAPE-OPEN Thermodynamic & Physical Properties Interface (TD002)
Olivier Baudouin, Alain Vacher, Stéphane Déchelotte
ProSim SAStratège Bâtiment ABP 27210F-31672 LABEGE CedexFrance
E-mail: [email protected]: www.prosim.net
www.prosim.net
Simulis Thermodynamics – 2007 AIChE Annual Meeting - Salt Lake City - November 4-9, 2007
OUTLINE
Simulis ® Thermodynamics overview
Its different levels of use
Within Microsoft ® EXCEL
Integrated in other codes
As a framework to develop new thermodynamic models or to welcome existing ones
Concluding remarks
www.prosim.net
Simulis Thermodynamics – 2007 AIChE Annual Meeting - Salt Lake City - November 4-9, 2007
SIMULIS® THERMODYNAMICS
Software component
for computing thermophysical properties and
phase equilibria on pure components
or mixtures
in Microsoft ® Excel, Matlab ® or other
applications
www.prosim.net
Simulis Thermodynamics – 2007 AIChE Annual Meeting - Salt Lake City - November 4-9, 2007
THERMO-PHYSICAL PROPERTIES SUPPORTED
� Derivatives of the properties with respect to temperature, pressure and number of moles are also provided
Transport propertiesIsobaric specific heat (Cp)Dynamic viscosity Thermal conductivity DensityMolar VolumeMolar densitySurface tensionMolecular weight
Thermodynamic propertiesEnthalpy (H)Entropy (S)Internal energy (U)Isochoric specific heat (Cv)Enthalpy of vaporization
Compressibility propertiesCompressibility factor Gamma (Cp/Cv ratio)Sound speed
Non-ideal propertiesActivity coefficientsFugacity coefficients and FugacityLn of fugacity coefficients
www.prosim.net
Simulis Thermodynamics – 2007 AIChE Annual Meeting - Salt Lake City - November 4-9, 2007
FLASHES SUPPORTED
Liquid-Liquid equilibriaFlash at given temperature and pressure
Liquid-Liquid-Vapor equilibriaBubble temperatureFlash at given enthalpy and pressureFlash at given temperature and pressureFlash at given vaporization ratio and pressure
PωVHSU
P ω V H STT
ULiquid-Vapor equilibriaBubble and dew temperatures and pressuresFlash at given temperature (T) and pressure (P)
Flash at given vaporization ratio (ω) and P (or T) Flash at given enthalpy (H) and P (or T, or V, or U)Flash at given entropy (S) and P (or T, or V, or H, or U)Flash at given internal energy (U) and P (or T, or V)Flash at given volume (V) and P (or T)
www.prosim.net
Simulis Thermodynamics – 2007 AIChE Annual Meeting - Salt Lake City - November 4-9, 2007
New components can be added and properties modified
Estimation methods are included
A regression of experimental data tool is provided
Existing in-house property databases can be include d
All the properties of pure components can be access ed, modified, plotted,…
PURE COMPONENT PROPERTIES
Supplied with a database of over 2 000 components i ncluding AIChE's DIPPR ® database
www.prosim.net
Simulis Thermodynamics – 2007 AIChE Annual Meeting - Salt Lake City - November 4-9, 2007
A WIDE SET OF THERMODYNAMIC MODELS
Equations of StateSoave-Redlich-Kwong (SRK)
Peng-Robinson (PR)Lee-Kesler-Plöcker (LKP)
Benedict-Webb-Rubin modified Starling (BWRS)
Nakamuraetc…
Activity coefficients modelsNRTL
UNIQUACUNIFAC (Larsen, Dortmund,…)
Wilson
etc…
Combined approach modelsMHV2MHV1
PSRK
etc…
Specific systemsPure Water (NBS/NRC steam tables - IAPS,1984)
Amines
Sour-Wateretc…
ElectrolytesEdwardsUNIQUAC electrolyte
ULPDHS
etc…� BIP databases included
� New methods are continuously implemented to cover a wide field of applications: oil & gas, fine chemicals, etc…
www.prosim.net
Simulis Thermodynamics – 2007 AIChE Annual Meeting - Salt Lake City - November 4-9, 2007
0
200
400
600
800
1000
1200
1400
1600
1800
2000
2200
-300 -200 -100 0 100 200 300
Pressure (psi)
Temperature (°F)
Tc=222.876Pc=1 871.646
Temp.=60.000Pres.=600.000
EXAMPLE OF CALCULATION PERFORMED
WITH SIMULIS® THERMODYNAMICS
Phase envelope and hydrate line of a natural gas mixt ure with PR EOS
www.prosim.net
Simulis Thermodynamics – 2007 AIChE Annual Meeting - Salt Lake City - November 4-9, 2007
A FULL SET OF SERVICES AVAILABLE
Data regression of pure components experimental pro perties
Graphical display of properties on temperature, pre ssure or composition ranges
Generation and export of property tables (PSF files to HTFS, PVT files to OLGA…)
Estimation of pure component properties
Link with DPP
Calculation of petroleum fractions properties
Unit conversions
etc…
� All these services become automatically available i n any software embedding Simulis ® Thermodynamics
www.prosim.net
Simulis Thermodynamics – 2007 AIChE Annual Meeting - Salt Lake City - November 4-9, 2007
OUTLINE
Simulis ® Thermodynamics overview
Its different levels of use
Within Microsoft ® EXCEL
Integrated in other codes
As a framework to develop new thermodynamic models or to welcome existing ones
Concluding remarks
www.prosim.net
Simulis Thermodynamics – 2007 AIChE Annual Meeting - Salt Lake City - November 4-9, 2007
WITHIN MICROSOFT® EXCEL
Thermodynamic functions are added to Microsoft ® Excel …
…and used in spreadsheets as native Excel functions …
… to perform more or less complex engineering calculations …
…but with rigorous thermodynamics
www.prosim.net
Simulis Thermodynamics – 2007 AIChE Annual Meeting - Salt Lake City - November 4-9, 2007
EXAMPLE OF A MCCABE & THIELE METHOD
FOR BINARY DISTILLATION IN EXCEL
www.prosim.net
Simulis Thermodynamics – 2007 AIChE Annual Meeting - Salt Lake City - November 4-9, 2007
OUTLINE
Simulis ® Thermodynamics overview
Its different levels of use
Within Microsoft ® EXCEL
Integrated in other codes
As a framework to develop new thermodynamic models or to welcome existing ones
Concluding remarks
www.prosim.net
Simulis Thermodynamics – 2007 AIChE Annual Meeting - Salt Lake City - November 4-9, 2007
SEAMLESS INTEGRATION IN ANY CODE
� Visual Basic or VBA (Microsoft ® Excel)
� MATLAB ®
� C++
� Delphi
� FORTRAN
� C#
� etc…
����However, the interface between the embedding applic ation and Simulis ®
Thermodynamics must be coded
Thanks to its component based architecture, Simulis ®
Thermodynamics can be easily embedded in any applic ation that supports the COM/DCOM technology:
www.prosim.net
Simulis Thermodynamics – 2007 AIChE Annual Meeting - Salt Lake City - November 4-9, 2007
CO THERMODYNAMIC SOCKET
Successfully tested with �Multiflash (Infochem)
�PPDS (TUV-NEL)
�Aspen Properties (AspenTech)
�COM Thermo (AspenTech)
�IVCSEPThermoSystem (IVC-SEP)
�COCO TEA (AmsterCHEM),
�etc…
Ability to use an external thermodynamic model (CAPE-OPEN "Property
Package")
����If required, a third party thermo package can be us ed within any application embedding Simulis ® Thermodynamics
Implementation �Thermo 1.0�Thermo 1.1 (Nov. 2007)
ExternalCAPE-OPEN
PropertyPackage
Simulis ®
Thermodynamics
ClientSoftware
MS-ExcelProSimPlus,MATLAB, etc
External software able to generate
CO packages(Aspen Properties,
Multiflash, PPDS,…)
www.colan.org
www.prosim.net
Simulis Thermodynamics – 2007 AIChE Annual Meeting - Salt Lake City - November 4-9, 2007
CO THERMODYNAMIC PLUG
Successfully tested in �Aspen Plus (2004 and v12.1)
�Aspen Hysys (2004 and v3.2)
�PRO/II (v7.1)
�gPROMS®
�Xist (HTRI)�UNISIM Design�etc…
Ability to generate CAPE-OPEN "Property Packages" to be used within
compliant modeling tools
� The thermo of ProSim can be used in software withou t satisfactory thermo routines
� A thermo expert can prepare with Simulis ® Thermodynamics the model for a complex system, and provide it to its colleagues fo r further "safe" use in their traditional simulation tool (AspenPlus, ProSimPlus,…)
Modeling tool implementing
COThermo Socket
(AspenPlus, HTRI, ProSimPlus, etc)
CO PropertyPackagegenerated by
Simulis ®
Thermodynamics
Implementation �Thermo 1.0�Thermo 1.1 (Nov. 2007)
www.colan.org
Simulis ®
Thermodynamics
ClientSoftware
Microsoft ® ExcelProSimPlus,MATLAB, etc
www.prosim.net
Simulis Thermodynamics – 2007 AIChE Annual Meeting - Salt Lake City - November 4-9, 2007
�Any application that embeds Simulis ® Thermodynamics automatically inherits from its CAPE-OPEN standard compliance
�Seamless integration of Simulis ® Thermodynamics in many codes is allowed
IMPLEMENTS THE STANDARDIZED
CAPE-OPEN INTERFACESwww.colan.org
www.prosim.net
Simulis Thermodynamics – 2007 AIChE Annual Meeting - Salt Lake City - November 4-9, 2007
INTEGRATION IN PROSIMPLUS
ThermodynamicsChemical Reactions
Unit OperationsNumerical Methods
GUI
Conventional simulatorMonolithic program (generally divided
into several source files and DLLs)
Unit Operations
Chemical Reactions
GUI
Numerical Methods
Thermodynamics
Simulis ®
Thermodynamics
ProSimPlusThermodynamic calculations are performed within a component (Simulis ® Thermodynamics)
This component implements CAPE-OPEN interfaces (Plug & Socket)
ProSimPlus also implements CO Unit Socket
www.prosim.net
Simulis Thermodynamics – 2007 AIChE Annual Meeting - Salt Lake City - November 4-9, 2007
OUTLINE
Simulis ® Thermodynamics overview
Its different levels of use
Within Microsoft ® EXCEL
Integrated in other codes
As a framework to develop new thermodynamic models or to welcome existing ones
Concluding remarks
www.prosim.net
Simulis Thermodynamics – 2007 AIChE Annual Meeting - Salt Lake City - November 4-9, 2007
THE "EXPERT MODE"
For users who want:
� to develop their own new thermodynamic models
� or to integrate in Simulis ® Thermodynamics exiting models
� taking advantage of Simulis ® Thermodynamics environment (pure components properties, unit conversions and management,…)
� in view to use these developments in other applications (commercial software, Excel, legacy codes, …)
Two possibilities are offered:
1. VBScript models
2. External DLL models
www.prosim.net
Simulis Thermodynamics – 2007 AIChE Annual Meeting - Salt Lake City - November 4-9, 2007
VBSCRIPT MODELS
Function parameters must satisfy a predefined
syntax (name, type)
Code is directly entered in Simulis®
Thermodynamics
A skeleton is provided
Many available functions
www.prosim.net
Simulis Thermodynamics – 2007 AIChE Annual Meeting - Salt Lake City - November 4-9, 2007
EXTERNAL DLL MODELS
Function parameters must satisfy a predefined
syntax (name, type)
User parameters are supported
Many available functions
An external DLL is plugged
www.prosim.net
Simulis Thermodynamics – 2007 AIChE Annual Meeting - Salt Lake City - November 4-9, 2007
VBScript models:
� Interpreted language ���� not very efficient
� Useful for prototyping or simple functions (Cp,…)
� Can be a first step
DLL models:
� Can be built using any language (FORTRAN, C++,…)
� Allows re-use of existing codes (with some modifications)
� More efficient ����In both cases access to pure component properties, uni ts management,…
VBSCRIPT MODELS VS DLL MODELS
www.prosim.net
Simulis Thermodynamics – 2007 AIChE Annual Meeting - Salt Lake City - November 4-9, 2007
VBScript, external DLL and native models can be mixed (each one computing a different property)
Native models will be used except when a VBScript model or a DLL model is available
Priorities must be given
THE "EXPERT MODE"
www.prosim.net
Simulis Thermodynamics – 2007 AIChE Annual Meeting - Salt Lake City - November 4-9, 2007
Combination of VBScript, external DLL and native models is supported
Native DLL forcalculation of
H and Cp
User DLL forcalculation of
H and Cp
H (Cp)
Cp
H (Cp)CpH (Cp)
H (Cp)
However, no "true re-entrance"
between different modes
THE "EXPERT MODE"
www.prosim.net
Simulis Thermodynamics – 2007 AIChE Annual Meeting - Salt Lake City - November 4-9, 2007
Both VBScript and external DLL models can be used in CAPE-OPEN thermodynamic packages built with Simulis ® Thermodynamics
THE "EXPERT MODE"
"Expert Mode" of Simulis ® Thermodynamics vs CAPE-
OPEN Thermo Wizard
� Easy configuration (access to standard pure components databases,…)
� Predefined access to pure components properties
� User-friendly existing GUIs to access parameters
� Full rewriting is not required (possibility to mix with native existing models)
www.prosim.net
Simulis Thermodynamics – 2007 AIChE Annual Meeting - Salt Lake City - November 4-9, 2007
CONCLUDING REMARKS
Simulis ® Thermodynamics allows several levels of use�Within Microsoft ® Excel to perform more or less
complex engineering calculations�Embedded in other applications taking advantage
of the CAPE-OPEN standard interfaces implemented (plug & socket)
�As a framework to welcome existing thermodynamic models or to develop new ones in view to use them in other applications ("Expert Mode")
www.prosim.net
Simulis Thermodynamics – 2007 AIChE Annual Meeting - Salt Lake City - November 4-9, 2007
CONCLUDING REMARKS
These levels of use can coexist in the same organization allowing:�Minimization of learning time�Consistency of data & results between several appli cations�Reusability of available expertise�Permanence of internal knowledge
The "Expert Mode" of Simulis ® Thermodynamics can be an alternative to CO Thermo Wizard in order to make thermo legacy codes CAPE-OPEN compliant �No knowledge of CAPE OPEN technology required�Reduced development time
SIMULIS® THERMODYNAMICSA CAPE-OPEN COMPLIANT FRAMEWORK
FOR USERS AND DEVELOPERS
2007 AIChE Annual MeetingSalt Lake City, Utah
#459e CAPE-OPEN Thermodynamic & Physical Properties Interface (TD002)
Olivier Baudouin, Alain Vacher, Stéphane Déchelotte
ProSim SAStratège Bâtiment ABP 27210F-31672 LABEGE CedexFrance
E-mail: [email protected]: www.prosim.net