summary file toolkit - rowan universityusers.rowan.edu/~savelski/plantdesign/aspen plus/aplus 111...

218
Summary File Toolkit

Upload: phungnhu

Post on 28-Mar-2018

247 views

Category:

Documents


2 download

TRANSCRIPT

Summary File Toolkit

Part Number: Summary File ToolkitSeptember 2001

Copyright (c) 2001 by Aspen Technology, Inc. All rights reserved.

Aspen Plus, the aspen leaf logo, and Plantelligence are trademarks or registered trademarks of Aspen Technology,Inc., Cambridge, MA.

All other brand and product names are trademarks or registered trademarks of their respective companies.

This manual is intended as a guide to using AspenTech's software. This documentation contains AspenTechproprietary and confidential information and may not be disclosed, used, or copied without the prior consent ofAspenTech or as set forth in the applicable license agreement. Users are solely responsible for the proper use of thesoftware and the application of the results obtained.

Although AspenTech has tested the software and reviewed the documentation, the sole warranty for the softwaremay be found in the applicable license agreement between AspenTech and the user. ASPENTECH MAKES NOWARRANTY OR REPRESENTATION, EITHER EXPRESSED OR IMPLIED, WITH RESPECT TO THISDOCUMENTATION, ITS QUALITY, PERFORMANCE, MERCHANTABILITY, OR FITNESS FOR APARTICULAR PURPOSE.

CorporateAspen Technology, Inc.Ten Canal ParkCambridge, MA 02141-2201USAPhone: (1) (617) 949-1021Toll Free: (1) (888) 996-7001Fax: (1) (617) 949-1724URL: http://www.aspentech.com

DivisionDevelopment Services OrganizationAspen Technology, Inc.Ten Canal ParkCambridge, MA 02141-2201USAPhone: (617) 949-1000Fax: (617) 949-0130URL: http://www.aspentech.com

Aspen Plus 11.1 Summary File Toolkit Contents •••• iii

Contents

Introduction 1-1Intended Audience for the Summary File Toolkit ...........................................................1-1Overview of the Summary File Toolkit ...........................................................................1-1Related Documentation ....................................................................................................1-1

Installation Manual...............................................................................................1-1User Guide............................................................................................................1-2Getting Started Guides .........................................................................................1-2Other Documentation ...........................................................................................1-2

Technical Support ............................................................................................................1-2World Wide Web .................................................................................................1-2Online Technical Support Center.........................................................................1-2Hours ....................................................................................................................1-3Phone....................................................................................................................1-3Fax........................................................................................................................1-4E-mail ...................................................................................................................1-4

Getting Started 2-1The Summary File and Toolkit ........................................................................................2-1Initializing the Toolkit......................................................................................................2-2

Accessing the Required Files ...............................................................................2-2Getting the Summary File Name......................................................................................2-3

Defining Units of Measurement...........................................................................2-3Specifying a Value for Missing Results...............................................................2-4

Determining the Data Dimensions ...................................................................................2-4Retrieving Data for an Object ..........................................................................................2-6Using the Toolkit With a Hierarchical Aspen Plus Run ..................................................2-7Linking Toolkit Subroutines into Your Module ..............................................................2-8Creating a Toolkit Application for Windows...................................................................2-9

About the Windows Version ................................................................................2-9Linker Directive Commands for Windows ....................................................................2-10Calling Summary File Toolkit Routines ........................................................................2-11

Opening and Closing Files Using the Summary File Toolkit ............................2-11Using Fortran to Call Routines...........................................................................2-11Using C to Call Routines....................................................................................2-12

General Subroutines 3-1

iv •••• Contents Aspen Plus 11.1 Summary File Toolkit

Initializing the Summary File Toolkit..............................................................................3-1Closing the Summary File Toolkit ...................................................................................3-3Opening and Closing Files ...............................................................................................3-4Retrieving Run Information .............................................................................................3-5

Standard Run Information....................................................................................3-5Run Titles .............................................................................................................3-6Accounting Information .......................................................................................3-7

Retrieving Flowsheet Balance Results.............................................................................3-7Units Conversion..............................................................................................................3-8

Changing Units Sets .............................................................................................3-8Converting Units for Real Numbers.....................................................................3-9Determining Units Labels ..................................................................................3-10

Component Information Retrieval .................................................................................3-10Number of Components .....................................................................................3-10Component IDs ..................................................................................................3-11Component Alias Names....................................................................................3-11Component Properties ........................................................................................3-12

Sensitivity Block Results ...............................................................................................3-12Identifying Sensitivity Blocks............................................................................3-12Determining Sensitivity Dimensions .................................................................3-13Retrieving Sensitivity Results ............................................................................3-14

Block Result Subroutines 4-1Block Identification..........................................................................................................4-2

Block IDs..............................................................................................................4-2Next Block............................................................................................................4-2

Block Connectivity Information.......................................................................................4-3Number of Inlet and Outlet Streams ....................................................................4-3Stream Names and Types.....................................................................................4-3Additional Port Information .................................................................................4-4

Standard Block Results ....................................................................................................4-7Dimensions of Standard Scalar Results ...............................................................4-7Standard Scalar Block Results .............................................................................4-8

Compressor Results..........................................................................................................4-9Dimensions of Performance Results ....................................................................4-9Stage-by-Stage Performance Results .................................................................4-10Dimensions of Wheel-by-Wheel Performance Results......................................4-11Wheel-by-Wheel Performance Results ..............................................................4-11

Compressor Profile Results............................................................................................4-12Dimensions of MCompr Profile Results ............................................................4-12MCompr Profile Results ....................................................................................4-13MCompr Cooler Profile Results.........................................................................4-13

Heat Exchanger Results .................................................................................................4-14Number of Detailed Results ...............................................................................4-15Detailed Results..................................................................................................4-15Velocity and Pressure Results ............................................................................4-16

Aspen Plus 11.1 Summary File Toolkit Contents •••• v

Heat Exchanger Results Dimensions .................................................................4-16Heat Exchanger Zone Results ............................................................................4-17Heat Exchanger Shell Results ............................................................................4-17Heat Exchanger Tube Results ............................................................................4-18Heat Exchanger Baffle Results ..........................................................................4-19Heat Exchanger Nozzle Results .........................................................................4-19

Heat Exchanger Profiles.................................................................................................4-20Heat Exchanger Profile Size ..............................................................................4-21Heat Exchanger Profile Properties .....................................................................4-21Heat Exchanger Profile Results..........................................................................4-21

Column Results ..............................................................................................................4-22Number of Columns ...........................................................................................4-23Column Profile Dimensions...............................................................................4-23Column Profile Properties..................................................................................4-24Non-Component-Dependent Column Profiles ...................................................4-24Component-Dependent Column Profiles ...........................................................4-25RadFrac Thermosyphon Reboiler Results..........................................................4-25Interconnecting Stream and Pumparound Results .............................................4-27

Additional Data for PetroFrac Models ...........................................................................4-30Dimensions of Additional Data..........................................................................4-30Additional Scalar Results Data ..........................................................................4-31Additional PetroFrac Profile Properties .............................................................4-32Additional Property Profiles...............................................................................4-32Furnace Data for PETROFRAC.........................................................................4-33Component-Dependent Properties for the PetroFrac Furnace ...........................4-34Pumparound Results for PetroFrac Columns .....................................................4-34Connectivity Data for PetroFrac Strippers .........................................................4-35Additional Data for RateFrac Models ................................................................4-36Dimensions of Additional Scalar Data...............................................................4-36Additional Scalar Results Data ..........................................................................4-37Dimensions of Component Split Fractions ........................................................4-37Component Split Fractions.................................................................................4-38Number of Liquid Phases...................................................................................4-38

Tray Reports...................................................................................................................4-39Tray Report Dimensions ....................................................................................4-39Sequential Tray Report Properties .....................................................................4-39Specific Tray Report Properties .........................................................................4-40

Tray/Packing Sizing and Rating.....................................................................................4-41Number of Columns ...........................................................................................4-42Number of Column Sections ..............................................................................4-42Column Section Types and Numbers.................................................................4-42Size of a Column Section...................................................................................4-43Scalar Results for a Column Section..................................................................4-43Column Section Profile Properties.....................................................................4-44Column Section Profiles ....................................................................................4-45

Reactor Results...............................................................................................................4-46

vi •••• Contents Aspen Plus 11.1 Summary File Toolkit

Number of Reactor Substreams..........................................................................4-46Reactor Profile Dimensions ...............................................................................4-47Reactor Profile Properties ..................................................................................4-47Non-Component-Dependent Reactor Profiles ...................................................4-48Component-Dependent Reactor Profiles............................................................4-48Number of Components with Component Attribute Results .............................4-49Number of Attributes for a Component .............................................................4-49Details of a Component Attribute ......................................................................4-50Component Attribute Results .............................................................................4-50Number of Continuous Feed Streams ................................................................4-51Continuous Feed Stream Results........................................................................4-51RBATCH Vent Accumulator Results ................................................................4-52RBatch Vent Profile Results ..............................................................................4-54Reaction Data .....................................................................................................4-57

Reactor Property Reports ...............................................................................................4-59Number of Reports for a Reactor Block.............................................................4-60Size of a Reactor Property Report......................................................................4-60Sequential Reactor Report Properties ................................................................4-61Specific Reactor Report Properties ....................................................................4-62

Pipeline Results ..............................................................................................................4-63Pipeline Results Dimensions..............................................................................4-63Non-Component-Dependent Pipeline Inlet and Outlet Conditions....................4-64Component-Dependent Pipeline Inlet and Outlet Property Names ...................4-65Component-Dependent Pipeline Inlet and Outlet Conditions............................4-65Segment Data Property Names ..........................................................................4-66Pipeline Segment Data .......................................................................................4-66Pipeline Node Property Names ..........................................................................4-67Pipeline Node Results ........................................................................................4-67Pipeline Profile Property Names ........................................................................4-68Pipeline Profile Results ......................................................................................4-68

Pipe Results ....................................................................................................................4-69Pipe Standard Profile Dimensions......................................................................4-69Pipe Standard Profile Property Names...............................................................4-70Pipe Standard Profile Properties ........................................................................4-70Pipe Property Reports.........................................................................................4-71

Block VLE Results.........................................................................................................4-73Heating/Cooling Curves.................................................................................................4-74

Number of Heating/Cooling Curves for a Block ...............................................4-74Heating/Cooling Curves for a Block..................................................................4-75Size of a Heating/Cooling Curve .......................................................................4-76Standard Heating/Cooling Curve Results ..........................................................4-76Sequential Heating/Cooling Curve Properties ...................................................4-77Specific Heating/Cooling Curve Properties .......................................................4-78Interconnecting Stream IDs................................................................................4-79

Stream Result Subroutines 5-1

Aspen Plus 11.1 Summary File Toolkit Contents •••• vii

Stream Identification ........................................................................................................5-2Listing Stream IDs ................................................................................................5-2Determining the Next Stream................................................................................5-2

Material Stream Results ....................................................................................................5-3Retrieving Basic Stream Information....................................................................5-3Listing Substream IDs...........................................................................................5-3Retrieving Stream Results.....................................................................................5-4Retrieving a Single Stream Property.....................................................................5-4

Heat and Work Stream Results .........................................................................................5-5Component Attribute Results............................................................................................5-5

Determining the Number of Components with Attributes.....................................5-6Determining Number of Attributes for a Component............................................5-6Determining Component Attribute Size................................................................5-7Retrieving Component Attribute Values ...............................................................5-7

Substream Attribute Results..............................................................................................5-8Determining the Number of Substream Attributes ................................................5-8Determining Substream Attribute Size..................................................................5-8Retrieving Substream Attribute Values.................................................................5-9

Stream Property Set Results..............................................................................................5-9Determining Dimensions of Stream Property Values............................................5-9Retrieving Stream Property Results ....................................................................5-10

Physical Property Table Results Subroutines 6-1Property Table Identification ...........................................................................................6-1Property and Flashcurve Table Results............................................................................6-2

Determining Property Table Dimensions.............................................................6-2Retrieving Sequential Properties in a Table.........................................................6-2Retrieving Specific Properties from a Table ........................................................6-3

Pressure-Temperature Envelope Results..........................................................................6-4Determining Dimensions for Properties in the Envelope.....................................6-4Determining Envelope Dimensions .....................................................................6-4Retrieving Temperature and Pressure for Envelope Branch................................6-5Retrieving Sequential Envelope Properties..........................................................6-6Retrieving Specific Envelope Properties..............................................................6-7

Costing Results Subroutines 7-1Equipment Item Identification .........................................................................................7-2

Determining Number of Equipment Items...........................................................7-2Listing Equipment Items ......................................................................................7-2Determining Next Equipment Item......................................................................7-3

Equipment Item Results ...................................................................................................7-3Retrieving Equipment Item Costing Results........................................................7-3Determining Equipment Item Sizing Results.......................................................7-4Retrieving Equipment Item Sizing Results ..........................................................7-4

Pressure Relief Subroutines 8-1

viii •••• Contents Aspen Plus 11.1 Summary File Toolkit

Pressure Relief Block Identification ................................................................................8-1Determining the Number of Pressure Relief Blocks............................................8-2Listing Pressure Relief Blocks .............................................................................8-2Determining the Next Pressure Relief Block .......................................................8-2

Pressure Relief Results.....................................................................................................8-3Determining the Number of Substreams..............................................................8-4Determining Dimensions of Pressure Relief Arrays ............................................8-4Listing Profile Properties .....................................................................................8-5Retrieving Dynamic Scalar Results......................................................................8-6Retrieving Steady-State Scalar Results ................................................................8-6Retrieving Non-Component-Dependent Dynamic Profiles .................................8-7Retrieving Dynamic Component-Dependent Profiles..........................................8-8Retrieving Steady-State Profiles ..........................................................................8-8Determining Vent Accumulator Profile Dimensions ...........................................8-9Listing Vent Accumulator Profile Properties.......................................................8-9Retrieving Non-Component-Dependent Vent Accumulator Profiles ................8-10Retrieving Component-Dependent Vent Accumulator Profiles.........................8-10Determining Pressure Relief Vent Profile Dimensions......................................8-11Listing Vent Profile Properties...........................................................................8-11Retrieving Position-Dependent Vent Profiles ....................................................8-12Retrieving Component-Dependent Vent Profiles ..............................................8-13

Examples 9-1Example 1: Stream Heat and Material Balance Table Generation...................................9-2

Declaring Variables and Dimensioning ...............................................................9-2Initializing the Toolkit..........................................................................................9-3Finding Number of Streams .................................................................................9-3Finding Component Molecular Weight................................................................9-4

Writing Stream Table .......................................................................................................9-5Example 2: Interactive Heating/Cooling Curve Table Generation ..................................9-8

Declaring Variables..............................................................................................9-8Initializing the Toolkit..........................................................................................9-8Finding Number of Blocks...................................................................................9-9Finding Blocks with Heating/Cooling Curves .....................................................9-9Prompting for Block Name ................................................................................9-10Finding Heating/Cooling Curves for Selected Block.........................................9-10Finding Dimensions of Heating/Cooling Curve.................................................9-11Retrieving Standard Heating/Cooling Curve Results.........................................9-11Retrieving Property Sets.....................................................................................9-12

Example 3: Column Profile Results Written to Plot File ...............................................9-14Opening Files and Initializing Toolkit ...............................................................9-14Finding List of Blocks........................................................................................9-15Finding List of Properties...................................................................................9-16Retrieving Selected Property Profile..................................................................9-17Closing the Application......................................................................................9-17

Example 4: Distillation Column Diagram Generation...................................................9-20

Aspen Plus 11.1 Summary File Toolkit Contents •••• ix

Initializing the Toolkit........................................................................................9-20Retrieving Basic Block Results..........................................................................9-21Retrieving Inlet and Outlet Stream Flows..........................................................9-22Finding Inlet and Outlet Stream IDs ..................................................................9-23

Units 10-1Table A.1 - Units Options ..............................................................................................10-2

Property Names 11-1Table B.1 - Standard Property Names............................................................................11-1Table B.2 - Mixture Thermodynamic Properties .........................................................11-15

Volume.............................................................................................................11-15Flow Rates, Fractions.......................................................................................11-15Enthalpy, Entropy, Gibbs Energy, Heat Capacity............................................11-15Other properties................................................................................................11-16

Table B.3 - Thermodynamic Properties of Components in Mixtures ..........................11-17Table B.4 - Pure Component Thermodynamic Property Sets......................................11-17Table B.5 - Electrolyte Property Sets...........................................................................11-18Table B.6 - Transport Properties ..................................................................................11-19

Mixture .............................................................................................................11-19Component in a Mixture ..................................................................................11-19Pure Components .............................................................................................11-19

Table B.7 - Petroleum-Related Properties for Mixtures ..............................................11-20Distillation Curves ...........................................................................................11-20Distillation Temperature ..................................................................................11-21Distillation Volume and Weight Percent .........................................................11-22Bulk Petroleum Property Values from Assay Curves......................................11-22Petroleum Cuts .................................................................................................11-23Petroleum Property Curves ..............................................................................11-24

Table B.8 - Elemental Analysis of Mixtures................................................................11-25Table B.9 - Nonconventional Component Properties ..................................................11-26Table B.10 - Property Names for Costing Results .......................................................11-26

Equipment Type: HEATX ...............................................................................11-26Equipment Type: AIRCOOL ...........................................................................11-27Equipment Type: FIRED-HEATER ................................................................11-27Equipment Type: PUMP ..................................................................................11-28Equipment Type: COMPR...............................................................................11-28Equipment Type: BLOWER ............................................................................11-29Equipment Type: TRAY-TOWER...................................................................11-29Equipment Type: TRAY-TOWER Section Results.........................................11-30Equipment Type: USER...................................................................................11-30Equipment Type: V-VESSEL ..........................................................................11-30Equipment Type: H-VESSEL ..........................................................................11-31Equipment Type: TANK..................................................................................11-31

x •••• Contents Aspen Plus 11.1 Summary File Toolkit

Aspen Plus 11.1 Summary File Toolkit Introduction •••• 1-1

Introduction

Intended Audience for the SummaryFile ToolkitThe intended audience for this toolkit is application developerswho need to get information from Aspen Plus simulations intotheir applications, and prefer a file based data transfer to datatransfer through OLE Automation.

Overview of the Summary File ToolkitAn Aspen Plus summary file is an ASCII file produced by AspenPlus for every simulation run, containing all the results for that run.The Summary File Toolkit is a set of Fortran subroutines that youcan use to build a program to extract results from an Aspen Plussummary file.This reference manual describes the Summary File Toolkit andhow to build programs using the toolkit.The manual assumes that you are familiar with Fortran, AspenPlus, and the results of an Aspen Plus simulation.Beginning with Aspen Plus 11.1, there is also an XML Results fileavailable from Aspen Plus which can be processed by standardXML tools. This manual does not document the format of that file.

Related DocumentationIn addition to this document, a number of other documents areprovided to help users learn and use Aspen Plus. Thedocumentation set consists of the following:AES Installation ManualInstallation Manual

1-2 •••• Introduction Aspen Plus 11.1 Summary File Toolkit

Aspen Plus User Guide

Aspen Plus Getting Started Building and Running a Process ModelAspen Plus Getting Started Modeling Processes with ElectrolytesAspen Plus Getting Started Modeling Petroleum ProcessesAspen Plus Getting Started Customizing Unit Operation ModelsAspen Plus Getting Started Modeling Processes with SolidsAspen Plus Getting Started with Equation-Oriented Modeling

Online HelpAspen Plus Application ExamplesAspen Plus Reference Manual Series

Technical SupportFor additional information about AspenTech products and services,visit the AspenTech World Wide Web homepage on the Internetat:

http://www.aspentech.com/AspenTech customers with a valid license and softwaremaintenance agreement can register to access the OnlineTechnical Support Center at:

http://support.aspentech.com/This web support site allows you to:• Access current product documentation• Search for tech tips, solutions and frequently asked questions

(FAQs)• Search for and download application examples• Submit and track technical issues• Send suggestions• Report product defects• Review lists of known deficiencies and defectsRegistered users can also subscribe to our Technical Support e-Bulletins. These e-Bulletins are used to proactively alert users toimportant technical support information such as:

User Guide

Getting StartedGuides

Other Documentation

World Wide Web

Online TechnicalSupport Center

Aspen Plus 11.1 Summary File Toolkit Introduction •••• 1-3

• Technical advisories• Product updates and Service Pack announcementsCustomer support is also available by phone for customers with acurrent support contract for this product.

Support Centers Operating Hours

North America 8:00 – 20:00 Eastern TimeSouth America 9:00 – 17:00 Local timeEurope 8:30 – 18:00 Central European timeAsia and Pacific Region 9:00 – 17:30 Local time

SupportCenters

Phone Numbers

1-888-996-7100 Toll-free from U.S., Canada, Mexico1-281-584-4357 North America Support Center

NorthAmerica

(52) (5) 536-2809 Mexico Support Center(54) (11) 4361-7220 Argentina Support Center(55) (11) 5012-0321 Brazil Support Center(0800) 333-0125 Toll-free to U.S. from Argentina(000) (814) 550-4084 Toll-free to U.S. from Brazil

SouthAmerica

8001-2410 Toll-free to U.S. from Venezuela(32) (2) 701-95-55 European Support CenterCountry specific toll-free numbers:Belgium (0800) 40-687Denmark 8088-3652Finland (0) (800) 1-19127France (0805) 11-0054Ireland (1) (800) 930-024Netherlands (0800) 023-2511Norway (800) 13817Spain (900) 951846Sweden (0200) 895-284Switzerland (0800) 111-470

Europe

UK (0800) 376-7903(65) 395-39-00 SingaporeAsia and

PacificRegion

(81) (3) 3262-1743 Tokyo

Hours

Phone

1-4 •••• Introduction Aspen Plus 11.1 Summary File Toolkit

Support Centers Fax Numbers

North America 1-617-949-1724 (Cambridge, MA)1-281-584-1807 (Houston, TX)1-301-424-4647 (Rockville, MD)1-908-516-9550 (New Providence, NJ)1-425-492-2388 (Seattle, WA)

South America (54) (11) 4361-7220 (Argentina)(55) (11) 5012-4442 (Brazil)

Europe (32) (2) 701-94-45Asia and PacificRegion

(65) 395-39-50 (Singapore)(81) (3) 3262-1744 (Tokyo)

Support Centers E-mail

North America [email protected] (Engineering Suite)[email protected] (Mexico)

South America [email protected] (Argentina)[email protected] (Brazil)

Europe [email protected] (Engineering Suite)Asia and PacificRegion

[email protected] (Singapore)[email protected] (Tokyo)

Fax

E-mail

Aspen Plus 11.1 Summary File Toolkit Getting Started •••• 2-1

Getting Started

This chapter describes how to build an application program usingthe Aspen Plus Summary File Toolkit. It contains information on:• The summary file and toolkit• Initializing the toolkit• Determining data dimensions• Retrieving data for an object• Using the toolkit with a hierarchical Aspen Plus run• Linking toolkit subroutines into your module• Creating a toolkit application for Windows• Transferring the toolkit to another computer

The Summary File and ToolkitThe summary file is an ASCII file produced by Aspen Plus forevery simulation run. This file contains the summary of simulationresults, such as block results, stream values, tray profiles,heating/cooling curves, and property tables. The information in asummary file is also contained within the Aspen Plus backup file.Summary files are named according to the form runid.SUM.Backup files are named according to the form runid.BKP.The summary file toolkit is a set of Fortran subroutines thatretrieve results information from the Aspen Plus summary file andbackup file. (Use the backup file with results, in place of thesummary file, in procedures throughout this manual.)The subroutines are organized around the logical structure of thedata. You can retrieve selected results. Or you can retrieve all theresults of a simulation or simulation object (such as unit operationblocks or streams). The Fortran source code for the subroutines isprovided so that you can build applications on any computer.

2-2 •••• Getting Started Aspen Plus 11.1 Summary File Toolkit

The location of the Fortran source code is the toolkit directory ofthe Aspen Plus Simulation Engine installation. Initially, all theFortran source code files are packaged in a self-extracting ZIParchive named toolkit.exe.To use the summary file toolkit, an application program mustperform three steps:Initialize the toolkit for a summary file.Get the dimensions of the data to be retrieved.Retrieve the data.These three steps are described in the following sections.

Initializing the ToolkitYou must initialize the toolkit for a summary file before you canretrieve data. The initialization process consists of:1 Accessing the required files and setting up directories for fast

data access2 Defining the units of measurement for all values retrieved

from the toolkit3 Specifying a value to substitute for missing results

You need to include file definitions for the following files duringthe initialization process. The unit numbers for these files mustmatch those specified in the call to toolkit initialization routineTKINIT or TKINI2.

File Description

Summary file The summary fileProperties file A file defining the names of results within the summary

fileUnits file A file containing units conversion informationScratch file A temporary direct access file for fast access to

summary file results

To define the summary file, use the subroutine TKOPEN. SeeChapter 3 for more information.

Accessing theRequired Files

Defining the SummaryFile

Aspen Plus 11.1 Summary File Toolkit Getting Started •••• 2-3

Getting the Summary File NameBecause the summary file may be different each time the toolkitapplication is executed, some input to the program is required todetermine the summary file name. If the application program hasan existing method of passing information into the program, usethis method to pass the summary file name to the program.Otherwise, the three principal ways the program can get the filename are by:1 Prompting the user at the terminal2 Reading the file name from the command line3 Reading the file name from a filePrompting the user is the easiest method for most operatingsystems. Fortran READ and WRITE statements are used to get thefile name.

The properties file, RCPROPNU.DAT, and the units file,RCUNITS.DAT, are installed in the toolkit subdirectory of theAspen Plus Simulation Engine installation. The Engine directoryshould be set as the value of the %asptop% environment variable.

Example of Environment Variable for Windows

When running in an Aspen simulation engine window, the environment variableASPTOP points to the top level supplementary directory for Aspen Plus. TheTOOLKIT directory is a subdirectory of this directory. You can use the followingcode to expand the file specification:

CALL GETENV('ASPTOP', ASPTOP)DO 50 I = 80, 1, -1

IF (ASPTOP(I:I) .NE. ' ') GO TO 555055

CONTINUECONTINUERCPROP = ASPTOP(1:I) // '\TOOLKIT\RCPROPNU.DAT'RCUNIT = ASPTOP(1:I) // '\TOOLKIT\RCUNITS.DAT'

The direct access file is used to provide fast access to data in thesummary file after initialization. The units number you specify forthis file should not be used by the application program.

As part of the toolkit initialization process, you must specify a baseunits set in which the results will be returned. The base units set

Getting Property andUnits File Names

Scratch File UnitsNumber

Defining Units ofMeasurement

2-4 •••• Getting Started Aspen Plus 11.1 Summary File Toolkit

defines the units of measurement for each physical quantity (unitstype).The base units sets available are SI, ENG, MET, and OUT. Tocustomize a units set to change the output units of measurement forone or more physical quantities, or convert a result to another unitof measurement, use the subroutines described in Chapter 2. SeeChapter 10 for other conversion options.

If you make calls to the toolkit to retrieve results, and a requestedresult is missing, the toolkit returns a special value in place of theresult. As part of the toolkit initialization process, you specify thisvalue by assigning it to the argument RMISS in the call to routineTKINIT or TKINI2. Choose a value that will not be mistaken for areal result. A very large value (greater than 1E20) is recommended.

Determining the Data DimensionsThe toolkit data retrieval routines require you to know the datadimensions before a retrieval is done. With these dimensions inmind, you must allocate space inside your application program forthe data before retrieving it. Determining data dimensionsincludes:1 Querying the summary file for the existence of simulation

objects and data within an object2 Defining the size of the data for a simulation objectThe subroutine TKINFO returns the number of blocks, streams,property tables, and sensitivity tables in the summary file.Each type of simulation object has a subroutine to find the nextobject in sequence. These subroutines are:

Object Type Subroutine to Find Next Object

Blocks TKNBLKStreams TKNSTRProperty tables TKNPPTSensitivity tables TKNEXTEquipment item TKNEQPPressure relief TKNXPR

Each of these subroutines has a sequence number as an argument.The sequence number identifies the position of the object withinthe summary file. For example, a sequence number of five for

Specifying a Value forMissing Results

Aspen Plus 11.1 Summary File Toolkit Getting Started •••• 2-5

TKNBLK indicates the fifth unit operation block in the summaryfile. Except for sensitivity objects and pressure relief, thesubroutine also returns information about the type of object: theunit operation model type for a block, the type of stream(MATERIAL, HEAT, or WORK), or the type of property table.The data available for an object are organized by the type of data.For example, block data is organized into a standard results set,connectivity information, heating/cooling curve data, profile data,and property set profile data. Each type of data has a routine thatreturns the dimensions of the data. Chapters 2 through 7 describethe toolkit routines for determining the dimensions of data andretrieving it. If a type of data is not available for an object,dimension values of zero are returned.

2-6 •••• Getting Started Aspen Plus 11.1 Summary File Toolkit

Retrieving Data for an ObjectOnce the dimensions for data are known, you can retrieve the databy calling the appropriate routine. Each result returned is identifiedby a property name. Chapter 11 contains a list of property namesand their descriptions.In addition to property names, some results have qualifiers tofurther identify the data. For example, for an FSPLIT block, thesplit fractions for each outlet stream are returned. The stream ID ofthe outlet stream is returned as a qualifier for the result.You can use single subroutine calls to retrieve standard results forblocks, streams, heating/cooling curves, and pressure-temperatureenvelopes. Standard tray or reactor profiles are retrieved oneprofile at a time. You can identify property set results by theproperty set qualifiers:

Qualifier Description

PNAME Property name. See Chapter 11 for a description.SUBSID Substream IDPHASE Phase (VAPOR, LIQUID, LIQUID1, LIQUID2, TOTAL,

SOLID)COMPID Component IDWETDRY Wet/dry basis (WET or DRY) †

BASIS Unit basis for properties with multiple units ††

† Can be left unspecified.†† Valid values for the basis are MOLE, MASS and FLOW. MOLE and MASSapply to density (specifying mole density and mass density), entropy (specifyingmole entropy and mass entropy), and heat capacity (specifying mole heatcapacity and mass heat capacity). MOLE and FLOW apply to volume(specifying mole volume and volume flow). MOLE, MASS and FLOW apply toenthalpy (specifying mole enthalpy, mass enthalpy, and enthalpy flow).

Before calling a subroutine, make sure that all the qualifiers are setto the desired values or unset. If you do not unset a qualifier from aprevious value, unexpected results may be returned.All values with physical dimensions are returned in the units youspecify during the initialization process. The units label and theunits type are usually returned with the value. When the physicaldimensions of a property are always known, the units informationmay not be returned. You can call the utility routine TKLABL toreturn the units label for a value not returned. In addition, you canuse the utility routine TKCNVT to convert a value from defaultunits to user-specified units.

Aspen Plus 11.1 Summary File Toolkit Getting Started •••• 2-7

Sometimes the retrieved data values are two-dimensional. Forexample, the column profile routine TKPRO2 returns values forevery stage and component combination in a column. Thedimension for the results then appears as two dimensionsmultiplied together. This figure yields the total number of resultsreturned. It also shows the sequence of the results data in the array.The results array is ordered so that the first dimension can scrollbefore the second dimension. In the TKPRO2 example, the resultsare returned in RVALS, which is dimensioned as NCP*NSTAGE(the number of components * the number of stages). The valuesreturned in the RVALS array are ordered so that the results forevery component on the first stage are given first, followed by allthe results for every component on the second stage, and so on.

Using the Toolkit With a HierarchicalAspen Plus RunMost Aspen Plus objects, including hierarchies, can exist withinhierarchies. In such cases it is not sufficient to reference an objectby type and eight character ID. The object’s ID must contain thefull hierarchical path to the object, with each hierarchy nameseparated by a period (.). For example, if a run contains hierarchyH1, which contains hierarchy H2, which contains block B1, referto the block as H1.H2.B1.All toolkit subroutines that accept or return an object ID declarethe argument as CHARACTER *(*). When passing such anargument, set up the dimension large enough to hold thehierarchical ID. If referencing a non-hierarchical problem,declaring the ID arguments as CHARACTER*8 is sufficient.

Note: The length must be larger for hierarchical problems. Adeclaration of CHARACTER*128 is always sufficient.

The toolkit always returns IDs with full path name. For example,TKNBLK, which lists the blocks in a run, cycles through all blocksin all hierarchy levels, returning IDs with full path name.Block, stream, pressure relief, property table, and sensitivity IDsare hierarchical. Property name, substream, phase, and componentIDs are not.

Note: It is not possible to cycle through all blocks in a singlehierarchy level.

2-8 •••• Getting Started Aspen Plus 11.1 Summary File Toolkit

Linking Toolkit Subroutines into YourModuleAfter you write or modify your application program to call theappropriate toolkit subroutines to retrieve the data, you must buildan executable module, including the toolkit routines. The objectcode for the toolkit subroutines is stored in a dynamic link libraryfor Windows, which is delivered with Aspen Plus.

The library is named zetoolkit.dll and can be found in the toolkitsubdirectory of the Aspen Plus Simulation Engine installation.To link to this library, include %asptop%\LIB\zetoolkit.lib in thelinker directive, where %asptop% represents the Engineinstallation directory.

Aspen Plus 11.1 Summary File Toolkit Getting Started •••• 2-9

Creating a Toolkit Application forWindowsThe source code, in the form of a self-extracting executable, anddynamic link library (DLL) for the summary file toolkit are locatedin the toolkit directory of the Aspen Plus Simulation Engineinstallation. If you want to build a Windows summary file toolkitapplication and you do not have a license for Aspen Plus onWindows, the toolkit files are available separately on a 3.5"diskette. For ordering information, contact the AspenTech Hotline.The files on the diskette are not compressed, and can be copied toany directory on your Windows NT, 95, 98, or 2000 PC.

The Windows version of the summary file toolkit consists of twofiles:

File Name Description

zetoolkit.dll The summary file toolkit dynamic-link library.zetoolkit.lib Import library. This file contains the external references

to the summary file toolkit routines in zetoolkit.dll.

The DLL and LIB are compiled and linked with Digital VisualFortran 5.0.If you are using the summary file toolkit as part of a fullinstallation of Aspen Plus, you can compile and link toolkitapplications with the Fortran compiler for your Operating System.Make sure you are set up for running Aspen Plus. Aspen Plusprovides procedures to help use the Aspen Plus Fortran utilities.The following table summarizes these procedures:

To do this Enter these commands

Compile a Fortran routine ASPCOMP appnameLink an application executable link @appname.optRun a previously linked executable appname.exe

About the WindowsVersion

2-10 •••• Getting Started Aspen Plus 11.1 Summary File Toolkit

Where:

appname = The file name of the main Fortran application. Donot include the file extension when specifying thefile name. ASPCOMP will accept Fortran fileswith the extension .for.

appname.opt = Text file containing the linker directivecommands. For more information, see thefollowing section, Linker Directive Commands forWindows.

Linker Directive Commands forWindowsThe linker directive file contains a set of commands that controlthe generation of the linked executable. Any object files orlibraries you want to be included in the linked executable must belisted in the linker directive file.The standard set of commands required to link a toolkit applicationare shown for a toolkit application named tkexampl.

Example of Linker Directive File-entry:mainCRTStartupmsvcrt.lib-nodefaultlib:libc.libdfordll.lib-nodefaultlib:dfor.libc:\Engine\toolkit\zetoolkit.libtkexample.obj-out:tkexample.exe

Substitute c:\Engine with the appropriate drive and directory location where theAspen Plus Simulation Engine is installed. Replace tkexample with the name ofyour application. Add any additional object files and libraries you need to thisdirective file.

After creating the linker directive file for your application, you canuse the link and run commands to generate and run yourapplication's executable program.

Aspen Plus 11.1 Summary File Toolkit Getting Started •••• 2-11

Calling Summary File ToolkitRoutinesThe files are compiled so that the summary file toolkit routines usethe default calling and naming conventions for the Fortrancompiler. These are similar to the stdcall convention, except:• All routine names are in uppercase (Windows 95 and Windows

NT Intel only)• All arguments are passed by reference• There is a hidden string length argument when character strings

are passed.Applications calling the DLL should use this convention. Pleasesee your compiler documentation about calling Fortran routinesand hidden string length arguments.Fortran applications can call the routines in the Summary FileToolkit without any code modifications. If you want to call theSummary File Toolkit from another language, you will have tomodify the code to work with the Fortran conventions adopted. SeeUsing C to Call Routines, this chapter.

You must be careful with file input and output when using theSummary File Toolkit. You must observe the following practices:• Open and close the summary file with TKOPEN and TKCLFL.• Open and close the log file optionally used in TKINI2, with

TKOPEN and TKCLFL.• Close the toolkit with TKCLOS, at the end of each run.• Close the summary file and the log file with TKCLFL, at the

end of each run.• Do not use TKOPEN and TKCLFL for opening and closing the

files your application reads from or writes to.

Use the Fortran default naming and calling conventions for calls tothe summary file toolkit shared library, when compiling code. Youdo not have to carry out any special steps to call the summary filetoolkit routines.When linking the application, make sure a reference to thezetoolkit shared library is included in the list of libraries, and thatits pathname is included in the list of library directories.You must write your code and any setup procedures so that thezetoolkit shared library is in your run time path.

Opening and ClosingFiles Using theSummary File Toolkit

Using Fortran toCall Routines

2-12 •••• Getting Started Aspen Plus 11.1 Summary File Toolkit

When using C to call routines, you must adjust the naming andcalling conventions. A full discussion of mixed languageprogramming is beyond the scope of this manual, but a briefoutline of important points follows.You must:• Make sure the DLL routines are called using stdcall• Make sure all arguments are passed by reference (pointers)• Include the hidden string length arguments• Declare the Summary File Toolkit routines called in prototypes• Allow for the C string null-terminatorSee the documentation of your compiler for more details.

Sample Prototypes for TKINIT, TKINFO and TKBIDS forWindows

The following routines are declared as stdcall, and all character strings arefollowed by their lengths. The unsigned integer is passed by value.

The calling routine will add null characters to the strings returned. It will alsomake sure null characters are not included in any strings passed to the Fortran.

extern void __stdcallTKINIT

(char* units, unsigned int len4,int *idirac, int* iunit, int *ipropn,char* rcprop, unsigned int len80,int* iunits, char* rcunits,unsigned int len80, double* rmiss,int *ierr);

extern void __stdcallTKINFO

(char*versn, unsigned int len20,char* runid, unsigned int len8,char* date, unsigned int len80,char* infile, unsigned int len80,int* isstat, int* istatf, int* nblock,int* nstrm, int* ntable, int * nsens);

extern void __stdcallTKBIDS

(int* nblock, char blkids[200] [8],unsigned int len8, char blktypes [200][12], unsigned int len12, int* ierr);

Using C to CallRoutines

Aspen Plus 11.1 Summary File Toolkit General Subroutines •••• 3-1

General Subroutines

This chapter describes the purpose and use of subroutines in theAspen Plus Summary File Toolkit. Use the subroutines describedin this chapter for:• Initializing the summary file toolkit• Retrieving run information• Retrieving flowsheet balance results• Setting and changing units of measurement• Retrieving component information• Retrieving sensitivity results

Initializing the Summary File ToolkitBefore you can retrieve any results from a summary file, you mustcall subroutine TKINIT or TKINI2 to initialize the summary filetoolkit.TKINIT assigns Fortran unit numbers and unit names for files usedby the toolkit. See Initializing the Toolkit, Chapter 1, forinformation on identifying the necessary files.The scratch file is a direct access file used by the toolkit to storeintermediate data. You must supply a Fortran unit number for thescratch file.To open the summary file and connect it to a unit number, you can:• Use a Fortran OPEN statement in your program.• Call TKOPEN routine (see Opening and Closing Files, this

chapter), if using the Windows DLL.The property number file and the unit definition file are deliveredwith Aspen Plus. The file names you specify to call TKINITdepend on the computer and operating system you are using (seeGetting Property and Units File Names, Chapter 2).

3-2 •••• General Subroutines Aspen Plus 11.1 Summary File Toolkit

TKINIT sets the default units set for all results data to the value ofUNISET. This can be one of four values: SI, ENG, MET, or OUT.The first three values correspond to the Aspen Plus units sets withthese names. OUT can be used to retrieve the results from thesummary file without any UOM conversion. The data is retrievedin the same units as the Aspen Plus out units for the run.

Calling Sequence for TKINITCALL TKINIT (UNISET, IDIRAC, ISUMMF, IPROPN,RCPROP, IUNITS, RCUNIT, RMISS, IERR)

Argument List Descriptions for TKINITVariable I/O † Type Dimension Description

UNISET I CHARACTER*4 — Units set for retrieved values (SI,ENG, MET, or OUT)

IDIRAC I INTEGER — Fortran unit number for scratchfile

ISUMMF I INTEGER — Fortran unit number for summaryfile

IPROPN I INTEGER — Fortran unit number for propertynumbers file

RCPROP I CHARACTER*80 — File name for property numbersfile

IUNITS I INTEGER — Fortran unit number for unitsdefinition file

RCUNIT I CHARACTER*80 — File name for units definition fileRMISS I REAL*8 — Real value flag for missing valuesIERR O INTEGER — Error flag (0=No error)† I = Input to subroutineO = Output from subroutine

If you initialize the toolkit with TKINIT, Aspen Plus writes errorsor warnings from the toolkit run to the screen. TKINI2 works inthe same way as TKINIT, except that it allows you to specify aFortran unit number for error and warning messages. This is usefulfor applications where messages should not be written directly tothe screen. Like the summary file, this file should already beopened before calling TKINI2. If you specify a negative unitnumber for the error and warning messages, they are turned off.

Aspen Plus 11.1 Summary File Toolkit General Subroutines •••• 3-3

Calling Sequence for TKINI2CALL TKINI2(UNISET, IDIRAC, ISUMMF, IPROPN,RCPROP, IUNITS, RCUNIT, RMISS , IERR, ILOG)

Argument List Descriptions for TKINI2Variable I/O † Type Dimension Description

UNISET I CHARACTER*4 — Units set for retrieved values(SI, ENG, MET or OUT)

IDIRAC I INTEGER — Fortran unit number forscratch file

ISUMMF I INTEGER — Fortran unit number forsummary file

IPROPN I INTEGER — Fortran unit number forproperty numbers file

RCPROP I CHARACTER*80 — File name for propertynumbers file

IUNITS I INTEGER — Fortran unit number for unitsdefinition file

RCUNIT I CHARACTER*80 — File name for units definitionfile

RMISS I REAL*8 — Real value flag for missingvalues

IERR O INTEGER — Error flag (0=No error)ILOG I INTEGER — Fortran Unit number for log

file. Negative for nomessages.

† I = Input to subroutineO = Output from subroutine

Closing the Summary File ToolkitCall subroutine TKCLOS to close a summary file toolkit run.TKCLOS closes files opened by TKINIT or TKINI2, so theargument list should use the corresponding values passed toTKINIT or TKINI2. The summary file is not closed by thisroutine, but is instead rewound to its first record. Use TKCLFL toclose it.

3-4 •••• General Subroutines Aspen Plus 11.1 Summary File Toolkit

Calling Sequence for TKCLOSCALL TKCLOS( ISUMMF, IDIRAC, IPROPN, IUNITS )

Argument List Descriptions for TKCLOSVariable I/O † Type Dimension Description

ISUMMF I INTEGER — Fortran unit number forsummary file

IDIRAC I INTEGER — Fortran unit number for scratchfile

IPROPN I INTEGER — Fortran unit number forproperty numbers file

IUNITS I INTEGER — Fortran unit number for unitsdefinition file

† I = Input to subroutineO = Output from subroutine

Opening and Closing FilesTwo routines are provided to open and close files with a specifiedFortran unit number. If you are using a DLL version of thesummary file toolkit, you must use these routines to open and closethe summary file, and any log file used by TKINI2. Unless you doso, the summary file toolkit DLL will not recognize the Fortranunit numbers you pass it for these files. When using the DLL, youshould not call these routines to open and close files your codeaccesses.Call subroutine TKOPEN to open the file with the specifiedFortran unit number.

Calling Sequence for TKOPENCALL TKOPEN(IUNIT, FILNAM, ACCESS, FORM, IRECL,STATUS, MODE, IERR)

Argument List Descriptions for TKOPENVariable I/O † Type Dimension Description

IUNIT I INTEGER — Unit number of the filebeing opened

FILNAM I CHARACTER*80 — Name of file to openACCESS I CHARACTER*16 — File access

(SEQUENTIAL, DIRECT)FORM I CHARACTER*16 — I/O format (FORMATTED,

UNFORMATTED)IRECL I INTEGER — Record lengthSTATUS I CHARACTER*16 — File status (SCRATCH,

OLD, NEW, UNKNOWN)

Aspen Plus 11.1 Summary File Toolkit General Subroutines •••• 3-5

Variable I/O † Type Dimension Description

MODE I CHARACTER*16 — Open mode (READ,WRITE)

IERR O INTEGER — Error flag(0=No error, 1=Invalid argument, >0= IOSTAT error)

† I = Input to subroutineO = Output from subroutine

Call subroutine TKCLFL to close the file with the specifiedFortran unit number.

Calling Sequence for TKCLFLCALL TKCLFL( IUNIT, IERR )

Argument List Descriptions for TKCLFLVariable I/O † Type Dimension Description

IUNIT I INTEGER — Unit number of the file beingclosed

IERR O INTEGER — Error flag (0=No error)† I = Input to subroutine

O = Output from subroutine

Retrieving Run InformationUse the subroutines in this section to retrieve general informationabout the run.• Call TKINFO to obtain standard information about a run.• Call TKTITL to obtain the run title.• Call TKACCT to obtain run accounting information.

Call subroutine TKINFO to retrieve the following standardinformation about a run:• Aspen Plus release name• Run ID of the Aspen Plus run• Date of the run• Input file name• Input translator status• Simulation program status• Number of simulation objects (blocks, streams, property tables,

sensitivity tables)

Standard RunInformation

3-6 •••• General Subroutines Aspen Plus 11.1 Summary File Toolkit

Calling Sequence for TKINFOCALL TKINFO (VERSN, RUNID, DATE, INFILE, ISSTAT,ISTAT, NBLOCK, NSTRM, NTABLE, NSENS)

Argument List Descriptions for TKINFOVariable I/O † Type Dimension Description

VERSN O CHARACTER*20 — Aspen Plus release nameRUNID O CHARACTER*8 — Aspen Plus run IDDATE O CHARACTER*80 — Date of Aspen Plus runINFILE O CHARACTER*80 — Aspen Plus input file nameISSTAT O INTEGER — Input translator completion codeISTATF O INTEGER 6 Simulation status flags for each

element, the values are:0 = Completed without errors,1 = Completed with errors,2 = None in this simulation,The elements represent:ISTATF(1): Block status,(2): Convergence status,(3): Sensitivity status,(4): Case study status,(5): Stream calculation status,(6): Fortran and transfer status

NBLOCK O INTEGER — Number of blocksNSTRM O INTEGER — Number of streamsNTABLE O INTEGER — Number of property tablesNSENS O INTEGER — Number of sensitivity tables† I = Input to subroutine

O = Output from subroutine

Call subroutine TKTITL to retrieve the run title.

Calling Sequence for TKTITLCALL TKINFO (TITLE)

Argument List Descriptions for TKTITLVariable I/O † Type Dimension Description

TITLE O CHARACTER*64 — Run title† I = Input to subroutine

O = Output from subroutine

Run Titles

Aspen Plus 11.1 Summary File Toolkit General Subroutines •••• 3-7

Call subroutine TKACCT to obtain accounting information for arun. Accounting information is only available if requested in theAspen Plus input.

Calling Sequence for TKACCTCALL TKACCT (ACCNT, PROJID, PRNAME, USER, IERR)

Argument List Descriptions for TKACCTVariable I/O † Type Dimension Description

ACCNT O CHARACTER*8 — Account numberPROJID O CHARACTER*8 — Project IDPRNAME O CHARACTER*32 — Project nameUSER O CHARACTER*20 — User nameIERR O INTEGER — Error flag (0=No error)† I = Input to subroutine

O = Output from subroutine

Retrieving Flowsheet BalanceResultsCall subroutine TKFLWB to retrieve the absolute and relativedifferences for:• Total mole balance• Total mass balance• Enthalpy balance• Mole balance for each conventional component• Mass balance for each nonconventional component

Calling Sequence for TKFLWBCALL TKFLWB (ABSMOL, RELMOL, ABSMAS, RELMAS,ABSENT, RELENT, NCC, ABSCON, RELCON, NNCC, ABSNC,RELNC, IERR)

Argument List Descriptions for TKFLWBVariable I/O † Type Dimension Description

ABSMOL O REAL*8 — Absolute mole balance difference(UNITS=MOLE-FLOW)

RELMOL O REAL*8 — Relative mole balance differenceABSMAS O REAL*8 — Absolute mass balance difference

(UNITS=MASS-FLOW)RELMAS O REAL*8 — Relative mass balance differenceABSENT O REAL*8 — Absolute enthalpy balance difference

(UNITS=ENTHALPY-FLOW)

AccountingInformation

3-8 •••• General Subroutines Aspen Plus 11.1 Summary File Toolkit

Variable I/O † Type Dimension Description

RELENT O REAL*8 — Relative enthalpy balance differenceNCC I INTEGER — Number of conventional componentsABSCON O REAL*8 NCC Absolute mole balance difference for

each conventional component(UNITS=MOLE-FLOW)

RELCON O REAL*8 NCC Relative mole balance for eachconventional component

NNCC I INTEGER — Number of nonconventionalcomponents

ABSNC O REAL*8 NNCC Absolute mass balance difference foreach nonconventional component(UNITS=MASS-FLOW)

RELNC O REAL*8 NNCC Relative mass balance difference foreach nonconventional component

IERR O INTEGER — Error flag (0=No error)† I = Input to subroutine

O = Output from subroutine

Units ConversionUse the subroutines in this section to:• Change the units set for results• Convert units for individual results• Find units labels for results

Values retrieved from the summary file are converted to the currentunits set. The variable SETID takes the same values as UNISETdoes in TKINIT and TKINI2. The units set is initially defined in thecall to subroutine TKINIT or TKINI2. You can change the units setat any point in your program, by calling subroutine TKUNIT.Use TKUNIT to define a new base units set and any units' optionsthat should override the units' options in the base set.

Calling Sequence for TKUNITCALL TKUNIT (SETID, NTYPES, TYPES, LABELS, IERR)

Argument List Descriptions for TKUNITVariable I/O † Type Dimension Description

SETID I CHARACTER*4 — Base units set(SI, ENG, MET, or OUT)

NTYPES I INTEGER — Number of units types to changefrom the base set

Changing Units Sets

Aspen Plus 11.1 Summary File Toolkit General Subroutines •••• 3-9

Variable I/O † Type Dimension Description

TYPES I CHARACTER*12 NTYPES List of units' types to changefrom the base set. See Chapter 10for a list of valid units' types.

LABELS I CHARACTER*16 NTYPES List of units labels for the unitstypes to change from the baseset. See Chapter 10 for a list ofvalid units' labels.

IERR O INTEGER — Error flag (0=No error)† I = Input to subroutine

O = Output from subroutine

Call subroutine TKCNVT to perform units conversion on a result oran array of results. TKCNVT converts values from the current unitsset to units specified by a unit's label. TKCNVT will not convert aresult if the current units set is OUT units. (There is no such thing asa current unit for a particular units type with OUT units.)

Calling Sequence for TKCNVTCALL TKCNVT (TYPE, LABEL, NVAL, RVALI, RVALO)

Argument List Descriptions for TKCNVTVariable I/O † Type Dimension Description

TYPE I CHARACTER*12 — Units type. Valid units' typesare shown in Chapter 10.

LABEL I CHARACTER*16 — Units label for output. SeeChapter 10 for a list of validunits' labels.

NVAL I INTEGER — Number of values to convertRVALI I REAL*8 NVAL Array of values to be

converted. These values areassumed to be in the currentunits set.

RVALO O REAL*8 NVAL Array of converted values† I = Input to subroutine

O = Output from subroutine

Converting Units forReal Numbers

3-10 •••• General Subroutines Aspen Plus 11.1 Summary File Toolkit

Call subroutine TKLABL to determine the units' labels for a list ofunits' types in the current units set. TKLABL will not retrieve a labelfor a type if the current units set is OUT units. (There is no suchthing as a current unit for a particular units type with OUT units.)

Calling Sequence for TKLABLCALL TKLABL (NTYPES, TYPES, LABELS)

Argument List Descriptions for TKLABLVariable I/O † Type Dimension Description

NTYPES I INTEGER — Number of units typesTYPES I CHARACTER*12 NTYPES Units types. See Chapter 10

for a list of valid units' types.LABELS O CHARACTER*16 NTYPES Units labels† I = Input to subroutine

O = Output from subroutine

Component Information RetrievalUse the subroutines in this section to retrieve information about thecomponents in the simulation:• TKCOMP gets the number of components in the simulation.• TKCIDS gets the list of component IDs.• TKALIS gets lists of conventional components and their

formulas (alias names).• TKCPRP retrieves component properties, such as molecular

weight, boiling point, and standard volume.

Call subroutine TKCOMP to determine the number of componentsin a simulation. TKCOMP returns the number of both conventionaland nonconventional components.

Calling Sequence for TKCOMPCALL TKCOMP (NCC, NNCC)

Argument List Descriptions for TKCOMPVariable I/O † Type Dimension Description

NCC O INTEGER — Number of conventional componentsNNCC O INTEGER — Number of nonconventional

components† I = Input to subroutine

O = Output from subroutine

Determining UnitsLabels

Number ofComponents

Aspen Plus 11.1 Summary File Toolkit General Subroutines •••• 3-11

Call subroutine TKCIDS to retrieve the component IDs forconventional and nonconventional components.

Calling Sequence for TKCIDSCALL TKCIDS (NCC, NNCC, COMPID, COMPNC)

Argument List Descriptions for TKCIDSVariable I/O † Type Dimension Description

NCC I INTEGER — Number of conventionalcomponents

NNCC I INTEGER — Number of nonconventionalcomponents

COMPID O CHARACTER*8 NCC Component IDs for conventionalcomponents

COMPNC O CHARACTER*8 NNCC Component IDs fornonconventional components

† I = Input to subroutineO = Output from subroutine

Call subroutine TKALIS to retrieve conventional component IDsand their formulas (aliases).

Calling Sequence for TKALISCALL TKALIS (NCC, COMPID, ALIAS, IERR)

Argument List Descriptions for TKALISVariable I/O † Type Dimension Description

NCC I INTEGER — Number of conventionalcomponents

COMPID O CHARACTER*8 NCC Conventional component IDsALIAS O CHARACTER*12 NCC Alias corresponding to

component IDsIERR O INTEGER — Error flag (0=No error)† I = Input to subroutine

O = Output from subroutine

Component IDs

Component AliasNames

3-12 •••• General Subroutines Aspen Plus 11.1 Summary File Toolkit

Call subroutine TKCPRP to retrieve component properties forconventional components. The properties that you can retrieve aremolecular weight, boiling point, and standard volume.

Calling Sequence for TKCPRPCALL TKCPRP (PROP, NCC, RVALS, LABEL)

Argument List Descriptions for TKCPRPVariable I/O † Type Dimension Description

PROP I CHARACTER*8 — Property name (MW, TB, orVSTD)

NCC I INTEGER — Number of componentsRVALS O REAL*8 NCC Property values (units are

TEMPERATURE for TB andMOLE-VOLUME for VSTD)

LABEL O CHARACTER*16 — Units label† I = Input to subroutine

O = Output from subroutine

Sensitivity Block ResultsYou can retrieve sensitivity table results from the summary file,using the following three-step process:1 Call TKNEXT to identify the next sensitivity block.2 Call TKNSEN to retrieve the number of points and the

number of columns in the table.3 Call TKSENS to retrieve the values for the table and the

headers for the columns.

Call subroutine TKNEXT to find the name of the next sensitivityblock.To find the block ID of the first sensitivity block, set IOFF to 1. Tofind the name of the second block, set IOFF to 2, and so on.

Calling Sequence for TKNEXTCALL TKNEXT (TYPE, IOFF, ID1, ID2, IERR)

Argument List Descriptions for TKNEXTVariable I/O † Type Dimension Description

TYPE I CHARACTER*12 — Object type (set to SENSITIVITYfor sensitivity blocks)

IOFF I INTEGER — Sequence number

ComponentProperties

Identifying SensitivityBlocks

Aspen Plus 11.1 Summary File Toolkit General Subroutines •••• 3-13

Variable I/O † Type Dimension Description

ID1 O CHARACTER*(*) — First ID of the object. Forsensitivity blocks, it is the blockID. Returns complete hierarchyspecification.

ID2 O CHARACTER*12 — Second ID of the model name, forthe object. For sensitivity blocks,it is blank.

IERR O INTEGER — Error flag (0=No error)† I = Input to subroutine

O = Output from subroutine

Call subroutine TKNSEN to determine the number of points andnumber of columns in the sensitivity table.

Calling Sequence for TKNSENCALL TKNSEN(SENSID, NPOINT, NCOL, IERR)

Argument List Descriptions for TKNSENVariable I/O † Type Dimension Description

SENSID I CHARACTER*(*) — Sensitivity block IDNPOINT O INTEGER — Number of points in tableNCOL O INTEGER — Number of columns in

tableIERR O INTEGER — Error flag (0=No error)† I = Input to subroutine

O = Output from subroutine

DeterminingSensitivityDimensions

3-14 •••• General Subroutines Aspen Plus 11.1 Summary File Toolkit

Call subroutine TKSENS to retrieve the results for a sensitivitytable. The columns are identified by the variable HEADER. Theactual argument to RVALS should be declared as a one-dimensionalarray of length, equal to or greater than (NPOINT * NCOL). Theresults in each column are stored consecutively.

Calling Sequence for TKSENSCALL TKSENS(SENSID, NPOINT, NCOL, HEADER, RVALS,IERFLG, IERR)

Argument List Descriptions for TKSENSVariable I/O † Type Dimension Description

SENSID I CHARACTER*(*) — Sensitivity block ID(Full hierarchical path)

NPOINT I INTEGER — Number of points in tableNCOL I INTEGER — Number of columns in tableHEADER O CHARACTER*8 6, NCOL Table header of each table

columnRVALS O REAL*8 NPOINT*

NCOLResults for sensitivity table

IERFLG O INTEGER NPOINT Error flag for each row of table(0=No error)

IERR O INTEGER — Error flag (0=No error)† I = Input to subroutine

O = Output from subroutine

Retrieving SensitivityResults

Aspen Plus 11.1 Summary File Toolkit Block Result Subroutines •••• 4-1

Block Result Subroutines

This chapter describes the use of block result retrieval subroutinesin the summary file toolkit. Use the subroutines described in thischapter for:• Block identification, connectivity, and results• Compressor results• Heat exchanger results• Column results• Tray reports and tray/packing sizing and rating• Reactor results and property reports• Pipeline results• Block vapor-liquid equilibrium (VLE) results• Heating/cooling curves

4-2 •••• Block Result Subroutines Aspen Plus 11.1 Summary File Toolkit

Block IdentificationThe following subroutines are used to identify blocks in thesummary file:• TKBIDS returns a list of blocks in the summary file.• TKNBLK retrieves the next block ID in sequence.Both routines return the model type for each block.Call subroutine TKBIDS to get the list of blocks and model types.

Calling Sequence for TKBIDSCALL TKBIDS (NBLOCK, BLKID, BLKTYP, IERR)

Argument List Descriptions for TKBIDSVariable I/O † Type Dimension Description

NBLOCK I INTEGER — Number of blocks. You canfind the value of NBLOCK bycalling TKINFO.

BLKID O CHARACTER*(*) NBLOCK Block ID(Full hierarchical path)

BLKTYP O CHARACTER*12 NBLOCK Model typeIERR O INTEGER — Error flag (0=No error)† I = Input to subroutine

O = Output from subroutine

Call subroutine TKNBLK to find the name of the next unitoperation block.To find the block ID of the first block, set IBLOCK to 1. To findthe name of the second block, set IBLOCK to 2, and so on.

Calling Sequence for TKNBLKCALL TKNBLK (IBLOCK, BLKID, BLKTYP, IERR)

Argument List Descriptions for TKNBLKVariable I/O † Type Dimension Description

IBLOCK I INTEGER — Block numberBLKID O CHARACTER*(*) — Block IDBLKTYP O CHARACTER*12 — Model typeIERR O INTEGER — Error flag

(0=No error)† I = Input to subroutine

O = Output from subroutine

Block IDs

Next Block

Aspen Plus 11.1 Summary File Toolkit Block Result Subroutines •••• 4-3

Block Connectivity InformationUse the subroutines in this section to retrieve the inlet and outletstream connectivity for a block. Retrieving the inlet and outletstreams of a block is a two-step process:1 Call subroutine TKCNTN to find the number of inlet and

outlet streams.2 Call subroutine TKCNCT to retrieve the list of inlet and

outlet stream names.Some blocks have additional connectivity information, such asstage number and column number. For these blocks you can obtainthe additional information by calling TKPORT.

Call subroutine TKCNTN to determine the number of inlet streamsand outlet streams for a particular block.

Calling Sequence for TKCNTNCALL TKCNTN (BLKID, NIN, NOUT, IERR)

Argument List Descriptions for TKCNTNVariable I/O † Type Dimension Description

BLKID I CHARACTER*(*) — Block IDNIN O INTEGER — Number of inlet streamsNOUT O INTEGER — Number of outlet

streamsIERR O INTEGER — Error flag

(0=No error)† I = Input to subroutine

O = Output from subroutine

Call subroutine TKCNCT to retrieve the names of the inlet andoutlet streams for a block, along with the stream types(MATERIAL, HEAT, or WORK).

Calling Sequence for TKCNCTCALL TKCNCT (BLKID, NIN, NOUT, BLKIN, TYPIN,

BLKOUT, TYPOUT, IERR)

Argument List Descriptions for TKCNCTVariable I/O † Type Dimension Description

BLKID I CHARACTER*(*) — Block IDNIN I INTEGER — Number of inlet streamsNOUT I INTEGER — Number of outlet streams

Number of Inlet andOutlet Streams

Stream Names andTypes

4-4 •••• Block Result Subroutines Aspen Plus 11.1 Summary File Toolkit

Variable I/O † Type Dimension Description

BLKIN O CHARACTER*(*) NIN Inlet stream IDsTYPIN O CHARACTER*8 NIN Stream type of inlet streams

(MATERIAL, HEAT, orWORK)

BLKOUT O CHARACTER*(*) NOUT Outlet stream IDsTYPOUT O CHARACTER*8 NOUT Stream type of outlet

streams (MATERIAL,HEAT, or WORK)

IERR O INTEGER — Error flag (0=No error)† I = Input to subroutine

O = Output from subroutine

Call subroutine TKPORT to obtain additional port information oninlet and outlet streams for a block. The additional informationincludes the port name (for example, F indicating a feed port) andadditional identifiers, such as column number and stage number.Only the blocks with the model types shown in Table 3.1 need thissubroutine. The outlet types for the other blocks are implicit in theorder that the streams are returned by TKCNT. For example, vaporstreams are returned before liquid streams.

Calling Sequence for TKPORTCALL TKPORT (BLKID, NIN, NOUT, INPORT, IDIN1,

IDIN2, IOPORT, IDOUT1, IDOUT2,IERR)

Argument List Descriptions for TKPORTVariable I/O † Type Dimension Description

BLKID I CHARACTER*(*) — Block IDNIN I INTEGER — Number of inlet streamsNOUT I INTEGER — Number of outlet streamsINPORT O CHARACTER*4 NIN Inlet port namesIDIN1 O INTEGER NIN ID1 for inlet streamsIDIN2 O INTEGER NIN ID2 for inlet streamsIOPORT O CHARACTER*4 NOUT Outlet port namesIDOUT1 O INTEGER NOUT ID1 for outlet streamsIDOUT2 O INTEGER NOUT ID2 for outlet streamsIERR O INTEGER — Error flag:

0 = No error1 = Block ID not found2 = Block has no portinformation

† I = Input to subroutineO = Output from subroutine

Additional PortInformation

Aspen Plus 11.1 Summary File Toolkit Block Result Subroutines •••• 4-5

Model Type Port Name Description ID1 ID2

Extract TFBFSFTPBPSP

Top feedBottom feedSide feedTop productBottom productSide product

Stagenumber

HeatX HFCFHPCPHWDCWD

Hot feedCold feedHot productCold productHot water decantCold water decant

— —

Mcompr S1FIFWSHSFLSLKWDWSHS

Stage1 feedStage feedWork feedHeat feedProductLiquid knockoutWater drawWork outHeat out

Stagenumber

MheatX HFCFHPCPHWDCWD

Hot feedCold feedHot productCold productHot water decantCold water decant

Streamnumber

MultiFrac FHSVDLDRSPCWDHS

FeedHeat feedVapor distillateLiquid distillateResidueSide productWater distillateHeat product

Columnnumber

Stagenumber

Port InformationReturned by TKPORT

4-6 •••• Block Result Subroutines Aspen Plus 11.1 Summary File Toolkit

Model Type Port Name Description ID1 ID2

PetroFrac MFSFMHFSHFPHFVDLDBSPCWDSBPSCHSRHSMHPSHPPHP

Main column feedStripper steam feedMain column heat feedStripper heat feedPumparound heat feedMain column vapor distillateMain column liquid distillateMain column bottoms productMain column side productMain column condenser water decantStripper bottom productPseudo streamCondenser heat streamReboiler heat streamMain column heat productStripper heat productPumparound heat product

Columnnumber †

Stagenumber

RadFrac FHSVDLDRSPWDCHSRHS

FeedHeat feedVapor distillateLiquid distillateResidueSide productWater distillateCondenser heatReboiler heat

Stagenumber

RateFrac FHSVDLDRSPCWDHS

FeedHeat feedVapor distillateLiquid distillateResidueSide productWater distillateHeat product

Columnnumber

Sectionnumber

SCFrac FSFDBSP

FeedSteam feedDistillateBottomsSide product

— —

† The PetroFrac column number for the main column is one. The strippersare numbered sequentially, starting with two.

Aspen Plus 11.1 Summary File Toolkit Block Result Subroutines •••• 4-7

Standard Block ResultsAll unit operations have standard scalar block results. For example,Flash2 results include the outlet temperature and pressure, thevapor fraction, and the heat duty.You can retrieve standard scalar results using a two-step process:1 Call subroutine TKNRES to determine the dimensions of the

results.2 Call subroutine TKBRES to retrieve the results.

Call subroutine TKNRES to determine the dimensions of thestandard results for a block. TKNRES returns the number of resultsand the maximum number of qualifiers for results. You can usethis information to dimension arrays for calling subroutineTKBRES, which retrieves the results.

Calling Sequence for TKNRESCALL TKNRES (BLKID, NRES, NQUAL, IERR)

Argument List Descriptions for TKNRESVariable I/O † Type Dimension Description

BLKID I CHARACTER*(*) — Block IDNRES O INTEGER — Number of resultsNQUAL O INTEGER — Maximum number of

qualifiers for a result ††

IERR O INTEGER — Error flag(0=No error)

† I = Input to subroutineO = Output from subroutine

†† Some results have qualifiers needed to identify the result, such as the streamID or substream ID. NQUAL is the maximum number of qualifiers for the resultsof a block.

Dimensions ofStandard ScalarResults

4-8 •••• Block Result Subroutines Aspen Plus 11.1 Summary File Toolkit

Call subroutine TKBRES to retrieve the standard scalar results of ablock. Treat the QUALS array as a one-dimensional array, with allthe values for each qualifier type stored consecutively.

Calling Sequence for TKBRESCALL TKBRES (BLKID, NRES, NQUAL, PNAMES, QUALS,

ITYPE, IVALS, CVALS, RVALS, TYPES,LABELS)

Argument List Descriptions for TKBRESVariable I/O † Type Dimension Description

BLKID I CHARACTER*(*) — Block IDNRES I INTEGER — Number of resultsNQUAL I INTEGER — Maximum number of

qualifiers ††

PNAMES O CHARACTER*12 NRES Property name. SeeChapter 11 for adescription.

QUALS O CHARACTER*8 NRES*NQUAL

Qualifiers ††

ITYPE O INTEGER NRES Data type of results(1=Integer, 2=Real, 3=Character) †††

IVALS O INTEGER NRES Integer results †††

CVALS O CHARACTER*8 NRES Character results †††

RVALS O REAL*8 NRES Real results †††

TYPES O CHARACTER*12 NRES Units typesLABELS O CHARACTER*16 NRES Units labels† I = Input to subroutine

O = Output from subroutine†† Some results have qualifiers needed to identify the result, such as the streamID or substream ID. NQUAL is the maximum number of qualifiers for the resultsof a block.††† For each result, the value in ITYPE specifies which array contains theresult (IVALS, CVALS or RVALS). For example, if ITYPE(4) is 2, then IVALS(4)is 0, CVALS(4) is blank and RVALS(4) contains the result.

Standard ScalarBlock Results

Aspen Plus 11.1 Summary File Toolkit Block Result Subroutines •••• 4-9

Compressor ResultsIf you use the Compr or MCompr model with scalar specifications,you can retrieve the standard block results. Retrieving these resultsis described in Standard Block Results, this chapter.If you use Compr with performance curves for a stage, or MComprwith stage-by-stage performance curves, additional results areavailable. These results include:• Percentage above surge• Percentage below stonewall• Speed of compressor shaftIf you use Compr with performance curves for a wheel, orMCompr with wheel-by-wheel performance curves, the followingadditional results are available:• Head coefficient• Flow coefficient• Rotor tip Mach numberYou can retrieve compressor performance results from thesummary file for the Compr and MCompr models. You canconsider Compr results as belonging to a single stage. TheMCompr performance results can be retrieved for each stage of theMCompr model. In addition, you can retrieve the performanceresults for the wheels within each stage of the MCompr modelwhen wheel-by-wheel performance is modeled.Use this two-step process to retrieve the stage-by-stageperformance results:1 Call subroutine TKNPER to determine the number of stage-

by-stage performance results in the Compr/MCompr model,and the number of stages in the MCompr model.

2 Call subroutine TKPERF to retrieve the stage-by-stageperformance data for all stages.

Use these additional two steps to retrieve the wheel-by-wheelperformance results:3 Call subroutine TKNWHL to determine the number of wheels

and the number of wheel-by-wheel performance results in theMCompr model.

4 Call subroutine TKWHLP to retrieve the wheel-by-wheelperformance data for each stage.

Call subroutine TKNPER to determine the number of properties inthe stage-by-stage compressor performance results. TKNPER alsoreturns NSTAGE, the number of compressor stages for MCompr.

Dimensions ofPerformance Results

4-10 •••• Block Result Subroutines Aspen Plus 11.1 Summary File Toolkit

TKNPER returns a NSTAGE value of 1 for Compr. TKNPERreturns a NSTAGE value of 0 for all other models.When there are no performance results, TKNPER may still returnthe number of stages. TKNPER will do this if there are wheel-by-wheel performance results available. Use NPROP (not NSTAGE)to check if there any performance results available.

Calling Sequence for TKNPERCALL TKNPER (BLKID, NPROP, NSTAGE)

Argument List Descriptions for TKNPERVariable I/O † Type Dimension Description

BLKID I CHARACTER*(*) — Block IDNPROP O INTEGER — Number of stage-by-

stage performanceresults properties

NSTAGE O INTEGER — Number of compressorstages

† I = Input to subroutineO = Output from subroutine

Call subroutine TKPERF to retrieve the stage-by-stage compressorperformance results. Use 1 as the value of NSTAGE with theCompr model. The results for the MCompr model are ordered inthe RVALS array, so that all the properties for a stage aresequential.

Calling Sequence for TKPERFCALL TKPERF (BLKID, NPROP, NSTAGE, PNAMES,

RVALS, TYPES, LABELS, IERR)

Argument List Descriptions for TKPERFVariable I/O † Type Dimension Description

BLKID I CHARACTER*(*) — Block IDNPROP I INTEGER — Number of propertiesNSTAGE I INTEGER — Number of stages (1 for

Compr)PNAMES O CHARACTER*12 NPROP Property name. See Chapter

11 for a description.RVALS O REAL*8 NPROP*

NSTAGEReal results

TYPES O CHARACTER*12 NPROP Units typesLABELS O CHARACTER*16 NPROP Units labelsIERR O INTEGER — Error flag (0=No error)† I = Input to subroutine

O = Output from subroutine

Stage-by-StagePerformance Results

Aspen Plus 11.1 Summary File Toolkit Block Result Subroutines •••• 4-11

Call subroutine TKNWHL to determine the number of wheels in aparticular stage of MCompr. The number of properties in thewheel-by-wheel performance results is also returned. CallTKNPER to find the total number of stages.

Calling Sequence for TKNWHLCALL TKNWHL (BLKID, ISTAGE, NWHEEL, NPROP)

Argument List Descriptions for TKNWHLVariable I/O † Type Dimension Description

BLKID I CHARACTER*(*) — Block IDISTAGE I INTEGER — Specified compressor

stageNWHEEL O INTEGER — Number of wheelsNPROP O INTEGER — Number of wheel-by-

wheel performanceresults properties

† I = Input to subroutineO = Output from subroutine

Call subroutine TKWHLR to retrieve the compressor wheel-by-wheel performance results for the specified stage of the MComprmodel. The results are ordered in the RVALS array so that all theproperties for a wheel are sequential.

Calling Sequence for TKWHLRCALL TKWHLR (BLKID, ISTAGE, NPROP, NWHEEL,

PNAMES, RVALS, TYPES, LABELS, IERR)

Argument List Descriptions for TKWHLRVariable I/O † Type Dimension Description

BLKID I CHARACTER*(*) — Block IDISTAGE I INTEGER — Stage numberNPROP I INTEGER — Number of propertiesNWHEEL I INTEGER — Number of wheels in stagePNAMES O CHARACTER*12 NPROP Property name. See Chapter

11 for a description.RVALS O REAL*8 NPROP*

NWHEELReal results

TYPES O CHARACTER*12 NPROP Units typesLABELS O CHARACTER*16 NPROP Units labelsIERR O INTEGER — Error flag (0=No error)† I = Input to subroutine

O = Output from subroutine

Dimensions ofWheel-by-WheelPerformance Results

Wheel-by-WheelPerformance Results

4-12 •••• Block Result Subroutines Aspen Plus 11.1 Summary File Toolkit

Compressor Profile ResultsYou can retrieve profile data for each stage and inter-stage coolerof the multi-stage compressor model MCompr. This requires threesteps:1 Call subroutine TKNMCP to determine the number of

MCompr stages, cooler stages and profile properties.2 Call subroutine TKMCPR to retrieve the profile data for the

MCompr stages.3 Call subroutine TKMCCP to retrieve the profile data for the

MCompr coolers.

Call subroutine TKNMCP to determine the number of stages,cooler stages, stage profile properties and cooler stage profileproperties.

Calling Sequence for TKNMCPCALL TKNMCP (BLKID, NSTAGE, NPROP, NCOOL,

NCPROP)

Argument List Descriptions for TKNMCPVariable I/O † Type Dimension Description

BLKID I CHARACTER*(*) — Block IDNSTAGE O INTEGER — Number of compressor

stagesNPROP O INTEGER — Number of stage profile

propertiesNCOOL O INTEGER — Number of compressor

cooler stagesNCPROP O INTEGER — Number of cooler stage

profile properties† I = Input to subroutine

O = Output from subroutine

Dimensions ofMCompr ProfileResults

Aspen Plus 11.1 Summary File Toolkit Block Result Subroutines •••• 4-13

Call subroutine TKMCPR to retrieve the MCompr profile results.The results are ordered in the RVALS array so that all propertiesfor a stage are sequential.

Calling Sequence for TKMCPRCALL TKMCPR (BLKID, NPROP, NSTAGE, PNAMES,

RVALS, TYPES, LABELS, IERR)

Argument List Descriptions for TKMCPRVariable I/O † Type Dimension Description

BLKID I CHARACTER*(*) — Block IDNPROP I INTEGER — Number of profile

propertiesNSTAGE I INTEGER — Number of stagesPNAMES O CHARACTER*12 NPROP Property name. See

Chapter 11 for adescription.

RVALS O REAL*8 NPROP*NSTAGE

Real results

TYPES O CHARACTER*12 NPROP Units typesLABELS O CHARACTER*16 NPROP Units labelsIERR O INTEGER — Error flag (0=No error)† I = Input to subroutine

O = Output from subroutine

Call subroutine TKMCCP to retrieve the MCompr profile resultsfor the cooler stage. The results are ordered in the RVALS array sothat all the properties for a cooler stage are sequential.

Calling Sequence for TKMCCPCALL TKMCCP (BLKID, NCPROP, NCOOL, PNAMES,

RVALS, TYPES, LABELS, IERR)

Argument List Descriptions for TKMCCPVariable I/O † Type Dimension Description

BLKID I CHARACTER*(*) — Block IDNCPROP I INTEGER — Number of profile

propertiesNCOOL I INTEGER — Number of cooler

stagesPNAMES O CHARACTER*12 NCPROP Property name. See

Chapter 11 for adescription.

MCompr ProfileResults

MCompr CoolerProfile Results

4-14 •••• Block Result Subroutines Aspen Plus 11.1 Summary File Toolkit

Variable I/O † Type Dimension Description

RVALS O REAL*8 NCPROP*NCOOL

Real results

TYPES O CHARACTER*12 NCPROP Units typesLABELS O CHARACTER*16 NCPROP Units labelsIERR O INTEGER — Error flag

(0=No error)† I = Input to subroutine

O = Output from subroutine

Heat Exchanger ResultsYou can retrieve the standard block results and HCURVE data, ifyou use the HeatX model in SHORTCUT mode. Retrieving theseresults is described in Standard Block Results and Heating/CoolingCurves, this chapter. Additional data are available, if you use theHeatX model in the RIGOROUS mode. These are more detailedblock results, zone, shell, tube, baffle and nozzle data. This sectiondescribes how to retrieve these additional rigorous HeatX results.You can retrieve the detailed block results using a three-stepprocess:1 Call subroutine TKNHXD to determine the HeatX detailed

results dimensions.2 Call subroutine TKHXD1 to retrieve detailed results.3 Call subroutine TKHXD2 to retrieve the velocity and pressure

drop results.You can retrieve the zone, shell, tube, baffle and nozzle data usinga six-step process:1 Call subroutine TKNHXT to determine the sizes of the

results.2 Call subroutine TKHXZO to retrieve the zone results.3 Call subroutine TKHXSH to retrieve the shell results.4 Call subroutine TKHXTU to retrieve the tube results.5 Call subroutine TKHXBA to retrieve the baffle results.6 Call subroutine TKHXNO to retrieve the nozzle results.

Aspen Plus 11.1 Summary File Toolkit Block Result Subroutines •••• 4-15

Call subroutine TKNHXD to determine the number of HeatXdetailed results. If NDET1 is returned as zero, there are no rigorousheat exchanger results for this block ID.

Calling Sequence for TKNHXDCALL TKNHXD (BLKID, NDET1, NDET2)

Argument List Descriptions for TKNHXDVariable I/O † Type Dimension Description

BLKID I CHARACTER*(*) — Block IDNDET1 O INTEGER — Number of detailed

resultsNDET2 O INTEGER — Number of velocity-DP

results† I = Input to subroutine

O = Output from subroutine

Call subroutine TKHXD1 to retrieve the first set of detailed results(such as, areas and heat transfer coefficients) for the heatexchanger.

Calling Sequence for TKHXD1CALL TKHXD1 (BLKID, NDET1, PNAMES, RVALS,

TYPES, LABELS, IERR)

Argument List Descriptions for TKHXD1Variable I/O † Type Dimension Description

BLKID I CHARACTER*(*) — Block IDNDET1 I INTEGER — Number of detailed

resultsPNAMES O CHARACTER*12 NDET1 Property name. See

Chapter 11 for adescription.

RVALS O REAL*8 NDET1 Real resultsTYPES O CHARACTER*12 NDET1 Units typesLABELS O CHARACTER*16 NDET1 Units labelsIERR O INTEGER — Error flag (0=No error)† I = Input to subroutine

O = Output from subroutine

Number of DetailedResults

Detailed Results

4-16 •••• Block Result Subroutines Aspen Plus 11.1 Summary File Toolkit

Call subroutine TKHXD2 to retrieve the velocity and pressuredrop results for the heat exchanger.

Calling Sequence for TKHXD2CALL TKHXD2 (BLKID, NDET2, PNAMES, RVALS,

TYPES, LABELS, IERR)

Argument List Descriptions for TKHXD2Variable I/O † Type Dimension Description

BLKID I CHARACTER*(*) — Block IDNDET2 I INTEGER — Number of velocity

pressure drop resultsPNAMES O CHARACTER*12 NDET2 Property name. See

Chapter 11 for adescription.

RVALS O REAL*8 NDET2 Real resultsTYPES O CHARACTER*12 NDET2 Units typesLABELS O CHARACTER*16 NDET2 Units labelsIERR O INTEGER — Error flag

(0=No error)† I = Input to subroutine

O = Output from subroutine

Call TKNHXT to retrieve the sizes of the zone, shell, tube, baffleand nozzle results. Because HeatX can be divided into a number ofzones, the number of zones together with the number of results in azone is returned. A single value is returned for the number of shell,tube, baffle and nozzle results.

Calling Sequence for TKNHXTCALL TKNHXT (BLKID, NZONE, NZORES, NSHRES,

NTURES, NBARES, NNORES)

Argument List Descriptions for TKNHXTVariable I/O † Type Dimension Description

BLKID I CHARACTER*(*) — Block IDNZONE O INTEGER — Number of ZonesNZORES O INTEGER — Number of Zone resultsNSHRES O INTEGER — Number of Shell resultsNTURES O INTEGER — Number of Tube resultsNBARES O INTEGER — Number of Baffle resultsNNORES O INTEGER — Number of Nozzle results† I = Input to subroutine

O = Output from subroutine

Velocity and PressureResults

Heat ExchangerResults Dimensions

Aspen Plus 11.1 Summary File Toolkit Block Result Subroutines •••• 4-17

Call subroutine TKHXZO to retrieve the HeatX zone results. Theresults for all zones are returned in the RVALS array, with thevalues for a zone stored at consecutive locations in this array. Thefirst zones results are from element 1 to element NZORES. Thesecond zones results are from NZORES+1 to 2*NZORES, and soon.

Calling Sequence for TKHXZOCALL TKHXZO (BLKID, NZONE, NZORES, PNAMES,

RVALS, TYPES, LABELS, IERR)

Argument List Descriptions for TKHXZOVariable I/O † Type Dimension Description

BLKID I CHARACTER*(*) — Block IDNZONE I INTEGER — Number of ZonesNZORES I INTEGER — Number of Zone

propertiesPNAMES O CHARACTER*12 NZORES Property name. See

Chapter 11 for adescription.

RVALS O REAL*8 NZORES*NZONE

Real results

TYPES O CHARACTER*12 NZORES Unit typesLABELS O CHARACTER*16 NZORES Unit labelsIERR O INTEGER — Error flag (0=No error)† I = Input to subroutine

O = Output from subroutine

Call subroutine TKHXSH to retrieve the shell results.

Calling Sequence for TKHXSHCALL TKHXSH (BLKID, NSHRES, PNAMES, ITYPES,

IVALS, CVALS, RVALS, TYPES, LABELS,IERR)

Argument List Descriptions for TKHXSHVariable I/O † Type Dimension Description

BLKID I CHARACTER*(*) — Block IDNSHRES I INTEGER — Number of Shell

propertiesPNAMES O CHARACTER*12 NSHRES Property name. See

Chapter 11 for adescription.

Heat Exchanger ZoneResults

Heat Exchanger ShellResults

4-18 •••• Block Result Subroutines Aspen Plus 11.1 Summary File Toolkit

Variable I/O † Type Dimension Description

ITYPES O INTEGER NSHRES Data type of results(1=Integer 2=Real 3=Character)

IVALS O INTEGER NSHRES Integer resultsCVALS O CHARACTER*12 NSHRES Character resultsRVALS O REAL*8 NSHRES Real resultsTYPES O CHARACTER*12 NSHRES Unit typesLABELS O CHARACTER*16 NSHRES Unit labelsIERR O INTEGER — Error flag

(0=No error)† I = Input to subroutine

O = Output from subroutine

Call subroutine TKHXTU to retrieve the tube results.

Calling Sequence for TKHXTUCALL TKHXTU (BLKID, NTURES, PNAMES, ITYPES,

IVALS, CVALS, RVALS, TYPES, LABELS,IERR)

Argument List Descriptions for TKHXTUVariable I/O † Type Dimension Description

BLKID I CHARACTER*(*) — Block IDNTURES I INTEGER — Number of Tube

propertiesPNAMES O CHARACTER*12 NTURES Property name. See

Chapter 11 for adescription.

ITYPES O INTEGER NTURES Data type of results(1=Integer 2=Real 3=Character)

IVALS O INTEGER NTURES Integer resultsCVALS O CHARACTER*12 NTURES Character resultsRVALS O REAL*8 NTURES Real resultsTYPES O CHARACTER*12 NTURES Unit typesLABELS O CHARACTER*16 NTURES Unit labelsIERR O INTEGER — Error flag

(0=No error)† I = Input to subroutine

O = Output from subroutine

Heat Exchanger TubeResults

Aspen Plus 11.1 Summary File Toolkit Block Result Subroutines •••• 4-19

Call subroutine TKHXBA to retrieve the baffle results.

Calling Sequence for TKHXBACALL TKHXBA (BLKID, NBARES, PNAMES, ITYPES,

IVALS, CVALS, RVALS, TYPES, LABELS,IERR)

Argument List Descriptions for TKHXBAVariable I/O † Type Dimension Description

BLKID I CHARACTER*(*) — Block IDNBARES I INTEGER — Number of Baffle

propertiesPNAMES O CHARACTER*12 NBARES Property name. See

Chapter 11 for adescription.

ITYPES O INTEGER NBARES Data type of results(1=Integer 2=Real 3=Character)

IVALS O INTEGER NBARES Integer resultsCVALS O CHARACTER*16 NBARES Character resultsRVALS O REAL*8 NBARES Real resultsTYPES O CHARACTER*12 NBARES Unit typesLABELS O CHARACTER*16 NBARES Unit labelsIERR O INTEGER — Error flag

(0=No error)† I = Input to subroutine

O = Output from subroutine

Call subroutine TKHXNO to retrieve the nozzle results.

Calling Sequence for TKHXNOCALL TKHXNO (BLKID, NNORES, PNAMES, RVALS,

TYPES, LABELS, IERR)

Argument List Descriptions for TKHXNOVariable I/O † Type Dimension Description

BLKID I CHARACTER*(*) — Block IDNNORES I INTEGER — Number of Nozzle

propertiesPNAMES O CHARACTER*12 NNORES Property name. See

Chapter 11 for adescription.

Heat ExchangerBaffle Results

Heat ExchangerNozzle Results

4-20 •••• Block Result Subroutines Aspen Plus 11.1 Summary File Toolkit

Variable I/O † Type Dimension Description

RVALS O REAL*8 NNORES Real resultsTYPES O CHARACTER*12 NNORES Unit typesLABELS O CHARACTER*16 NNORES Unit labelsIERR O INTEGER — Error flag

(0=No error)† I = Input to subroutine

O = Output from subroutine

Heat Exchanger ProfilesThe rigorous HeatX model may have up to four different profiles.They are:• Zone profile• Shell profile• Tube profile• Temperature/Duty profileYou can retrieve the HeatX profile results using a three-stepprocess.1 Call subroutine TKHXPF to determine the size of a profile.2 Call subroutine TKHXPP to get the names of the properties in

a profile.3 Call subroutine TKHXPR to get the results for a property in a

profile.The PRFTYP argument for these functions uses the followingprofile types:PRFTYP Value Profile Type

ZONE_PRF Zone ProfileSHEL_PRF Shell ProfileTUBE_PRF Tube ProfileTQ_PRF Temperature-Duty Profile

Aspen Plus 11.1 Summary File Toolkit Block Result Subroutines •••• 4-21

Call subroutine TKHXPF to determine the size of a profile.TKHXPF returns the size of the profile for the specified profiletype. A size of zero indicates the profile is not present.

Calling Sequence for TKHXPFCALL TKHXPF (BLKID, PRFTYP, NPOINT, NPROP)

Argument List Descriptions for TKHXPFVariable I/O † Type Dimension Description

BLKID I CHARACTER*(*) — Block IDPRFTYP I CHARACTER*8 — Profile type (see above)NPOINT O INTEGER — Number of profile pointsNPROP O INTEGER — Number of profile properties† I = Input to subroutine

O = Output from subroutine

Call subroutine TKHXPP to retrieve the names of the propertiesfor the specified profile type. The properties may have additionallabels, which further describe them. For example, PNAMES =HX_SMCV, LABEL1 = Crossflow, LABEL2 = Velocity.

Calling Sequence for TKHXPPCALL TKHXPP (BLKID, PRFTYP, NPROP, PNAMES,

LABEL1, LABEL2, IERR)

Argument List Descriptions for TKHXPPVariable I/O † Type Dimension Description

BLKID I CHARACTER*(*) — Block IDPRFTYP I CHARACTER*8 — Profile type (see above)NPROP O INTEGER — Number of profile propertiesPNAMES O CHARACTER*12 NPROP Property name. See Chapter

11 for a description.LABEL1 O CHARACTER*12 NPROP First property labelLABEL2 O CHARACTER*12 NPROP Second property labelIERR O INTEGER — Error flag (0=No error)† I = Input to subroutine

O = Output from subroutine

Call subroutine TKHXPR to retrieve the results for the specifiedproperty in a profile. The profile data consists of a number ofpoints within a number of zones. The zone of each value isreturned in IZONE, and the point number is returned in IPOINT.

Heat ExchangerProfile Size

Heat ExchangerProfile Properties

Heat ExchangerProfile Results

4-22 •••• Block Result Subroutines Aspen Plus 11.1 Summary File Toolkit

The results in RVALS are ordered so that all the points for the firstzone are followed by the points for the second zone, and so on.

Calling Sequence for TKHXPRCALL TKHXPR (BLKID, PRFTYP, PNAME, NPOINT,

IZONE, IPOINT, RVALS, TYPE, LABEL,IERR)

Argument List Descriptions for TKHXPRVariable I/O † Type Dimension Description

BLKID I CHARACTER*(*) — Block IDPRFTYP I CHARACTER*8 — Profile type (see above)PNAME I CHARACTER*12 — Property name from

TKHXPPNPOINT I INTEGER — Number of profile pointsIZONE O INTEGER NPOINT Number of zoneIPOINT O INTEGER NPOINT Point number within zoneRVALS O REAL*8 NPOINT Real resultsTYPE O CHARACTER*12 — Unit typesLABEL O CHARACTER*16 — Unit labelsIERR O INTEGER — Error flag (0=No error)† I = Input to subroutine

O = Output from subroutine

Column ResultsYou can retrieve column profile results from the summary file forthe rigorous distillation models RadFrac, MultiFrac, Extract,PetroFrac, and RateFrac. You can retrieve most column resultsusing the following four-step process. See also RadFracThermosyphon Reboiler Results, Additional Data for PetroFracModels, and Additional Data for RateFrac Models, this chapter.1 Call subroutine TKNCOL to determine the number of

columns for MultiFrac, PetroFrac, and RateFrac.2 Call subroutine TKPROF to determine the dimensions of the

profile.3 Call subroutine TKPROP to list the properties.4 Call subroutine TKPRO1 to retrieve the property values for

non-component-dependent properties, or subroutine TKPRO2to retrieve the property values for component-dependentproperties.

Most of the column subroutines take the argument ICOL, whichrepresents the column number. This is always 1 for RadFrac and

Aspen Plus 11.1 Summary File Toolkit Block Result Subroutines •••• 4-23

Extract. For MultiFrac and RateFrac this is the column number: 1,2, and so on. With PetroFrac the main column is numbered 1 andthe strippers are numbered starting with 2. The actual name of astripper can be retrieved using TKPTRS.RateFrac models have segments rather than stages. The referencesto NSTAGE used in the descriptions of the column routines, applyto the number of segments in a RateFrac column.Call subroutine TKNCOL to determine the number of columns in ablock using a staged separation model. TKNCOL returns a valueof 1 for Aspen Plus models RadFrac and Extract. It returns thenumber of columns for MultiFrac and RateFrac. For PetroFrac,NCOL equals the number of strippers plus 1 for the main column.All other models return 0.

Calling Sequence for TKNCOLCALL TKNCOL (BLKID, NCOL)

Argument List Descriptions for TKNCOLVariable I/O † Type Dimension Description

BLKID I CHARACTER*(*) — Block IDNCOL O INTEGER — Number of columns† I = Input to subroutine

O = Output from subroutine

Call subroutine TKPROF to determine the sizes of column profilearrays. TKPROF returns the number of:• Stages• Components present• Properties

Calling Sequence for TKPROFCALL TKPROF (BLKID, ICOL, NSTAGE, NCP, NPROP)

Argument List Descriptions for TKPROFVariable I/O † Type Dimension Description

BLKID I CHARACTER*(*) — Block IDICOL I INTEGER — Column numberNSTAGE O INTEGER — Number of stagesNCP O INTEGER — Number of components

presentNPROP O INTEGER — Number of properties† I = Input to subroutine

O = Output from subroutine

Number of Columns

Column ProfileDimensions

4-24 •••• Block Result Subroutines Aspen Plus 11.1 Summary File Toolkit

Call subroutine TKPROP to list the profile properties available fora block. Each property is identified as component-dependent ornot.

Calling Sequence for TKPROPCALL TKPROP (BLKID, ICOL, NPROP, ITYPES, PNAMES,

IERR)

Argument List Descriptions for TKPROPVariable I/O † Type Dimension Description

BLKID I CHARACTER*(*) — Block IDICOL I INTEGER — Column numberNPROP I INTEGER — Number of propertiesITYPES O INTEGER NPROP Property type

(1=Non-component-dependent, 2=Component-dependent)

PNAMES O CHARACTER*12 NPROP Property name. See Chapter11 for a description.

IERR O INTEGER — Error flag (0=No error)† I = Input to subroutine

O = Output from subroutine

Call subroutine TKPRO1 to retrieve the profile for a non-component-dependent property. This includes hydraulic properties.TKPRO1 returns a single units type and label for the entire profile.

Calling Sequence for TKPRO1CALL TKPRO1 (BLKID, PNAME, ICOL, NSTAGE, RVALS,

TYPE, LABEL, IERR)

Argument List Descriptions for TKPRO1Variable I/O † Type Dimension Description

BLKID I CHARACTER*(*) — Block IDPNAME I CHARACTER*12 — Property name

returned by TKPROPICOL I INTEGER — Column numberNSTAGE I INTEGER — Number of stagesRVALS O REAL*8 NSTAGE Property valuesTYPE O CHARACTER*12 — Units typeLABEL O CHARACTER*16 — Units labelIERR O INTEGER — Error flag (0=No error)† I = Input to subroutine

O = Output from subroutine

Column ProfileProperties

Non-Component-Dependent ColumnProfiles

Aspen Plus 11.1 Summary File Toolkit Block Result Subroutines •••• 4-25

Call subroutine TKPRO2 to retrieve the profile for a component-dependent property. The results are in the RVALS array, whichreturns NCP * NSTAGE results. Treat RVALS as a one-dimensional array. All property results for a stage are storedconsecutively. TKPRO2 returns a single units type and label forthe entire profile.

Calling Sequence for TKPRO2CALL TKPRO2 (BLKID, PNAME, ICOL, NCP, COMPID,

NSTAGE, RVALS, TYPE, LABEL, IERR)

Argument List Descriptions for TKPRO2Variable I/O † Type Dimension Description

BLKID I CHARACTER*(*) — Block IDPNAME I CHARACTER*12 — Property name returned

by TKPROPICOL I INTEGER — Column numberNCP I INTEGER — Number of components

presentCOMPID O CHARACTER*8 NCP Component IDsNSTAGE I INTEGER — Number of stagesRVALS O REAL*8 NCP*

NSTAGEProperty values

TYPE O CHARACTER*12 — Units typesLABEL O CHARACTER*16 — Units labelsIERR O INTEGER — Error flag (0=No error)† I = Input to subroutine

O = Output from subroutine

A RadFrac unit may optionally have a thermosyphon reboiler. Youcan retrieve this data using two steps:1 Call TKTRNR to determine the numbers of results and

components.2 Call TKTRRS to retrieve the property names, results, and list

of components.

Component-Dependent ColumnProfiles

RadFracThermosyphonReboiler Results

4-26 •••• Block Result Subroutines Aspen Plus 11.1 Summary File Toolkit

Call subroutine TKTRNR to determine the number of componentspresent, the number of component-dependent properties withresults, and the number of properties with results that are non-component-dependent. If the unit does not have a thermosyphonreboiler, NRES, NCPROP, and NCP are all returned as 0.

Calling Sequence for TKTRNRCALL TKTRNR (BLKID, NRES, NCPROP, NCP)

Argument List Descriptions for TKTRNRVariable I/O † Type Dimension Description

BLKID I CHARACTER*(*) — Block IDNRES O INTEGER — Number of non-

component-dependentresults

NCPROP O INTEGER — Number of component-dependent properties

NCP O INTEGER — Number of componentspresent in reboiler

† I = Input to subroutineO = Output from subroutine

Call subroutine TKTRRS to retrieve the property names and valuesfor the thermosyphon reboiler. Two sets of property names andvalues are returned: one for the component-dependent results andone for the non-component-dependent results. Note that thecomponent-dependent data is returned in a single array, with all theresults for a single property returned in consecutive elements of theCRVALS array.

Calling Sequence for TKTRRSCALL TKTRRS (BLKID, NRES, NCPROP, NCP, PNAME,

RVALS, TYPES, LABELS, CPNAME,COMPID, CRVALS, IERR)

Argument List for Subroutine TKTRRSVariable I/O † Type Dimension Description

BLKID I CHARACTER*(*) — Block IDNRES I INTEGER — Number of non-component-

dependent resultsNCPROP I INTEGER — Number of component-

dependent resultsNCP I INTEGER — Number of components present

in reboiler

Number of Components

Reboiler Results

Aspen Plus 11.1 Summary File Toolkit Block Result Subroutines •••• 4-27

Variable I/O † Type Dimension Description

PNAMES O CHARACTER*12 NRES Property names for non-component-dependent results.See Chapter 11 for adescription.

RVALS O REAL*8 NRES Results for non-component-dependent properties

TYPES O CHARACTER*12 NRES Results types for non-component-dependentproperties

LABELS O CHARACTER*16 NRES Results labels for non-component-dependentproperties

CPNAME O CHARACTER*12 NCPROP Property names forcomponent-dependent results

COMPID O CHARACTER*8 NCP Component namesCRVALS O REAL*8 NCP*

NCPROPResults for component-dependent properties

IERR O INTEGER — Error flag (0=No error)† I = Input to subroutine

O = Output from subroutine

The MultiFrac and RateFrac models may contain interconnectingstreams. The RadFrac model may contain pumparounds. You canretrieve the data for these streams and pumparounds using thesetwo steps:1 Call TKNICS to determine the number of interconnecting

streams or pumparounds in the model.2 Call TKICST to retrieve the results for all the interconnecting

streams or pumparounds in a model.

InterconnectingStream andPumparound Results

4-28 •••• Block Result Subroutines Aspen Plus 11.1 Summary File Toolkit

Call subroutine TKNICS to determine the number ofinterconnecting streams present in a MultiFrac or RateFrac model.Also call TKNICS to determine the number of pumparounds in aRadFrac model. The value of NICST is returned as 0 if the modeldoes not have any interconnecting streams or pumparounds.

Calling Sequence for TKNICSCALL TKNICS (BLKID, NICST)

Argument List Descriptions for TKNICSVariable I/O † Type Dimension Description

BLKID I CHARACTER*(*) — Block IDNICST O INTEGER — Number of interconnecting

streams or pumparounds† I = Input to subroutine

O = Output from subroutine

Call subroutine TKICST to retrieve the results for MultiFrac orRateFrac interconnecting streams. Also call TKICST to retrievethe results for RadFrac pumparounds. The routine returns arrayscontaining the results for all the interconnecting streams orpumparounds in a model. Source and destination data are notreturned for the RateFrac model, and zeros are returned for theseproperties. The mass and volume flows are also unavailable for theRateFrac model, and values of RMISS are returned for theseproperties.

Calling Sequence for TKICSTCALL TKICST (BLKID, NICST, ISCOL, ISSTG, IDCOL,

IDSTG, TEMP, PRES, DUTY, VFRAC,FMOLE, FMASS, FVOL, IERR)

Argument List Descriptions for TKICSTVariable I/O † Type Dimension Description

BLKID I CHARACTER*(*) — Block IDNICST I INTEGER — Number of interconnecting

streams or pumparoundsISCOL O INTEGER NICST Source ColumnISSTG O INTEGER NICST Source StageIDCOL O INTEGER NICST Destination ColumnIDSTG O INTEGER NICST Destination StageTEMP O REAL*8 NICST TemperaturePRES O REAL*8 NICST PressureDUTY O REAL*8 NICST Duty

Number ofInterconnecting Streamsand Pumparounds

Retrieving Results forInterconnecting Streamsand Pumparounds

Aspen Plus 11.1 Summary File Toolkit Block Result Subroutines •••• 4-29

Variable I/O † Type Dimension Description

VFRAC O REAL*8 NICST Vapor FractionFMOLE O REAL*8 NICST Mole FlowFMASS O REAL*8 NICST Mass FlowFVOL O REAL*8 NICST Standard liquid volume

flowIERR O INTEGER — Error flag (0=No error)† I = Input to subroutine

O = Output from subroutine

4-30 •••• Block Result Subroutines Aspen Plus 11.1 Summary File Toolkit

Additional Data for PetroFrac ModelsThe PetroFrac model has a number of additional routines thatretrieve the results for the pumparounds, furnace, and connectivityof the model. The PetroFrac model consists of a main column anda number of strippers.1 Call subroutine TKNPET to determine the dimensions of the

additional data.2 Call subroutine TKPTRS to retrieve additional data for each

column.3 Call TKPTAD to list additional property profiles.4 Call TKPTPR to retrieve the values of the additional property

profiles.5 Call subroutine TKPTFR to retrieve the PetroFrac furnace

data.6 Call subroutine TKFRCM to retrieve the values for

component-dependent properties in the furnace.7 Call subroutine TKPTPP to retrieve pumparound results for

the PetroFrac columns.8 Call subroutine TKPTCN to retrieve connectivity data for the

strippers.

Call subroutine TKNPET for each column number in the PetroFracmodel to determine the sizes of the additional data. If a type of datais not present for the column number, the size is returned as 0. Themain column always returns 0 for NSTRCN and NCNRES. Thestrippers always return 0 for NPUMP, NPRRES, NFRCON,NFRRES, NFPROP, and NFCOMP.

Calling Sequence for TKNPETCALL TKNPET (BLKID, ICOL, NMOLE, NMASS, NSVOL,

NRES, NPUMP, NPRRES, NFRCON, NFRRES,NFPROP, NFCOMP, NSTRCN, NCNRES)

Argument List Descriptions for TKNPETVariable I/O † Type Dimension Description

BLKID I CHARACTER*(*) — Block IDICOL I INTEGER — Column numberNMOLE O INTEGER — Number of molar profile

resultsNMASS O INTEGER — Number of mass profile resultsNSVOL O INTEGER — Number of standard liquid

volume profile results

Dimensions ofAdditional Data

Aspen Plus 11.1 Summary File Toolkit Block Result Subroutines •••• 4-31

Variable I/O † Type Dimension Description

NRES O INTEGER — Number of scalar columnresults

NPUMP O INTEGER — Number of pumparoundsNPRRES O INTEGER — Number of pumparound resultsNFRCON O INTEGER — Number of furnace streamsNFRRES O INTEGER — Number of furnace resultsNFPROP O INTEGER — Number of furnace component

propertiesNFCOMP O INTEGER — Number of furnace

componentsNSTRCN O INTEGER — Number of connectivity

streamsNCNRES O INTEGER — Number of connectivity results† I = Input to subroutine

O = Output from subroutine

TKBRES (see Standard Scalar Block Results, this chapter) returnsthe convergence data for PetroFrac column numbers.Call subroutine TKPTRS to retrieve the additional scalar resultsdata for each PetroFrac column number.

Calling Sequence for TKPTRSCALL TKPTRS (BLKID, ICOL, NRES, NAME, PNAMES,

RVALS, TYPES, LABELS, IERR)

Argument List Descriptions for TKPTRSVariable I/O † Type Dimension Description

BLKID I CHARACTER*(*) — Block IDICOL I INTEGER — Column numberNRES I INTEGER — Number of column resultsNAME O CHARACTER*8 — Side stripper namePNAMES O CHARACTER*12 NRES Property name. See

Chapter 11 for adescription.

RVALS O REAL*8 NRES ResultsTYPES O CHARACTER*12 NRES Units typeLABELS O CHARACTER*16 NRES Units labelIERR O INTEGER — Error flag (0=No error)† I = Input to subroutine

O = Output from subroutine

Additional ScalarResults Data

4-32 •••• Block Result Subroutines Aspen Plus 11.1 Summary File Toolkit

Call TKPTAD to list the additional profile properties available foreach column number. None of these properties iscomponent-dependent (see Column Profile Properties, thischapter). There are three sets of additional properties for PetroFrac.These consist of similar properties. But the results are returned oneither a molar, mass, or standard liquid volume basis, dependingon the value you give for BASIS. The number of properties differsslightly for each BASIS, so ensure that NPROF is set to the correctvalue returned from TKNPET. The value of NPROF is NMOLEfor MOLE BASIS, NMASS for MASS, and NSVOL for SVOL.

Calling Sequence for TKPTADCALL TKPTAD (BLKID, ICOL, NPROF, BASIS, PNAMES,

IERR)

Argument List Descriptions for TKPTADVariable I/O † Type Dimension Description

BLKID I CHARACTER*(*) — Block IDICOL I INTEGER — Column numberNPROF I INTEGER — Number of profile properties.

(Use the value NMOLE,NMASS, or SVOL fromTKNPET.)

BASIS I CHARACTER*4 — Basis for profile(MOLE, MASS, or SVOL)

PNAMES O CHARACTER*12 NPROF Property name. See Chapter 11for a description.

IERR O INTEGER — Error flag (0=No error)† I = Input to subroutine

O = Output from subroutine

Call TKPTPR to retrieve profiles for the PetroFrac additionalproperties.

Calling Sequence for TKPTPRCALL TKPTPR (BLKID, PNAME, ICOL, NSTAGE, BASIS,

RVALS, TYPE, LABEL, IERR)

Argument List Descriptions for TKPTPRVariable I/O † Type Dimension Description

BLKID I CHARACTER*(*) — Block IDPNAME I CHARACTER*12 — Profile property name

from TKPTADICOL I INTEGER — Column numberNSTAGE I INTEGER — Number of stages

Additional PetroFracProfile Properties

Additional PropertyProfiles

Aspen Plus 11.1 Summary File Toolkit Block Result Subroutines •••• 4-33

Variable I/O † Type Dimension Description

BASIS I CHARACTER*4 — Basis for profile(MOLE, MASS, orSVOL)

RVALS O REAL*8 NSTAGE Real valuesTYPE O CHARACTER*12 — Units typeLABEL O CHARACTER*16 — Units labelIERR O INTEGER — Error flag (0=No error)† I = Input to subroutine

O = Output from subroutine

Call subroutine TKPTFR to retrieve the furnace data for PetroFrac.Data is returned for each connection between the furnace and aPetroFrac column. Supply the connection number in the ICONparameter. The connections are numbered sequentially, starting at1. The total number of connections is given by the NFRCONparameter returned in TKNPET.

Calling Sequence for TKPTFRCALL TKPTFR (BLKID, ICON, NFRRES, PNAMES,

ITYPES, IVALS, CVALS, RVALS, TYPES,LABELS, IERR)

Argument List Descriptions for TKPTFRVariable I/O † Type Dimension Description

BLKID I CHARACTER*(*) — Block IDICON I INTEGER — Connection numberNFRRES I INTEGER — Number of propertiesPNAMES O CHARACTER*12 NFRRES Property name. See

Chapter 11 for adescription.

ITYPES O INTEGER NFRRES Result type(1=Integer, 2=Real,3=Character)

IVALS O INTEGER NFRRES Integer valuesCVALS O CHARACTER*12 NFFRES Character valuesRVALS O REAL*8 NFRRES Real valuesTYPES O CHARACTER*12 NFRRES Units typeLABELS O CHARACTER*16 NFRRES Units labelIERR O INTEGER — Error flag (0=No error)† I = Input to subroutine

O = Output from subroutine

Furnace Data forPETROFRAC

4-34 •••• Block Result Subroutines Aspen Plus 11.1 Summary File Toolkit

Call subroutine TKFRCM to retrieve the values for component-dependent properties in the PetroFrac furnace. The property namesand the results are returned. The real values are returned. All thedata for a property are arranged sequentially in the array, followedby all the data for the second property, and so on. Since all theproperties are dimensionless, TYPES and LABELS return blankstrings.

Calling Sequence for TKFRCMCALL TKFRCM (BLKID, NFPROP, NFCOMP, PNAMES,

COMPID, RVALS, TYPES, LABELS, IERR)

Argument List Descriptions for TKFRCMVariable I/O † Type Dimension Description

BLKID I CHARACTER*(*) — Block IDNFPROP I INTEGER — Number of propertiesNFCOMP I INTEGER — Number of componentsPNAMES O CHARACTER*12 NFPROP Property name. See Chapter

11 for a description.COMPID O CHARACTER*8 NFCOMP Component namesRVALS O REAL*8 NFCOMP*

NFPROPReal values

TYPES O CHARACTER*12 NFPROP Units typeLABELS O CHARACTER*16 NFPROP Units labelIERR O INTEGER — Error flag (0=No error)† I = Input to subroutine

O = Output from subroutine

Call subroutine TKPTPP to retrieve pumparound results for thePetroFrac columns. Supply the pumparound number in the IPUMPparameter. The pumparounds are numbered sequentially, startingat 1. The total number of pumparounds is given by the NPUMPparameter returned in TKNPET.

Calling Sequence for TKPTPPCALL TKPTPP (BLKID, IPUMP, NPRRES, PNAMES,

ITYPES, IVALS, RVALS, TYPES, LABELS,IERR)

Argument List Descriptions for TKPTPPVariable I/O † Type Dimension Description

BLKID I CHARACTER*(*) — Block IDIPUMP I INTEGER — Pumparound numberNPRRES I INTEGER — Number of properties

Component-Dependent Propertiesfor the PetroFracFurnace

Pumparound Resultsfor PetroFracColumns

Aspen Plus 11.1 Summary File Toolkit Block Result Subroutines •••• 4-35

Variable I/O † Type Dimension Description

PNAMES O CHARACTER*12 NPRRES Property name. See Chapter11 for a description.

ITYPES O INTEGER NPRRES Result type(1=Integer, 2=Real)

IVALS O INTEGER NPRRES Integer valuesRVALS O REAL*8 NPPRES Real valuesTYPES O CHARACTER*12 NPRRES Units typeLABELS O CHARACTER*16 NPRRES Units labelIERR O INTEGER — Error flag (0=No error)† I = Input to subroutine

O = Output from subroutine

Call subroutine TKPTCN to retrieve connectivity data for thePetroFrac strippers. Specify the column number of the stripper inICOL and the connection number in ICON. The connections arenumbered sequentially, starting at 1. The total number ofconnections for each stripper is given by the NSTRCN parameterin TKNPET.

Calling Sequence for TKPTCNCALL TKPTCN (BLKID, ICOL, ICON, NCNRES, PNAMES,

ITYPES, IVALS, CVALS, RVALS, TYPES,LABELS, IERR)

Argument List Descriptions for TKPTCNVariable I/O † Type Dimension Description

BLKID I CHARACTER*(*) — Block IDICOL I INTEGER — Column numberICON I INTEGER — Connection numberNCNRES I INTEGER — Number of propertiesPNAMES O CHARACTER*12 NCNRES Property name. See Chapter

11 for a description.ITYPES O INTEGER NCNRES Result type

(1=Integer, 2=Real)IVALS O INTEGER NCNRES Integer valuesCVALS O CHARACTER*12 NCNRES Character valuesRVALS O REAL*8 NCNRES Real valuesTYPES O CHARACTER*12 NCNRES Units typeLABELS O CHARACTER*16 NCNRES Units labelIERR O INTEGER — Error flag (0=No error)† I = Input to subroutine

O = Output from subroutine

Connectivity Data forPetroFrac Strippers

4-36 •••• Block Result Subroutines Aspen Plus 11.1 Summary File Toolkit

The RateFrac model has additional routines to retrieve furtherscalar block results, the component split fractions in the outletstreams, and the number of liquid phases in each segment of thecolumn.You can retrieve the additional scalar results data, using a two-stepprocess:1 Call subroutine TKRTNR to determine the dimensions of the

additional scalar results data.2 Call subroutine TKRTRS to retrieve the additional scalar

results for each column.You can retrieve the split fractions of each component in the outletstreams, using a two-step process:1 Call subroutine TKRTSP to determine the dimensions of the

split fractions.2 Call subroutine TKRTSP to retreive the split fraction results.Call subroutine TKRTNL to determine the number of liquid phasesin each segment of a column.

Call subroutine TKRTNR for each column number in the RateFracmodel, to determine the sizes for the additional data. NRES isreturned as zero if the model has no additional scalar results.

Calling Sequence for TKRTNRCALL TKRTNR (BLKID, ICOL, NRES)

Argument List Descriptions for TKRTNRVariable I/O † Type Dimension Description

BLKID I CHARACTER*(*) — Block IDICOL I INTEGER — Column numberNRES O INTEGER — Number of scalar results† I = Input to subroutine

O = Output from subroutine

Additional Data forRateFrac Models

Dimensions ofAdditional ScalarData

Aspen Plus 11.1 Summary File Toolkit Block Result Subroutines •••• 4-37

TKBRES (see Standard Scalar Block Results, this chapter) returnsthe convergence data for the RateFrac column.Call subroutine TKRTRS to retrieve the additional scalar data foreach RateFrac column.

Calling Sequence for TKRTRSCALL TKRTRS (BLKID, ICOL, NRES, PNAMES, RVALS,

TYPES, LABELS, IERR)

Argument List Descriptions for TKRTRSVariable I/O † Type Dimension Description

BLKID I CHARACTER*(*) — Block IDICOL I INTEGER — Column numberNRES O INTEGER — Number of scalar resultsPNAMES O CHARACTER*12 — Property names. See

Chapter 11 for adescription.

RVALS O REAL*8 NRES Real valuesTYPES O CHARACTER*12 NRES Unit typesLABELS O CHARACTER*16 NRES Unit labelsIERR O INTEGER — Error flag

(0=No error)† I = Input to subroutine

O = Output from subroutine

Call subroutine TKRTSP to determine the dimensions of thecomponent split fraction results.

Calling Sequence for TKRTSPCALL TKRTSP (BLKID, NCP, NSTREAM)

Argument List Descriptions for TKRTSPVariable I/O † Type Dimension Description

BLKID I CHARACTER*(*) — Block IDNCP O INTEGER — Number of

components in outletstreams

NSTREAM O INTEGER — Number of outletstreams

† I = Input to subroutineO = Output from subroutine

Additional ScalarResults Data

Dimensions ofComponent SplitFractions

4-38 •••• Block Result Subroutines Aspen Plus 11.1 Summary File Toolkit

Call subroutine TKRTSR to retrieve the component split fractionsin the RateFrac outlet streams. The results are ordered in theSFRACS array so that all the fractions for a component arereturned consecutively.

Calling Sequence for TKRTSRCALL TKRTSR (BLKID, NCP, NSTREAM, COMPID,

STRMID, SFRACS, IERR)

Argument List Descriptions for TKRTSRVariable I/O † Type Dimension Description

BLKID I CHARACTER*(*) — Block IDNCP I INTEGER — Number of components in

outlet streamsNSTREAM I INTEGER — Number of outlet streamsCOMPID O CHARACTER*8 NCP Component IDsSTRMID O CHARACTER*8 NSTREAM Outlet Stream IDsSFRACS O REAL*8 NSTREAM*

NCPComponent SplitFractions

IERR O INTEGER — Error flag (0=No error)† I = Input to subroutine

O = Output from subroutine

Call subroutine TKRTNL to get the number of liquid phases ineach segment of the specified column.

Calling Sequence for TKRTNLCALL TKRTNL (BLKID, ICOL, NSTAGE, NLIQ, IERR)

Argument List Descriptions for TKRTNLVariable I/O † Type Dimension Description

BLKID I CHARACTER*(*) — Block IDICOL I INTEGER — Column numberNSTAGE I INTEGER — Number of sections

(Use NSTAGE fromTKPROF)

NLIQ I INTEGER NSTAGE Number of liquidphases

IERR O INTEGER — Error flag (0=No error)† I = Input to subroutine

O = Output from subroutine

Component SplitFractions

Number of LiquidPhases

Aspen Plus 11.1 Summary File Toolkit Block Result Subroutines •••• 4-39

Tray ReportsTray report results are calculated when the Tray-Report option ischosen for a rigorous distillation model. The user defines theproperties calculated and the stages for which they are calculated.

Call subroutine TKTREP to determine the dimensions of the trayreport for a block. TKTREP returns the number of stages for whichproperties are calculated, and the number of properties in the trayreport.

Calling Sequence for TKTREPCALL TKTREP (BLKID, ICOL, NSTAGE, NPROP)

Argument List Descriptions for TKTREPVariable I/O † Type Dimension Description

BLKID I CHARACTER*(*) — Block IDICOL I INTEGER — Column numberNSTAGE O INTEGER — Number of stage valuesNPROP O INTEGER — Total number of

properties† I = Input to subroutine

O = Output from subroutine

Call subroutine TKNTPR to retrieve the next property from a trayreport. Use the property sequence number INUM to specify theproperty. TKNTPR returns the list of stage numbers, the propertyvalue, the property set qualifiers, and the units type and label.

Calling Sequence for TKNTPRCALL TKNTPR (BLKID, ICOL, INUM, NSTAGE,

ISTAGE, PNAME, SUBSID, PHASE,COMPID, WETDRY, BASIS, RVALS, TYPE,LABEL, IERR)

Argument List Descriptions for TKNTPRVariable I/O † Type Dimension Description

BLKID I CHARACTER*(*) — Block IDICOL I INTEGER — Column numberINUM I INTEGER — Property sequence

numberNSTAGE I INTEGER — Number of stage valuesISTAGE O INTEGER NSTAGE List of stage numbers

Tray ReportDimensions

Sequential TrayReport Properties

4-40 •••• Block Result Subroutines Aspen Plus 11.1 Summary File Toolkit

Variable I/O † Type Dimension Description

PNAME O CHARACTER*12 — Property name. SeeChapter 11 for adescription.

SUBSID O CHARACTER*8 — Substream IDPHASE O CHARACTER*8 — PhaseCOMPID O CHARACTER*8 — Component IDWETDRY O CHARACTER*4 — Wet/dry basis (WET or

DRY) ††

BASIS O CHARACTER*4 — Units basis(MOLE, MASS, orFLOW)

RVALS O REAL*8 NSTAGE Property valuesTYPE O CHARACTER*12 — Units typeLABEL O CHARACTER*16 — Units labelIERR O INTEGER — Error flag

(0=No error)† I = Input to subroutine

O = Output from subroutine†† Can be left unspecified.

Call subroutine TKTPRP to retrieve a specific property from thetray report for a block. The property is identified by specifying theproperty set qualifiers (PNAME, SUBSID, PHASE, COMPID,WETDRY, BASIS). Before calling TKTPRP, make sure that allthe qualifiers are either set to the desired values or unset. TKTPRPreturns the list of stage numbers, the property values, and the unitstype and label.

Calling Sequence for TKTPRPCALL TKTPRP (BLKID, ICOL, NSTAGE, ISTAGE,

PNAME, SUBSID, PHASE, COMPID,WETDRY, BASIS, RVALS, TYPE, LABEL,IERR)

Argument List Descriptions for TKTPRPVariable I/O † Type Dimension Description

BLKID I CHARACTER*(*) — Block IDICOL I INTEGER — Column numberNSTAGE I INTEGER — Number of stage valuesISTAGE O INTEGER NSTAGE List of stage numbersPNAME I CHARACTER*12 — Property name. See Chapter 11

for a list of valid property names.SUBSID I CHARACTER*8 — Substream ID

PHASE I CHARACTER*8 — Phase

Specific Tray ReportProperties

Aspen Plus 11.1 Summary File Toolkit Block Result Subroutines •••• 4-41

Variable I/O † Type Dimension Description

COMPID I CHARACTER*8 — Component IDWETDRY I CHARACTER*4 — Wet/dry basis (WET or DRY)††

BASIS I CHARACTER*4 — Units basis (MOLE, MASS, orFLOW)

RVALS O REAL*8 NSTAGE Property valuesTYPE O CHARACTER*12 — Units typeLABEL O CHARACTER*16 — Units labelIERR O INTEGER — Error flag (0=No error)† I = Input to subroutine

O = Output from subroutine†† Can be left unspecified.

Tray/Packing Sizing and RatingYou can retrieve column tray/packing sizing and rating data for therigorous distillation models RadFrac, MultiFrac, and PetroFrac.You can retrieve the results using a seven-step process:1 Call subroutine TKNCOL to determine the number of

columns where appropriate.2 Call subroutine TKNSEC to determine the number of sections

in the column.3 Call subroutine TKLSEC to list the column section types and

their numbers.4 Call subroutine TKSSEC to determine the dimensions of a

section.5 Call subroutine TKSCRS to retrieve the scalar results for the

column section.6 Call subroutine TKPSEC to obtain a list of the properties in a

section profile.7 Call subroutine TKSCPR to retrieve the profile data for a

named property in a section.Several subroutines below have a TYPE or TYPES argument forsection types. The possible values are:TYPE value Type of column section

TRAY-SIZE Tray sizingTRAY-RATE Tray ratingPACK-SIZE Packed sizingPACK-RATE Packed rating

4-42 •••• Block Result Subroutines Aspen Plus 11.1 Summary File Toolkit

If you want to retrieve MultiFrac or PetroFrac data, call TKNCOL.(See Column Results, this chapter.) Omit this step if you want toretrieve RadFrac data.

Call subroutine TKNSEC to determine the number ofTray/Packing Sizing and Rating calculation sections in the column.

Calling Sequence for TKNSECCALL TKNSEC (BLKID, ICOL, NSECT, IERR)

Argument List Descriptions for TKNSECVariable I/O † Type Dimension Description

BLKID I CHARACTER*(*) — Block IDICOL I INTEGER — Column number

(MultiFrac andPetroFrac)

NSECT O INTEGER — Number of sectionsIERR O INTEGER — Error flag (0=No error)† I = Input to subroutine

O = Output from subroutine

Call subroutine TKLSEC to list the section types and numbersused to identify individual sections.

Calling Sequence for TKLSECCALL TKLSEC (BLKID, ICOL, NSECT, TYPES, NUMBRS,

IERR)

Argument List Descriptions for TKLSECVariable I/O † Type Dimension Description

BLKID I CHARACTER*(*) — Block IDICOL I INTEGER — Column number.

(MultiFrac and PetroFrac)NSECT I INTEGER — Number of sectionsTYPES O CHARACTER*12 NSECT Types of column sections

(see above)NUMBRS O INTEGER NSECT Section numbersIERR O INTEGER — Error flag (0=No error)† I = Input to subroutine

O = Output from subroutine

Number of Columns

Number of ColumnSections

Column SectionTypes and Numbers

Aspen Plus 11.1 Summary File Toolkit Block Result Subroutines •••• 4-43

Call subroutine TKSSEC to determine the dimensions of a section.TKSSEC returns the number of:• Stages in a section• Scalar properties• Profile propertiesProfile properties have a value for each stage in a section. Scalarproperties have a single value for a section as a whole.

Calling Sequence for TKSSECCALL TKSSEC (BLKID, ICOL, TYPE, NUMBER, NSTAGE,

NPROF, NSCAL, IERR)

Argument List Descriptions for TKSSECVariable I/O † Type Dimension Description

BLKID I CHARACTER*(*) — Block IDICOL I INTEGER — Column number

(MultiFrac and PetroFrac)TYPE I CHARACTER*12 — Section type (see above)NUMBER I INTEGER — Section numberNSTAGE O INTEGER — Number of stages in the

sectionNPROF O INTEGER — Number of profile propertiesNSCAL O INTEGER — Number of scalar propertiesIERR O INTEGER — Error flag (0=No error)† I = Input to subroutine

O = Output from subroutine

Call subroutine TKSCRS to retrieve the section results for thescalar properties.

Calling Sequence for TKSCRSCALL TKSCRS (BLKID, ICOL, TYPE, NUMBER, NSCAL,

PNAMES, ITYPES, IVALS, CVALS, RVALS,UTYPES, LABELS, IERR)

Argument List Descriptions for TKSCRSVariable I/O † Type Dimension Description

BLKID I CHARACTER*(*) — Block IDICOL I INTEGER — Column number

(MultiFrac and PetroFrac)TYPE I CHARACTER*12 — Section type (see above)NUMBER I INTEGER — Section numberNSCAL I INTEGER — Number of scalar properties

Size of a ColumnSection

Scalar Results for aColumn Section

4-44 •••• Block Result Subroutines Aspen Plus 11.1 Summary File Toolkit

Variable I/O † Type Dimension Description

PNAMES O CHARACTER*12 NSCAL Property name. See Chapter 11for a description.

ITYPES O INTEGER NSCAL Result types(1=Integer value2=Real*8 value3=Character*12 value)††

IVALS O INTEGER NSCAL Integer resultCVALS O CHARACTER*12 NSCAL Character resultRVALS O REAL*8 NSCAL Real resultUTYPES O CHARACTER*12 NSCAL Units typesLABELS O CHARACTER*16 NSCAL Units labelsIERR O INTEGER — Error flag (0=No error)† I = Input to subroutine

O = Output from subroutine†† For each result, the value in ITYPE specifies which array contains the

result (IVALS, CVALS, or RVALS).For example, if ITYPE(4) is 2, then IVALS(4) is 0, CVALS(4) is blank andRVALS(4) contains the result.

Call routine TKPSEC to retrieve the list of properties for aspecified section profile. TKPSEC returns an array of propertynames. When you specify a tray rating section type, TKPSEC alsoreturns an array indicating if the property belongs to panel A, B, C,or D.

Calling Sequence for TKPSECCALL TKPSEC (BLKID, ICOL, TYPE, NUMBER, NPROF,

PNAMES, PANELS, IERR)

Argument List Descriptions for TKPSECVariable I/O † Type Dimension Description

BLKID I CHARACTER*(*) — Block IDICOL I INTEGER — Column number

(MultiFrac and PetroFrac)TYPE I CHARACTER*12 — Section type (see above)NUMBER I INTEGER — Section numberNPROF I INTEGER — Number of profile propertiesPNAMES O CHARACTER*12 NPROF Property name. See Chapter 11

for a description.PANELS O CHARACTER*1 NPROF Panel identifier (A, B, C, D)

(TRAY-RATE only)IERR O INTEGER — Error flag (0=No error)† I = Input to subroutine

O = Output from subroutine

Column SectionProfile Properties

Aspen Plus 11.1 Summary File Toolkit Block Result Subroutines •••• 4-45

Call subroutine TKSCPR to retrieve the section profile data for thenamed property. If the section type is TRAY-RATE, you mustspecify the panel.

Calling Sequence for TKSCPRCALL TKSCPR (BLKID, ICOL, TYPE, NUMBER, NSTAGE,

ISTAGE, PNAME, PANEL, RVALS, UTYPE,LABEL, IERR)

Argument List Descriptions for TKSCPRVariable I/O † Type Dimension Description

BLKID I CHARACTER*(*) — Block IDICOL I INTEGER — Column number

(MultiFrac and PetroFrac)TYPE I CHARACTER*12 — Section type (see above)NUMBER I INTEGER — Section numberNSTAGE I INTEGER — Number of stages in sectionISTAGE O INTEGER NSTAGE List of stage numbersPNAME I CHARACTER*12 — Property name from TKPSECPANEL I CHARACTER*1 — Panel identifier (A, B, C, D)

(TRAY-RATE only)RVALS O REAL*8 NSTAGE Property valuesUTYPE O CHARACTER*12 — Units typeLABEL O CHARACTER*16 — Units labelIERR O INTEGER — Error flag (0=No error)† I = Input to subroutine

O = Output from subroutine

Column SectionProfiles

4-46 •••• Block Result Subroutines Aspen Plus 11.1 Summary File Toolkit

Reactor ResultsYou can retrieve reactor profile results from the summary file forthe reactor models RPlug and RBatch. You can also retrieve thevent accumulator and vent profile results for the RBatch model.(See RBatch Vent Accumulator Results, and RBatch Vent ProfileResults, this chapter.) You can retrieve reaction data for theRStoic, REquil and RGibbs models. (See Reaction Data, thischapter.) Retrieving reactor profile results is a four-step process:1 Call subroutine TKRSUB to determine the number of

substreams.2 Call subroutine TKRPRF to determine the dimensions of the

profile.3 Call subroutine TKRPRP to list the properties.4 Retrieve the property values. Call subroutine TKRPR1 for

non-component-dependent properties. Call subroutineTKRPR2 for component-dependent properties.

Call subroutines TKRNAC, TKRNCA, TKRSCA, and TKRCATto retrieve the property values for the component attributes of asolid substream. Call subroutines TKRNFS and TKRFSP toretrieve the property values for the continuous feed stream to theRBatch block.

Call subroutine TKRSUB to determine the number of substreamsin a block modeled using the rigorous reactor models RBatch andRPlug. All other models return a value of 0.

Calling Sequence for TKRSUBCALL TKRSUB (BLKID, NSUB)

Argument List Descriptions for TKRSUBVariable I/O † Type Dimension Description

BLKID I CHARACTER*(*) — Block IDNSUB O INTEGER — Number of substreams† I = Input to subroutine

O = Output from subroutine

Number of ReactorSubstreams

Aspen Plus 11.1 Summary File Toolkit Block Result Subroutines •••• 4-47

Call subroutine TKRPRF to determine the sizes of the reactorprofile arrays for the specified substream. TKRPRF returns the:• Substream ID for the requested substream• Number of output points• Number of components present• Number of properties

Calling Sequence for TKRPRFCALL TKRPRF (BLKID, ISUB, SUBSID, NPOINT, NCP,

NPROP)

Argument List Descriptions for TKRPRFVariable I/O † Type Dimension Description

BLKID I CHARACTER*(*) — Block IDISUB I INTEGER — Substream numberSUBSID O CHARACTER*8 — Substream IDNPOINT O INTEGER — Number of output pointsNCP O INTEGER — Number of components

presentNPROP O INTEGER — Number of properties† I = Input to subroutine

O = Output from subroutine

Call subroutine TKRPRP to list the reactor profile properties for aspecified substream. TKRPRP returns an array of property names.TKRPRP also returns the array ITYPES, which indicates whetherthe property is component-dependent, not component-dependent, acomponent attribute, or a continuous feed stream property.

Calling Sequence for TKRPRPCALL TKRPRP (BLKID, SUBSID, NPROP, ITYPES,

PNAMES, IERR)

Argument List Descriptions for TKRPRPVariable I/O † Type Dimension Description

BLKID I CHARACTER*(*) — Block IDSUBSID I CHARACTER*8 — Substream IDNPROP I INTEGER — Number of propertiesITYPES O INTEGER NPROP Property type:

1=Non-component-dependent2=Component-dependent3=Component attributes4=Continuous feed streamproperty

Reactor ProfileDimensions

Reactor ProfileProperties

4-48 •••• Block Result Subroutines Aspen Plus 11.1 Summary File Toolkit

Variable I/O † Type Dimension Description

PNAMES O CHARACTER*12 NPROP Property name. See Chapter11 for a description.

IERR O INTEGER — Error flag (0=No error)† I = Input to subroutine

O = Output from subroutine

Call subroutine TKRPR1 to retrieve reactor profiles for non-component-dependent properties.

Calling Sequence for TKRPR1CALL TKRPR1 (BLKID, PNAME, SUBSID, NPOINT,

RVALS, TYPE, LABEL, IERR)

Argument List Descriptions for TKRPR1Variable I/O † Type Dimension Description

BLKID I CHARACTER*(*) — Block IDPNAME I CHARACTER*12 — Property name from

TKRPRPSUBSID I CHARACTER*8 — Substream IDNPOINT I INTEGER — Number of output

pointsRVALS O REAL*8 NPOINT Property valuesTYPE O CHARACTER*12 — Units typeLABEL O CHARACTER*16 — Units labelIERR O INTEGER — Error flag (0=No error)† I = Input to subroutine

O = Output from subroutine

Call subroutine TKRPR2 to retrieve reactor profiles forcomponent-dependent properties. The results are returned in theRVALS array, with all the component data for a point storedconsecutively.

Calling Sequence for TKRPR2CALL TKRPR2 (BLKID, PNAME, SUBSID, NCP, COMPID,

NPOINT, RVALS, TYPE, LABEL, IERR)

Argument List Descriptions for TKRPR2Variable I/O † Type Dimension Description

BLKID I CHARACTER*(*) — Block IDPNAME I CHARACTER*12 — Property name from TKRPRPSUBSID I CHARACTER*8 — Substream ID

Non-Component-Dependent ReactorProfiles

Component-Dependent ReactorProfiles

Aspen Plus 11.1 Summary File Toolkit Block Result Subroutines •••• 4-49

Variable I/O † Type Dimension Description

NCP I INTEGER — Number of components presentCOMPID O CHARACTER*8 NCP Component IDsNPOINT I INTEGER — Number of output pointsRVALS O REAL*8 NCP*

NPOINTProperty values

TYPE O CHARACTER*12 — Units typeLABEL O CHARACTER*16 — Units labelIERR O INTEGER — Error flag (0=No error)† I = Input to subroutine

O = Output from subroutine

Call subroutine TKRNAC to retrieve the number of componentsthat are reported for the component attribute property.

Calling Sequence for TKRNACCALL TKRNAC (BLKID, SUBSID, NCP)

Argument List Descriptions for TKRNACVariable I/O † Type Dimension Description

BLKID I CHARACTER*(*) — Block IDSUBSID I CHARACTER*8 — Substream IDNCP O INTEGER — Number of components† I = Input to subroutine

O = Output from subroutine

Call subroutine TKRNCA to determine the number of attributes aproperty has for a specified component. The component isspecified by supplying the sequence number of the component (forexample, 1 for the first component). The corresponding componentID is returned.

Calling Sequence for TKRNCACALL TKRNCA (BLKID, SUBSID, ICP, COMPID, NATT)

Argument List Descriptions for TKRNCAVariable I/O † Type Dimension Description

BLKID I CHARACTER*(*) — Block IDSUBSID I CHARACTER*8 — Substream IDICP I INTEGER — Component sequence

numberCOMPID O CHARACTER*8 — Component ID

Number ofComponents withComponent AttributeResults

Number of Attributesfor a Component

4-50 •••• Block Result Subroutines Aspen Plus 11.1 Summary File Toolkit

NATT O INTEGER — Number of attributes† I = Input to subroutine

O = Output from subroutine

Call subroutine TKRSCA to retrieve the number of elements thecomponent attribute has. The component attribute is specified bysupplying the sequence number of the component attribute (forexample, 1 for the first attribute). The corresponding componentattribute ID is returned.

Calling Sequence for TKRSCACALL TKRSCA (BLKID, SUBSID, COMPID, IDSEQ,

IDATT, NELEM)

Argument List Descriptions For TKRSCAVariable I/O † Type Dimension Description

BLKID I CHARACTER*(*) — Block IDSUBSID I CHARACTER*8 — Substream IDCOMPID I CHARACTER*8 — Component IDIDSEQ I INTEGER — Sequence number of

attributeIDATT O CHARACTER*8 — Attribute IDNELEM O INTEGER — Number of elements† I = Input to subroutine

O = Output from subroutine

Call subroutine TKRCAT to retrieve the results for all the elementsof a specified component attribute. (The results are returned in theRVALS array with all the data for a point stored consecutively.)The names of the elements are also returned.

Calling Sequence for TKRCATCALL TKRCAT (BLKID, SUBSID, COMPID, IDATT,

NELEM, NPOINT, ELEMID, RVALS, IERR)

Argument List Descriptions For TKRCATVariable I/O † Type Dimension Description

BLKID I CHARACTER*(*) — Block IDSUBSID I CHARACTER*8 — Substream IDCOMPID I CHARACTER*8 — Component IDIDATT I CHARACTER*8 — Attribute IDNELEM I INTEGER — Number of elementsNPOINT I INTEGER — Number of points

Details of aComponent Attribute

Component AttributeResults

Aspen Plus 11.1 Summary File Toolkit Block Result Subroutines •••• 4-51

Variable I/O † Type Dimension Description

ELEMID O CHARACTER*8 NELEM Element namesRVALS O REAL*8 NELEM*

POINTProperty values

IERR O INTEGER — Error flag (0=No error)† I = Input to subroutine

O = Output from subroutine

Call subroutine TKRNFS to determine the number of continuousfeed streams to an RBatch block. This number is used for thecontinuous feed stream properties.

Calling Sequence for TKRNFSCALL TKRNFS (BLKID, SUBSID, NFS)

Argument List Descriptions For TKRNFSVariable I/O † Type Dimension Description

BLKID I CHARACTER*(*) — Block IDSUBSID I CHARACTER*8 — Substream IDNFS O INTEGER — Number of continuous

feed streams† I = Input to subroutine

O = Output from subroutine

Call subroutine TKRFSP to retrieve the results for a continuousfeed stream to an RBatch block. The continuous feed streamnumber is specified (for example, 1 for the first stream). The nameof this stream and the property results are returned.

Calling Sequence for TKRFSPCALL TKRSFP (BLKID, SUBSID, IFEED, IDFEED,

PNAME, NPOINT, RVALS, TYPE, LABEL,IERR)

Argument List Descriptions For TKRFSPVariable I/O † Type Dimension Description

BLKID I CHARACTER*(*) — Block IDSUBSID I CHARACTER*8 — Substream IDIFEED I INTEGER — Feed stream numberIDFEED O CHARACTER*8 — Continuous feed stream IDPNAME I CHARACTER*12 — Property name from

TKRPRPNPOINT I INTEGER — Number of points

Number ofContinuous FeedStreams

Continuous FeedStream Results

4-52 •••• Block Result Subroutines Aspen Plus 11.1 Summary File Toolkit

Variable I/O † Type Dimension Description

RVALS O REAL*8 NPOINT Property valuesTYPE O CHARACTER*12 — Units typeLABEL O CHARACTER*16 — Units labelIERR O INTEGER — Error flag (0=No error)† I = Input to subroutine

O = Output from subroutine

Retrieving the vent accumulator profiles for the RBatch modelrequires three additional steps:1 Call subroutine TKVAPF to determine the dimensions of the

profile.2 Call subroutine TKVAPR to list the properties.3 Call subroutine TKVAR1 to retrieve the property values for

non-component-dependent properties, or subroutineTKVAR2 to retrieve the property values forcomponent-dependent properties.

Call subroutine TKVAPF to determine the sizes of profile arraysfor the vent accumulator. TKVAPF returns the number of:• Output points• Components present• Properties

Calling Sequence for TKVAPFCALL TKVAPF (BLKID, NPOINT, NCP, NPROP)

Argument List Descriptions for TKVAPFVariable I/O † Type Dimension Description

BLKID I CHARACTER*(*) — Block IDNPOINT O INTEGER — Number of output

pointsNCP O INTEGER — Number of components

presentNPROP O INTEGER — Number of properties† I = Input to subroutine

O = Output from subroutine

RBATCH VentAccumulator Results

Vent Accumulator ProfileDimensions

Aspen Plus 11.1 Summary File Toolkit Block Result Subroutines •••• 4-53

Call subroutine TKVAPR to list the RBatch vent accumulatorprofile properties. TKVAPR returns an array of property names,and an array indicating whether or not the property is component-dependent.

Calling Sequence for TKVAPRCALL TKVAPR (BLKID, NPROP, ITYPES, PNAMES,

IERR)

Argument List Descriptions for TKVAPRVariable I/O † Type Dimension Description

BLKID I CHARACTER*(*) — Block IDNPROP I INTEGER — Number of propertiesITYPES O INTEGER NPROP Property type:

1=Non-component-dependent2=Component-dependent

PNAMES O CHARACTER*12 NPROP Property name. SeeChapter 11 for adescription.

IERR O INTEGER — Error flag (0=No error)† I = Input to subroutine

O = Output from subroutine

Call subroutine TKVAR1 to retrieve RBatch vent accumulatorprofiles for non-component-dependent properties.

Calling Sequence for TKVAR1CALL TKVAR1 (BLKID, PNAME, NPOINT, RVALS, TYPE,

LABEL, IERR)

Argument List Descriptions for TKVAR1Variable I/O † Type Dimension Description

BLKID I CHARACTER*(*) — Block IDPNAME I CHARACTER*12 — Property name from

TKVAPRNPOINT I INTEGER — Number of output pointsRVALS O REAL*8 NPOINT Property valuesTYPE O CHARACTER*12 — Units typeLABEL O CHARACTER*16 — Units labelIERR O INTEGER — Error flag (0=No error)† I = Input to subroutine

O = Output from subroutine

Vent Accumulator ProfileProperties

Non-Component-Dependent VentAccumulator Profiles

4-54 •••• Block Result Subroutines Aspen Plus 11.1 Summary File Toolkit

Call subroutine TKVAR2 to retrieve RBatch vent accumulatorprofiles for component-dependent properties.

Calling Sequence for TKVAR2CALL TKVAR2 (BLKID, PNAME, NCP, COMPID, NPOINT,

RVALS, TYPE, LABEL, IERR)

Argument List Descriptions for TKVAR2Variable I/O † Type Dimension Description

BLKID I CHARACTER*(*) — Block IDPNAME I CHARACTER*12 — Property name from TKVAPRNCP I INTEGER — Number of components presentCOMPID O CHARACTER*8 NCP Component IDsNPOINT I INTEGER — Number of output pointsRVALS O REAL*8 NCP*

NPOINTProperty values

TYPE O CHARACTER*12 — Units typeLABEL O CHARACTER*16 — Units labelIERR O INTEGER — Error flag (0=No error)† I = Input to subroutine

O = Output from subroutine

Retrieving the vent profiles for the RBatch model requires threesteps:1 Call subroutine TKVTPF to determine the dimensions of the

profile.2 Call subroutine TKVTPR to list the properties.3 Call subroutine TKVTR1 to retrieve the property values for

non-component-dependent properties, or subroutine TKVTR2to retrieve the property values for component-dependentproperties.

Component-DependentVent AccumulatorProfiles

RBatch Vent ProfileResults

Aspen Plus 11.1 Summary File Toolkit Block Result Subroutines •••• 4-55

Call subroutine TKVTPF to determine the sizes of the profilearrays for the vent. TKVTPF returns the number of:• Output points• Components present• Properties

Calling Sequence for TKVTPFCALL TKVTPF (BLKID, NPOINT, NCP, NPROP)

Argument List Descriptions for TKVTPFVariable I/O † Type Dimension Description

BLKID I CHARACTER*(*) — Block IDNPOINT O INTEGER — Number of output pointsNCP O INTEGER — Number of components

presentNPROP O INTEGER — Number of properties† I = Input to subroutine

O = Output from subroutine

Call subroutine TKVTPR to list the RBatch vent profile properties.TKVTPR returns an array of property names, and an arrayindicating whether or not the property is component-dependent.

Calling Sequence for TKVTPRCALL TKVTPR (BLKID, NPROP, ITYPES, PNAMES,

IERR)

Argument List Descriptions for TKVTPRVariable I/O † Type Dimension Description

BLKID I CHARACTER*(*) — Block IDNPROP I INTEGER — Number of propertiesITYPES O INTEGER NPROP Property type

(1=Non-component-dependent,2=Component-dependent)

PNAMES O CHARACTER*12 NPROP Property name. SeeChapter 11 for adescription.

IERR O INTEGER — Error flag (0=No error)† I = Input to subroutine

O = Output from subroutine

Vent Profile Dimensions

Vent Profile Properties

4-56 •••• Block Result Subroutines Aspen Plus 11.1 Summary File Toolkit

Call subroutine TKVTR1 to retrieve RBatch vent profiles for non-component-dependent properties.

Calling Sequence for TKVTR1CALL TKVTR1 (BLKID, PNAME, NPOINT, RVALS, TYPE,

LABEL, IERR)

Argument List Descriptions for TKVTR1Variable I/O † Type Dimension Description

BLKID I CHARACTER*(*) — Block IDPNAME I CHARACTER*12 — Property name from

TKVTPRNPOINT I INTEGER — Number of output pointsRVALS O REAL*8 NPOINT Property valuesTYPE O CHARACTER*12 — Units typeLABEL O CHARACTER*16 — Units labelIERR O INTEGER — Error flag (0=No error)† I = Input to subroutine

O = Output from subroutine

Call subroutine TKVTR2 to retrieve RBatch vent profiles forcomponent-dependent properties.

Calling Sequence for TKVTR2CALL TKVTR2 (BLKID, PNAME, NCP, COMPID, NPOINT,

RVALS, TYPE, LABEL, IERR)

Argument List Descriptions for TKVTR2Variable I/O † Type Dimension Description

BLKID I CHARACTER*(*) — Block IDPNAME I CHARACTER*12 — Property name from TKVTPRNCP I INTEGER — Number of components presentCOMPID O CHARACTER*8 NCP Component IDsNPOINT I INTEGER — Number of output pointsRVALS O REAL*8 NCP*

NPOINTProperty values

TYPE O CHARACTER*12 — Units typeLABEL O CHARACTER*16 — Units labelIERR O INTEGER — Error flag (0=No error)† I = Input to subroutine

O = Output from subroutine

Non-Component-Dependent Vent Profiles

Component-DependentVent Profiles

Aspen Plus 11.1 Summary File Toolkit Block Result Subroutines •••• 4-57

You can retrieve the reaction equilibrium constants for eachreaction in the REquil and RGibbs models. For the RStoic modelyou can retrieve the reaction extent and the heat of reaction foreach reaction. You can also retrieve the component selectivity forRStoic. You can retrieve reaction data using a three-step process:1 Call subroutine TKRRPF to determine the number of

reactions.2 Call subroutine TKRRPR to retrieve the equilibrium

constants or reaction data.3 Call subroutine TKRRHR to retrieve the heat of reaction data

for RStoic.Use these additional two steps to retrieve the component selectivityresults:4 Call subroutine TKRRNS to determine the number of

selectivity results.5 Call subroutine TKRRSL to retrieve the component

selectivity results.Call subroutine TKRRPF to determine the number of reactions inthe REquil, RGibbs, and RStoic models.

Calling Sequence for TKRRPFCALL TKRRPF (BLKID, NREAC)

Argument List Descriptions for TKRRPFVariable I/O

†Type Dimension Description

BLKID I CHARACTER*(*) — Block IDNREAC O INTEGER — Number of reactions† I = Input to subroutine

O = Output from subroutine

Call subroutine TKRRPR to retrieve the reaction results. TKRRPRreturns a single property, equilibrium constant for REquil andRGibbs models, and reaction extent for RStoic models. SpecifyNPROP as 1.

Calling Sequence for TKRRPRCALL TKRRPR (BLKID, NPROP, NREAC, PNAMES,

RVALS, TYPES, LABELS, IERR)

Argument List Descriptions for TKRRPRVariable I/O

†Type Dimension Description

BLKID I CHARACTER*(*) — Block IDNPROP I INTEGER — Use NPROP = 1

Number of properties

Reaction Data

Number of Reactions

Reaction Results

4-58 •••• Block Result Subroutines Aspen Plus 11.1 Summary File Toolkit

Variable I/O †

Type Dimension Description

NREAC I INTEGER — Number of reactionsPNAMES O CHARACTER*12 NPROP Property name. See

Chapter 11 for adescription.

RVALS O REAL*8 NPROP*NREAC

Real results

TYPES O CHARACTER*12 NPROP Units typeLABELS O CHARACTER*16 NPROP Units labelIERR O INTEGER — Error flag (0=No error)† I = Input to subroutine

O = Output from subroutine

Call subroutine TKRRHR to retrieve the heats of reaction resultsfor RStoic models. The heat of reaction and the ID of the referencecomponent in the reaction are returned for each reaction.

Calling Sequence for TKRRHRCALL TKRRHR (BLKID, NREAC, COMPID, RVALS, TYPE,

LABEL, IERR)

Argument List Descriptions for TKRRHRVariable I/O

†Type Dimension Description

BLKID I CHARACTER*(*) — Block IDNREAC I INTEGER — Number of reactionsCOMPID O CHARACTER*12 NREAC Reference component IDRVALS O REAL*8 NREAC Real resultsTYPE O CHARACTER*12 — Units typeLABEL O CHARACTER*16 — Units labelIERR O INTEGER — Error flag (0=No error)† I = Input to subroutine

O = Output from subroutine

Call subroutine TKRRNS to determine the number of componentselectivity specifications given for the RStoic model.

Calling Sequence for TKRRNSCALL TKRRNS (BLKID, NSEL)

Argument List Descriptions for TKRRNSVariable I/O

†Type Dimension Description

BLKID I CHARACTER*(*) — Block IDNSEL O INTEGER — Number of selectivity

specifications† I = Input to subroutine

O = Output from subroutine

Heats of Reaction

Number of SelectivityResults

Aspen Plus 11.1 Summary File Toolkit Block Result Subroutines •••• 4-59

Call subroutine TKRRSL to retrieve the results of each componentselectivity specification. The reference/reactant component andproduct component, together with their substreams, are returnedwith the result for each selectivity specification.

Calling Sequence for TKRRSLCALL TKRRSL (BLKID, NSEL, PCOMPS, PSUBS,

RCOMPS, RSUBS, RVALS, IERR)

Argument List Descriptions for TKRRSLVariable I/O

†Type Dimension Description

BLKID I CHARACTER*(*) — Block IDNSEL I INTEGER — Number of selectivity

specificationsPCOMPS O CHARACTER*8 NSEL Product componentPSUBS O CHARACTER*8 NSEL Product component

substreamRCOMPS O CHARACTER*8 NSEL Reference component

(reactant)RSUBS O CHARACTER*8 NSEL Reference component

substreamRVALS O REAL*8 NSEL Component selectivityIERR O INTEGER — Error flag (0=No error)† I = Input to subroutine

O = Output from subroutine

Reactor Property ReportsReactor report results are calculated in Aspen Plus when thePROP-REPORT option is used with the RPlug or RBatch models.The RBatch model allows you to choose the property report for thereactor, accumulator, or vent.You can retrieve each type of reactor property report using a three-tep process:1 Call TKLRRP to determine the number and types of reports

available for the reactor.2 Call TKSRRP to determine the size of a reactor report.3 Call TKNRRP to retrieve the next property set property

calculated for a reactor property report, or call TKRRRP toretrieve a specific property.

Reactor ComponentSelectivity Results

4-60 •••• Block Result Subroutines Aspen Plus 11.1 Summary File Toolkit

The possible types of reports are:Type of report For

PROP-REACTOR RBatch ReactorPROP-ACCUM RBatch Vent accumulatorPROP-VENT RBatch VentPROP-REPORT RPlug Reactor

Call subroutine TKLRRP to determine the number and types ofreport available for the reactor.

Calling Sequence for TKLRRPCALL TKLRRP (BLKID, NRPRT, TYPES, IERR)

Argument List Descriptions for TKLRRPVariable I/O † Type Dimension Description

BLKID I CHARACTER*(*) — Block IDNRPRT O INTEGER — Number of reactor

property reportsTYPES O CHARACTER*12 3 Types of property reports

(see above)IERR O INTEGER — Error flag (0=No error)† I = Input to subroutine

O = Output from subroutine

Call subroutine TKSRRP to determine the size of the reactorproperty report. TKSRRP returns the number of points in thereport and the number of property sets calculated.

Calling Sequence for TKSRRPCALL TKSRRP (BLKID, TYPE, NPOINT, NPROP, IERR)

Argument List Descriptions for TKSRRPVariable I/O † Type Dimension Description

BLKID I CHARACTER*(*) — Block IDTYPE I CHARACTER*12 — Type of property report

(see above)NPOINT O INTEGER — Number of pointsNPROP O INTEGER — Number of propertiesIERR O INTEGER — Error flag (0=No error)† I = Input to subroutine

O = Output from subroutine

Number of Reportsfor a Reactor Block

Size of a ReactorProperty Report

Aspen Plus 11.1 Summary File Toolkit Block Result Subroutines •••• 4-61

Call subroutine TKNRRP to retrieve the next property setcalculated for a reactor property report. Use the property sequencenumber to identify the property. TKNRRP returns the property setqualifiers, the property values, and the units type and label.

Calling Sequence for TKNRRPCALL TKNRRP (BLKID, TYPE, NPOINT, IPROP,

PNAME, SUBSID, PHASE, COMPID,WETDRY, BASIS, RVALS, UTYPE, LABEL,IERR)

Argument List Descriptions for TKNRRPVariable I/O † Type Dimension Description

BLKID I CHARACTER*(*) — Block IDTYPE I CHARACTER*12 — Type of property report

(see above)NPOINT I INTEGER — Number of pointsIPROP I INTEGER — Property sequence numberPNAME O CHARACTER*12 — Property name. See

Chapter 11 for adescription.

SUBSID O CHARACTER*8 — Substream IDPHASE O CHARACTER*8 — PhaseCOMPID O CHARACTER*8 — Component IDWETDRY O CHARACTER*4 — Wet/dry basis ††

BASIS O CHARACTER*4 — Units basis (MOLE,MASS, or FLOW)

RVALS O REAL*8 NPOINT Property valuesUTYPE O CHARACTER*12 — Units typeLABEL O CHARACTER*16 — Units labelIERR O INTEGER — Error flag (0=No error)† I = Input to subroutine

O = Output from subroutine†† Can be left unspecified

Sequential ReactorReport Properties

4-62 •••• Block Result Subroutines Aspen Plus 11.1 Summary File Toolkit

Call subroutine TKRRRP to retrieve a specific property from areactor property report. The property is identified by specifying theproperty set qualifiers (PNAME, SUBSID, PHASE, COMPID,WETDRY, BASIS). TKRRRP returns the property values, theunits type, and the units label.

Calling Sequence for TKRRRPCALL TKRRRP (BLKID, TYPE, NPOINT, PNAME, SUBSID,

PHASE, COMPID, WETDRY, BASIS, RVALS,UTYPE, LABEL, IERR)

Argument List Descriptions for TKRRRPVariable I/O † Type Dimension Description

BLKID I CHARACTER*(*) — Block IDTYPE I CHARACTER*12 — Type of property report

(see above)NPOINT I INTEGER — Number of pointsPNAME I CHARACTER*12 — Property name. See

Chapter 11 for a list ofvalid property names.

SUBSID I CHARACTER*8 — Substream IDPHASE I CHARACTER*8 — PhaseCOMPID I CHARACTER*8 — Component IDWETDRY I CHARACTER*4 — Wet/dry basis

(WET or DRY)††

BASIS I CHARACTER*4 — Units basisRVALS O REAL*8 NPOINT Property valuesUTYPE O CHARACTER*12 — Units typeLABEL O CHARACTER*16 — Units labelIERR O INTEGER — Error flag

(0=No error)† I = Input to subroutine

O = Output from subroutine†† Can be left unspecified.

Specific ReactorReport Properties

Aspen Plus 11.1 Summary File Toolkit Block Result Subroutines •••• 4-63

Pipeline ResultsYou can retrieve all the pipeline model results with the toolkit.Retrieve block results using the standard block result routineTKBRES. Retrieve other results using the routines described inthis section.Retrieving all the additional pipeline results is a ten-step process:1 Call subroutine TKPLSZ to retrieve the dimensions of the

pipeline results.2 Call subroutine TKPLIO to retrieve the inlet and outlet

conditions.3 Call subroutine TKPLCP to retrieve the inlet and outlet

property names for components in a pipeline.4 Call subroutine TKPLCO to retrieve the inlet and outlet

conditions for components in a pipeline.5 Call subroutine TKPLSP to retrieve the segment data property

names.6 Call subroutine TKPLSG to retrieve the segment data.7 Call subroutine TKPLNP to retrieve the node property names.8 Call subroutine TKPLND to retrieve the node results.9 Call subroutine TKPLPP to retrieve the pipeline profile

property names.10 Call subroutine TKPLPR to retrieve the pipeline profile data.

Call subroutine TKPLSZ to retrieve the dimensions of the pipelineresults. TKPLSZ returns the number of each type of pipelineresults.

Calling Sequence for TKPLSZCALL TKPLSZ (BLKID, NIORES, NCC, NCCPRP, NSEG,

NSGPRP, NNODE, NNDPRP, NPOINT,NPROF, IERR)

Argument List Descriptions for TKPLSZVariable I/O † Type Dimension Description

BLKID I CHARACTER*(*) — Block IDNIORES O INTEGER — Number of inlet/outlet condition

resultsNCC O INTEGER — Number of components presentNCCPRP O INTEGER — Number of component propertiesNSEG O INTEGER — Number of pipeline segmentsNSGPRP O INTEGER — Number of segment properties

Pipeline ResultsDimensions

4-64 •••• Block Result Subroutines Aspen Plus 11.1 Summary File Toolkit

Variable I/O † Type Dimension Description

NNODE O INTEGER — Number of pipeline nodesNNDPRP O INTEGER — Number of node propertiesNPOINT O INTEGER — Number of pipeline profile pointsNPROF O INTEGER — Number of profile propertiesIERR O INTEGER — Error flag (0=No error)† I = Input to subroutine

O = Output from subroutine

Call subroutine TKPLIO to retrieve the results for the inlet andoutlet conditions of a pipeline. The inlet and outlet results share thesame property name, units type and label. The type of the result isindicated in the ITYPES array.

Calling Sequence for TKPLIOCALL TKPLIO (BLKID, NIORES, PNAMES, ITYPES,

CVALSI, CVALSO, RVALSI, RVALSO,TYPES, LABELS, IERR)

Argument List Descriptions for TKPLIOVariable I/O † Type Dimension Description

BLKID I CHARACTER*(*) — Block IDNIORES I INTEGER — Number of resultsPNAMES O CHARACTER*12 NIORES Property name. See

Chapter 11 for adescription.

ITYPES O INTEGER NIORES Data type of results(2=Real, 3=Character)

CVALSI O CHARACTER*12 NIORES Inlet character resultsCVALSO O CHARACTER*12 NIORES Outlet character resultsRVALSI O REAL*8 NIORES Inlet real resultsRVALSO O REAL*8 NIORES Outlet real resultsTYPES O CHARACTER*12 NIORES Units typesLABELS O CHARACTER*16 NIORES Units labelsIERR O INTEGER — Error flag (0=No error)† I = Input to subroutine

O = Output from subroutine

Non-Component-Dependent PipelineInlet and OutletConditions

Aspen Plus 11.1 Summary File Toolkit Block Result Subroutines •••• 4-65

Call subroutine TKPLCP to retrieve the names of the component-dependent properties of the pipeline.

Calling Sequence for TKPLCPCALL TKPLCP (BLKID, NCCPRP, PNAMES, IERR)

Argument List Descriptions for TKPLCPVariable I/O † Type Dimension Description

BLKID I CHARACTER*(*) — Block IDNCCPRP I INTEGER — Number of component

propertiesPNAMES O CHARACTER*12 NCCPRP Property name. See

Chapter 11 for adescription.

IERR O INTEGER — Error flag (0=No error)† I = Input to subroutine

O = Output from subroutine

Call subroutine TKPLCO to retrieve the results for a specifiedcomponent-dependent property in the pipeline. The inlet and outletresults share the same property name, units type and label.

Calling Sequence for TKPLCOCALL TKPLCO (BLKID, NCC, PNAME, RVALSI, RVALSO,

TYPE, LABEL, IERR)

Argument List Descriptions for TKPLCOVariable I/O † Type Dimension Description

BLKID I CHARACTER*(*) — Block IDNCC I INTEGER — Number of

componentsPNAME I CHARACTER*12 — Property name from

TKPLCPRVALSI O REAL*8 NCC Inlet resultsRVALSO O REAL*8 NCC Outlet resultsTYPE O INTEGER*12 — Units typeLABEL O CHARACTER*16 — Units labelIERR O INTEGER — Error flag (0=No error)† I = Input to subroutine

O = Output from subroutine

Component-Dependent PipelineInlet and OutletProperty Names

Component-Dependent PipelineInlet and OutletConditions

4-66 •••• Block Result Subroutines Aspen Plus 11.1 Summary File Toolkit

Call TKPLSP to retrieve a list of the names of the propertiesreported for pipeline segments.

Calling Sequence for TKPLSPCALL TKPLSP (BLKID, NSGPRP, PNAMES, IERR)

Argument List Descriptions for TKPLSPVariable I/O † Type Dimension Description

BLKID I CHARACTER*(*) — Block IDNSGPRP I INTEGER — Number of segmentsPNAMES O CHARACTER*12 NSGPRP Property name. See

Chapter 11 for adescription.

IERR O INTEGER — Error flag (0=No error)† I = Input to subroutine

O = Output from subroutine

Call subroutine TKPLSG to retrieve segment data for the specifiedproperty name. The result will be either a character or a real value,indicated by the value of ITYPE.

Calling Sequence for TKPLSGCALL TKPLSG (BLKID, NSEG, PNAME, ITYPE, RVALS,

CVALS, TYPE, LABEL, IERR)

Argument List Descriptions for TKPLSGVariable I/O † Type Dimension Description

BLKID I CHARACTER*(*) — Block IDNSEG I INTEGER — Number of pipeline

segmentsPNAME I CHARACTER*12 — Property name from

TKPLSPITYPE O INTEGER — Data type of results

(2=Real, 3=Character) ††

RVALS O REAL*8 NSEG Real resultsCVALS O CHARACTER*12 NSEG Character resultsTYPE O CHARACTER*12 — Units typeLABEL O CHARACTER*16 — Units labelIERR O INTEGER — Error flag (0=No error)† I = Input to subroutine

O = Output from subroutine†† For each result, the value in ITYPE specifies which array contains the

result (CVALS or RVALS). For example, if ITYPE(4) is 2, then CVALS(4) isblank and RVALS(4) contains the result.

Segment DataProperty Names

Pipeline SegmentData

Aspen Plus 11.1 Summary File Toolkit Block Result Subroutines •••• 4-67

Call TKPLNP to retrieve a list of the reported property names for apipeline node.

Calling Sequence for TKPLNPCALL TKPLNP (BLKID, NNDPRP, PNAMES, IERR)

Argument List Descriptions for TKPLNPVariable I/O † Type Dimension Description

BLKID I CHARACTER*(*) — Block IDNNDPRP I INTEGER — Number of node

propertiesPNAMES O CHARACTER*12 NNDPRP Property name. See

Chapter 11 for adescription.

IERR O INTEGER — Error flag (0=No error)† I = Input to subroutine

O = Output from subroutine

Call subroutine TKPLND to retrieve the node results for thespecific property. The type of result is indicated by ITYPE.

Calling Sequence for TKPLNDCALL TKPLND (BLKID, NNODE, PNAME, ITYPE, RVALS,

CVALS, TYPE, LABEL, IERR)

Argument List Descriptions for TKPLNDVariable I/O † Type Dimension Description

BLKID I CHARACTER*(*) — Block IDNNODE I INTEGER — Number of nodesPNAME I CHARACTER*12 — Property name from

TKPLNPITYPE O INTEGER — Data type of results

(2=Real, 3=Character) ††

RVALS O REAL*8 NNODE Segment resultsCVALS O CHARACTER*12 NNODE Character segment

resultsTYPE O CHARACTER*12 — Units typeLABEL O CHARACTER*16 — Units labelIERR O INTEGER — Error flag (0=No error)† I = Input to subroutine

O = Output from subroutine†† For each result, the value in ITYPE specifies which array contains the

result (CVALS or RVALS). For example, if ITYPE(4) is 2, then CVALS(4) isblank and RVALS(4) contains the result.

Pipeline NodeProperty Names

Pipeline NodeResults

4-68 •••• Block Result Subroutines Aspen Plus 11.1 Summary File Toolkit

Call subroutine TKPLPP to retrieve the names of the properties inthe pipeline fluid profile. Since not all pipelines have this profile,make sure that NPROF is greater than zero before calling thisroutine. TKPLPP will return an error in IERR if NPROF is zero.

Calling Sequence for TKPLPPCALL TKPLPP (BLKID, NPROF, PNAMES, IERR)

Argument List Descriptions for TKPLPPVariable I/O † Type Dimension Description

BLKID I CHARACTER*(*) — Block IDNPROF I INTEGER — Number of profile

propertiesPNAMES O CHARACTER*12 NPROF Property name. See

Chapter 11 for adescription.

IERR O INTEGER — Error flag (0=No error)† I = Input to subroutine

O = Output from subroutine

Call subroutine TKPLPR to retrieve the pipeline profile results forthe named property. Since not all pipelines have this profile, makesure that NPOINT is greater than zero before calling this routine.TKPLPR will return an error in IERR if NPOINT is zero.

Calling Sequence for TKPLPRCALL TKPLPR (BLKID, NPOINT, PNAME, RVALS, TYPE,

LABEL, IERR)

Argument List Descriptions for TKPLPRVariable I/O † Type Dimension Description

BLKID I CHARACTER*(*) — Block IDNPOINT I INTEGER — Number of profile pointsPNAME I CHARACTER*12 — Property name from

TKPLPPRVALS O REAL*8 NPOINT Profile resultsTYPE O CHARACTER*12 — Units typeLABEL O CHARACTER*16 — Units labelIERR O INTEGER — Error flag (0=No error)† I = Input to subroutine

O = Output from subroutine

Pipeline ProfileProperty Names

Pipeline ProfileResults

Aspen Plus 11.1 Summary File Toolkit Block Result Subroutines •••• 4-69

Pipe ResultsYou can retrieve all the results for the single-segment pipelinemodel Pipe, using the standard block results routines TKNRES andTKBRES. Retrieve other results using the routines described inthis section.You can retrieve Pipe results using a six-step process:1 Call subroutine TKPISP to retrieve the dimensions of the

standard profiles.2 Call subroutine TKPINP to retrieve the names of the standard

profile properties.3 Call subroutine TKPIPR to retrieve results for standard

profile properties.4 Call subroutine TKPLSZ to retrieve the number of fluid

properties. For a description of TKPLSZ, see Pipeline ResultsDimensions, this chapter.

5 Call subroutine TKPLPP to retrieve the names of the fluidproperties. For a description of TKPLPP, see Pipeline ProfileProperty Names, this chapter.

6 Call subroutine TKPLPR to retrieve the fluid propertiesresults. For a description of TKPLPR, see Pipeline ProfileResults, this chapter.

Call subroutine TKPISP to retrieve the dimensions of the standardPipe profiles results. NPOINT returns zero if there are no profileresults for this block. TKPISP returns the number of:• Profile points• Profile properties

Calling Sequence for TKPISPCALL TKPISP (BLKID, NPOINT, NPROP)

Argument List Descriptions for TKPISPVariable I/O † Type Dimension Description

BLKID I CHARACTER*(*) — Block IDNPOINT O INTEGER — Number of profile pointsNPROP O INTEGER — Number of profile

properties† I = Input to subroutine

O = Output from subroutine

Pipe Standard ProfileDimensions

4-70 •••• Block Result Subroutines Aspen Plus 11.1 Summary File Toolkit

Call subroutine TKPINP to retrieve the names of the properties inthe standard Pipe profiles results.

Calling Sequence for TKPINPCALL TKPINP (BLKID, NPROP, PNAMES, IERR)

Argument List Descriptions for TKPINPVariable I/O † Type Dimension Description

BLKID I CHARACTER*(*) — Block IDNPROP I INTEGER — Number of profile

propertiesPNAMES O CHARACTER*12 NPROP Property name. See

Chapter 11 for adescription.

IERR O INTEGER — Error flag (0=No error)† I = Input to subroutine

O = Output from subroutine

Call subroutine TKPIPR to retrieve the results for the specificproperty in the standard Pipe profiles results.

Calling Sequence for TKPIPRCALL TKPIPR (BLKID, NPOINT, PNAME, RVALS, TYPE,

LABEL, IERR)

Argument List Descriptions for TKPIPRVariable I/O † Type Dimension Description

BLKID I CHARACTER*(*) — Block IDNPOINT I INTEGER — Number of profile

pointsPNAME I CHARACTER*12 — Property name from

TKPINPRVALS O REAL*8 NPOINT Real resultsTYPE O CHARACTER*12 — Units typeLABEL O CHARACTER*16 — Units labelIERR O INTEGER — Error flag (0=No error)† I = Input to subroutine

O = Output from subroutine

Pipe Standard ProfileProperty Names

Pipe Standard ProfileProperties

Aspen Plus 11.1 Summary File Toolkit Block Result Subroutines •••• 4-71

The Pipe model allows you to get a profile report for the propertiesin a named property set. You can retrieve these results using a two-step process:1 Call TKSPIR to determine the size of the property set profile.2 Call TKNPIP to retrieve the next property set property

calculated in the profile report. Call TKRPIP to retrieve aspecified property.

Call subroutine TKSPIR to determine the size of the property setreport. The number of points in the report and the number ofproperties are returned.

Calling Sequence for TKSPIRCALL TKSPIR (BLKID, NPOINT, NPROP)

Argument List Descriptions for TKSPIRVariable I/O † Type Dimension Description

BLKID I CHARACTER*(*) — Block IDNPOINT O INTEGER — Number of profile

pointsNPROP O INTEGER — Number of profile

properties† I = Input to subroutine

O = Output from subroutine

Call subroutine TKNPIP to retrieve the next property calculatedfor a pipe property report. Use the property sequence number toidentify the property. TKNPIP returns the:• Property qualifiers• Property values• Units type• Units label

Calling Sequence for TKNPIPCALL TKNPIP (BLKID, NPOINT, IPROP, PNAME,

SUBSID, PHASE, COMPID, WETDRY,BASIS, RVALS, TYPE, LABEL, IERR)

Argument List Descriptions for TKNPIPVariable I/O † Type Dimension Description

BLKID I CHARACTER*(*) — Block IDNPOINT I INTEGER — Number of profile pointsIPROP I INTEGER — Property sequence

number

Pipe PropertyReports

Size of a Pipe PropertyReport

Sequential Pipe ReportProperties

4-72 •••• Block Result Subroutines Aspen Plus 11.1 Summary File Toolkit

Variable I/O † Type Dimension Description

PNAME O CHARACTER*12 — Property name. SeeChapter 11 for adescription.

SUBSID O CHARACTER*8 — Substream IDPHASE O CHARACTER*8 — PhaseCOMPID O CHARACTER*8 — Component IDWETDRY O CHARACTER*4 — Wet/dry basis (WET or

DRY)BASIS O CHARACTER*4 — Unit basis (MOLE,

MASS, or FLOW)RVALS O REAL*8 NPOINT Property valuesTYPE O CHARACTER*12 — Units typeLABEL O CHARACTER*16 — Units labelIERR O INTEGER — Error flag (0=No error)† I = Input to subroutine

O = Output from subroutine

Call subroutine TKRPIP to retrieve a specific property from a pipeproperty report. The property is identified by specifying theproperty set qualifiers (PNAME, SUBSID, PHASE, COMPID,WETDRY, BASIS). TKRPIP returns the property values, and theunits type and label.

Calling Sequence for TKRPIPCall TKRPIP (BLKID, NPOINT, PNAME, SUBSID,

PHASE, COMPID, WETDRY, BASIS,RVALS, TYPE, LABEL, IERR)

Argument List Descriptions for TKRPIPVariable I/O † Type Dimension Description

BLKID I CHARACTER*(*) — Block IDNPOINT I INTEGER — Number of profile pointsPNAME I CHARACTER*12 — Property name. See

Chapter 11 for a list ofvalid property names.

SUBSID I CHARACTER*8 — Substream IDPHASE I CHARACTER*8 — PhaseCOMPID I CHARACTER*8 — Component IDWETDRY I CHARACTER*4 — Wet/dry basis (WET or

DRY)BASIS I CHARACTER*4 — Unit basis (MOLE,

MASS, or FLOW)

Specific Pipe ReportProperties

Aspen Plus 11.1 Summary File Toolkit Block Result Subroutines •••• 4-73

Variable I/O † Type Dimension Description

RVALS O REAL*8 NPOINT Property valuesTYPE O CHARACTER*12 — Units typeLABEL O CHARACTER*16 — Units labelIERR O INTEGER — Error flag (0=No error)† I = Input to subroutine

O = Output from subroutine

Block VLE ResultsCall subroutine TKVLE to retrieve vapor-liquid (orvapor-liquid-liquid) equilibrium results for a block. These resultsare available for the following Aspen Plus models: Heater, Flash2,Flash3, RStoic, and RYield.

Calling Sequence for TKVLECALL TKVLE (BLKID, NPH, NCP, COMPID, F, X, Y,

RK, X2, RK2)

Argument List Descriptions for TKVLEVariable I/O † Type Dimension Description

BLKID I CHARACTER*(*) — Block IDNPH O INTEGER — Number of phases

(2=VLE, 3=VLLE)NCP O INTEGER — Number of components

presentCOMPID O CHARACTER*8 NCP Component IDsF O REAL*8 NCP Feed mole fractionsX O REAL*8 NCP Liquid mole fractions (for

VLE) or Liquid1 molefractions (for VLLE)

Y O REAL*8 NCP Vapor mole fractionsRK O REAL*8 NCP Vapor-Liquid K-value

(for VLE) orVapor-Liquid1 K-value(for VLLE)

X2 O REAL*8 NCP Liquid2 mole fractionsRK2 O REAL*8 NCP Vapor-Liquid2 K-value† I = Input to subroutine

O = Output from subroutine

4-74 •••• Block Result Subroutines Aspen Plus 11.1 Summary File Toolkit

Heating/Cooling CurvesAspen Plus can calculate heating/cooling curves for unit operationmodels Heater, Flash2, Flash3, HeatX, MHeatX, MCompR,RadFrac, MultiFrac, RateFrac, and PetroFrac. A unit operationblock can have any number of heating/cooling curves. Many unitoperation models allow for multiple types of heating/coolingcurves.You can retrieve heating/cooling curve results using a five-step process:1 Call TKNHCR to determine the number of heating/cooling

curves for a block.2 Call TKLHCR to list the heating/cooling curve types and

numbers.3 Call TKSHCR to determine the size of a heating/cooling

curve.4 Call TKHCUR to retrieve the standard results (temperature,

pressure, vapor fraction, and duty) for a heating/coolingcurve.

5 Retrieve the property set results by calling either TKNHCPfor sequential heating/cooling curve properties or TKHCPRfor specific heating/cooling curve properties.

The routines listed above replace the routines TKNHCV,TKLHCV, TKSHCV, TKHCRV, TKNHPR, and TKHPRP. Theseroutines will continue to be supported and updated but cannot beused to access PetroFrac heating/cooling curves.PetroFrac models have strippers and pumparounds that may haveheating/cooling curves. The heating/cooling curve for a particularstripper or pumparound has both a block ID and a second ID forthe main column/pumparound/stripper. The heating/cooling curveroutines have an argument for this second ID called ID2. Thisargument is ignored for other models.You can determine the interconnecting stream ID for MultiFracheating/cooling curves by calling TKHCID.

Call subroutine TKNHCR to determine the number ofheating/cooling curves for a unit operation block.

Calling Sequence for TKNHCRCALL TKNHCR (BLKID, NCURVE)

Number ofHeating/CoolingCurves for a Block

Aspen Plus 11.1 Summary File Toolkit Block Result Subroutines •••• 4-75

Argument List Descriptions for TKNHCRVariable I/O † Type Dimension Description

BLKID I CHARACTER*(*) — Block IDNCURVE O INTEGER — Number of

heating/cooling curves† I = Input to subroutine

O = Output from subroutine

Call subroutine TKLHCR to list the heating/cooling curves for aunit operation block. TKLHCR returns a list of heating/coolingcurve types and numbers, which are used to identify individualcurves. The IDs of the main column, pumparound, and strippers ofthe PetroFrac unit are returned in ID2.

Calling Sequence for TKLHCRCALL TKLHCR (BLKID, NCURVE, ID2, TYPES, NUMBER,

IERR)

Argument List Descriptions for TKLHCRVariable I/O † Type Dimension Description

BLKID I CHARACTER*(*) — Block IDNCURVE I INTEGER — Number of heating/cooling

curvesID2 O CHARACTER*8 NCURVE ID of PetroFrac main column,

pumparound, or stripperTYPES O CHARACTER*16 NCURVE Type of heating/cooling curve

(see below)NUMBER O INTEGER NCURVE Heating/cooling curve number

of each curveIERR O INTEGER — Error flag (0=No error)† I = Input to subroutine

O = Output from subroutine

TYPES value Type of Heating/Cooling Curve

HCURVE StandardHOT Hot sideCOLD Cold sideREBOILER ReboilerCONDENSER CondenserICSTREAM Interconnecting stream heaterPUMPAROUND PumparoundSTRIPPERREBOILER Stripper reboiler

Heating/CoolingCurves for a Block

4-76 •••• Block Result Subroutines Aspen Plus 11.1 Summary File Toolkit

Call subroutine TKSHCR to determine the size of aheating/cooling curve. TKSHCR returns the number of points inthe curve, and the number of properties calculated.

Calling Sequence for TKSHCRCALL TKSHCR (BLKID, ID2, TYPE, NUMBER, NPOINT,

NPROP)

Argument List Descriptions for TKSHCRVariable I/O † Type Dimension Description

BLKID I CHARACTER*(*) — Block IDID2 I CHARACTER*8 — ID of PetroFrac main column,

pumparound, or stripperTYPE I CHARACTER*16 — Type of heating/cooling curveNUMBER I INTEGER — Heating/cooling curve

numberNPOINT O INTEGER — Number of points in curveNPROP O INTEGER — Number of properties† I = Input to subroutine

O = Output from subroutine

Call subroutine TKHCUR to retrieve the temperature, pressure,vapor fraction, heat duty, and error flag for each point along thecurve.

Calling Sequence for TKHCURCALL TKHCUR (BLKID, ID2, TYPE, NUMBER, NPOINT,

IERFLG, TEMP, PRES, VFRAC, DUTY,IERR)

Argument List Descriptions for TKHCURVariable I/O † Type Dimension Description

BLKID I CHARACTER*(*) — Block IDID2 I CHARACTER*8 ID of PetroFrac main column,

pumparound, or stripperTYPE I CHARACTER*16 — Type of heating/cooling curveNUMBER I INTEGER — Heating/cooling curve numberNPOINT I INTEGER — Number of pointsIERFLG O INTEGER NPOINT Status flag for each point

0=OK 1=Errors in this row 2=Dew point 3=Bubble point)

TEMP O REAL*8 NPOINT Temperature at each point

Size of aHeating/CoolingCurve

StandardHeating/CoolingCurve Results

Aspen Plus 11.1 Summary File Toolkit Block Result Subroutines •••• 4-77

Variable I/O † Type Dimension Description

PRES O REAL*8 NPOINT Pressure at each pointVFRAC O REAL*8 NPOINT Vapor fraction at each pointDUTY O REAL*8 NPOINT Duty at each pointIERR O INTEGER — Error flag (0=No error)† I = Input to subroutine

O = Output from subroutine

Call subroutine TKNHCP to retrieve the next property setcalculated for a heating/cooling curve. Use the property sequencenumber to identify the property. TKNHCP returns the property setqualifiers, the property values, and the units type and label.

Calling Sequence for TKNHCPCALL TKNHCP (BLKID, ID2, TYPE, NUMBER,

NPOINT, IPROP, PNAME, SUBSID,PHASE, COMPID, WETDRY, BASIS,RVALS, UTYPE, LABEL, IERR)

Argument List Descriptions for TKNHCPVariable I/O † Type Dimension Description

BLKID I CHARACTER*(*) — Block IDID2 I CHARACTER*8 ID of PetroFrac main column,

pumparound, or stripperTYPE I CHARACTER*16 — Type of heating/cooling curveNUMBER I INTEGER — Heating/cooling curve numberNPOINT I INTEGER — Number of points in curveIPROP I INTEGER — Property sequence numberPNAME O CHARACTER*12 — Property name. See Chapter 11

for a description.SUBSID O CHARACTER*8 — Substream IDPHASE O CHARACTER*8 — PhaseCOMPID O CHARACTER*8 — Component IDWETDRY O CHARACTER*4 — Wet/dry basis (WET or DRY) ††

BASIS O CHARACTER*4 — Units basis (MOLE, MASS, orFLOW)

RVALS O REAL*8 NPOINT Real valuesUTYPE O CHARACTER*12 — Units typeLABEL O CHARACTER*16 — Units labelIERR O INTEGER — Error flag (0=No error)† I = Input to subroutine

O = Output from subroutine†† Can be left unspecified.

SequentialHeating/CoolingCurve Properties

4-78 •••• Block Result Subroutines Aspen Plus 11.1 Summary File Toolkit

Call subroutine TKHCPR to retrieve a specific property for aheating/cooling curve. The property is identified by specifying theproperty set qualifiers (PNAME, SUBSID, PHASE, COMPID,WETDRY, BASIS). Before calling TKHCPR, make sure that allthe qualifiers are either set to the desired value or unset. TKHCPRreturns the property values, the units type, and the units label.

Calling Sequence for TKHCPRCALL TKHCPR (BLKID, ID2, TYPE, NUMBER, NPOINT,

PNAME, SUBSID, PHASE, COMPID,WETDRY, BASIS, RVALS, UTYPE, LABEL,IERR)

Argument List Descriptions for TKHCPRVariable I/O † Type Dimension Description

BLKID I CHARACTER*(*) — Block IDID2 I CHARACTER*8 ID of PetroFrac main column,

pumparound, or stripperTYPE I CHARACTER*16 — Type of heating/cooling curveNUMBER I INTEGER — Heating/cooling curve numberNPOINT I INTEGER — Number of points in curvePNAME I CHARACTER*12 — Property name. See Chapter 11

for a list of valid propertynames.

SUBSID I CHARACTER*8 — Substream IDPHASE I CHARACTER*8 — PhaseCOMPID I CHARACTER*8 — Component IDWETDRY I CHARACTER*4 — Wet/dry basis (WET or DRY) ††

BASIS I CHARACTER*4 — Units basis (MOLE, MASS, orFLOW)

RVALS O REAL*8 NPOINT Real valuesUTYPE O CHARACTER*12 — Units typeLABEL O CHARACTER*16 — Units labelIERR O INTEGER — Error flag (0=No error)† I = Input to subroutine

O = Output from subroutine†† Can be left unspecified.

SpecificHeating/CoolingCurve Properties

Aspen Plus 11.1 Summary File Toolkit Block Result Subroutines •••• 4-79

MultiFrac heating/cooling curves of type ICSTREAM areassociated with interconnecting streams. Call subroutine TKHCIDto retrieve the ID of the interconnecting streams.

Calling Sequence for TKHCIDCALL TKHCID (BLKID, TYPE, NUMBER, INTID, CHARID,

IERR)

Argument List Descriptions for TKHCIDVariable I/O † Type Dimension Description

BLKID I CHARACTER*(*) — Block IDTYPE I CHARACTER*16 — Type of heating/cooling

curveNUMBER I INTEGER — Heating/cooling curve

numberINTID O INTEGER — Interconnecting stream

ID for MultiFracCHARID O CHARACTER*8 — Not currently usedIERR O INTEGER — Error flag (0=No error)† I = Input to subroutine

O = Output from subroutine

InterconnectingStream IDs

4-80 •••• Block Result Subroutines Aspen Plus 11.1 Summary File Toolkit

Aspen Plus 11.1 Summary File Toolkit Stream Result Subroutines •••• 5-1

Stream Result Subroutines

This chapter describes the use of stream result retrieval subroutinesin the Aspen Plus summary file toolkit. Use the subroutinesdescribed in this chapter for:• Stream identification• Material stream results• Heat and work stream results• Component attribute results• Substream attribute results• Stream property set results

5-2 •••• Stream Result Subroutines Aspen Plus 11.1 Summary File Toolkit

Stream IdentificationThe following subroutines are used to identify streams in thesummary file:• TKSIDS returns a list of all the streams in the summary file.• TKNSTR returns the next sequential stream.Both routines return the stream type (MATERIAL, HEAT, orWORK).

Call subroutine TKSIDS to retrieve the list of streams.

Calling Sequence for TKSIDSCALL TKSIDS (NSTRM, STRMID, STRTYP, IERR)

Argument List Descriptions for TKSIDSVariable I/O † Type Dimension Description

NSTRM I INTEGER — Stream numberSTRMID O CHARACTER*8 NSTRM Stream IDSTRTYP O CHARACTER*12 NSTRM Stream type (MATERIAL,

HEAT, or WORK)IERR O INTEGER — Error flag (0=No error)† I = Input to subroutine

O = Output from subroutine

Call subroutine TKNSTR to get the next stream in a sequence. Thestream is identified by the sequence number. TKNSTR also returnsthe stream type.To find the stream ID of the first stream, set ISTRM to 1. To findthe name of the second stream, set ISTRM to 2.

Calling Sequence for TKNSTRCALL TKNSTR (ISTRM, STRMID, STRTYP, IERR)

Argument List Descriptions for TKNSTRVariable I/O † Type Dimension Description

ISTRM I INTEGER — Stream numberSTRMID O CHARACTER*(*) — Stream IDSTRTYP O CHARACTER*12 — Stream type (MATERIAL,

HEAT, or WORK)IERR O INTEGER — Error flag (0=No error)† I = Input to subroutine

O = Output from subroutine

Listing Stream IDs

Determining the NextStream

Aspen Plus 11.1 Summary File Toolkit Stream Result Subroutines •••• 5-3

Material Stream ResultsTKSINF returns the source and destination blocks, along with thedimensions of the data for material streams. TKSSID returns thelist of substream IDs for a stream. TKSTRM retrieves the resultsfor material streams.

Call subroutine TKSINF to retrieve basic stream information.TKSINF returns the source and destination blocks of the stream. Inaddition, TKSINF returns the number of substreams and thedimensions of the results for material streams.

Calling Sequence for TKSINFCALL TKSINF (STRMID, SOURCE, DEST, NSUBS, LEN,

IERR)

Argument List Descriptions for TKSINFVariable I/O † Type Dimension Description

STRMID I CHARACTER*(*) — Stream IDSOURCE O CHARACTER*(*) — Source block IDDEST O CHARACTER*(*) — Destination block IDNSUBS O INTEGER — Number of substreamsLEN O INTEGER — Number of stream

resultsIERR O INTEGER — Error flag (0=No error)† I = Input to subroutine

O = Output from subroutine

Call subroutine TKSSID to list the substreams for a stream.

Calling Sequence for TKSSIDCALL TKSSID (STRMID, NSUB, SUBSID)

Argument List Descriptions for TKSSIDVariable I/O † Type Dimension Description

STRMID I CHARACTER*(*) — Stream IDNSUB I INTEGER — Number of

substreamsSUBSID O CHARACTER*8 NSUB Substream IDs† I = Input to subroutine

O = Output from subroutine

Retrieving BasicStream Information

Listing Substream IDs

5-4 •••• Stream Result Subroutines Aspen Plus 11.1 Summary File Toolkit

Call subroutine TKSTRM to retrieve the results for a materialstream. The property is identified by its qualifiers. Typical qualifiersare property name, substream, component ID, and units basis.

Calling Sequence for TKSTRMCALL TKSTRM (STRMID, LEN, QUALS, RVALS, TYPES,

LABELS, IERR )

Argument List Descriptions for TKSTRMVariable I/O † Type Dimension Description

STRMID I CHARACTER*(*) — Stream IDLEN I INTEGER — Number of stream resultsQUALS O CHARACTER*16 4*LEN Qualifiers for results. For

each value they are:• Property name. SeeChapter 11 for a description.• Substream ID• Component ID• Units basis

RVALS O REAL*8 LEN Real resultsTYPES O CHARACTER*12 LEN Units typeLABELS O CHARACTER*16 LEN Units labelIERR O INTEGER — Error flag (0=No error)† I = Input to subroutine

O = Output from subroutine

Call subroutine TKSVAL to retrieve a single material streamproperty. RVALS is an array which should be dimensioned to 1 ifan overall stream property is requested, or to NCOMP if acomponent property from Table B.4 is requested.

Calling Sequence for TKSVALCALL TKSVAL (STRMID, SUBSID, PNAME, BASIS,

RVALS, TYPE, LABEL, IERR)

Argument List Descriptions for TKSVALVariable I/O † Type Dimension Description

STRMID I CHARACTER*(*) — Stream IDSUBSID I CHARACTER*8 — Substream IDPNAME I CHARACTER*12 — Property name. See

Chapter 11 for a list ofvalid property names.

BASIS I CHARACTER*4 — Units basis (MOLE,MASS, or FLOW)

Retrieving StreamResults

Retrieving a SingleStream Property

Aspen Plus 11.1 Summary File Toolkit Stream Result Subroutines •••• 5-5

Variable I/O † Type Dimension Description

RVALS O REAL*8 1 orNCOMP

Real results (UseNCOMP if value is for acomponent property.)

TYPE O CHARACTER*12 — Units typeLABEL O CHARACTER*16 — Units labelIERR O INTEGER — Error flag

(0=No error)† I = Input to subroutine

O = Output from subroutine

Heat and Work Stream ResultsCall subroutine TKSTRA to retrieve the result value from a heat ora work stream. Heat streams return an enthalpy flow. Workstreams return a power.

Calling Sequence for TKSTRACALL TKSTRA (STRMID, STRTYP, VALUE, LABEL)

Argument List Descriptions for TKSTRAVariable I/O † Type Dimension Description

STRMID I CHARACTER*(*) — Stream IDSTRTYP I CHARACTER*4 — Stream type (HEAT or WORK)VALUE O REAL*8 — Result valueLABEL O CHARACTER*16 — Units labels (type is

ENTHALPY-FLOW for heatstreams, POWER for workstreams)

† I = Input to subroutineO = Output from subroutine

Component Attribute ResultsYou can retrieve component attribute results for a substream usinga four-step process:1 Call TKSNAC to determine the number of components with

attributes in the substream.2 Call TKSNCA to determine the number of attributes for a

component in a substream.3 Call TKSSCA to determine the size of a component attribute.4 Call TKSCAT to retrieve the component attribute values.

5-6 •••• Stream Result Subroutines Aspen Plus 11.1 Summary File Toolkit

Call subroutine TKSNAC to retrieve the number of componentswith attributes in a specified substream.

Calling Sequence for TKSNACCALL TKSNAC (STRMID, SUBSID, NAC)

Argument List Descriptions for TKSNACVariable I/O† Type Dimension Description

STRMID I CHARACTER*(*) — Stream IDSUBSID I CHARACTER*8 — Substream IDNAC O INTEGER — Number of components

with attributes† I = Input to subroutine

O = Output from subroutine

Call subroutine TKSNCA to determine the number of attributes fora component. Specify the component number; TKSNCA returns thecomponent ID and the number of attributes.

Calling Sequence for TKSNCACALL TKSNCA (STRMID, SUBSID, ICOMP, COMPID,

NATT)

Argument List Descriptions for TKSNCAVariable I/O † Type Dimension Description

STRMID I CHARACTER*(*) — Stream IDSUBSID I CHARACTER*8 — Substream IDICOMP I INTEGER — Component sequence

numberCOMPID O CHARACTER*8 — Component IDNATT O INTEGER — Number of attributes† I = Input to subroutine

O = Output from subroutine

Determining theNumber ofComponents withAttributes

Determining Numberof Attributes for aComponent

Aspen Plus 11.1 Summary File Toolkit Stream Result Subroutines •••• 5-7

Call subroutine TKSSCA to determine the size of a componentattribute. Specify the attribute sequence number. TKSSCA returnsthe attribute name and the number of elements.

Calling Sequence for TKSSCACALL TKSSCA (STRMID, SUBSID, COMPID, IATT,

IDATT, NELEM)

Argument List Descriptions for TKSSCAVariable I/O † Type Dimension Description

STRMID I CHARACTER*(*) — Stream IDSUBSID I CHARACTER*8 — Substream IDCOMPID I CHARACTER*8 — Component IDIATT I INTEGER — Attribute sequence

numberIDATT O CHARACTER*8 — Attribute nameNELEM O INTEGER — Number of elements† I = Input to subroutine

O = Output from subroutine

Call subroutine TKSCAT to retrieve the array of componentattribute values and the name of each attribute element.

Calling Sequence for TKSCATCALL TKSCAT (STRMID, SUBSID, COMPID, IDATT,

NELEM, ELEMID, VALUES, IERR)

Argument List Descriptions for TKSCATVariable I/O † Type Dimension Description

STRMID I CHARACTER*(*) — Stream IDSUBSID I CHARACTER*8 — Substream IDCOMPID I CHARACTER*8 — Component IDIDATT I CHARACTER*8 — Attribute nameNELEM I INTEGER — Number of elementsELEMID O CHARACTER*8 NELEM Names of elementsVALUES O REAL*8 NELEM Real valuesIERR O INTEGER — Error flag (0=No error)† I = Input to subroutine

O = Output from subroutine

DeterminingComponent AttributeSize

RetrievingComponent AttributeValues

5-8 •••• Stream Result Subroutines Aspen Plus 11.1 Summary File Toolkit

Substream Attribute ResultsYou can retrieve substream attribute results for a substream using athree-step process:1 Call TKSNSA to get the number of substream attributes in a

substream.2 Call TKSSSA to get the size of a substream attribute.3 Call TKSSAT to retrieve the substream attribute results.

Call subroutine TKSNSA to determine the number of attributes in asubstream.

Calling Sequence for TKSNSACALL TKSNSA (STRMID, SUBSID, NSATT)

Argument List Descriptions for TKSNSAVariable I/O † Type Dimension Description

STRMID I CHARACTER*(*) — Stream IDSUBSID I CHARACTER*8 — Substream IDNSATT O INTEGER — Number of substream

attributes† I = Input to subroutine

O = Output from subroutine

Call subroutine TKSSSA to determine the size of a substreamattribute. Specify the attribute sequence number; TKSSSA returnsthe number of elements and the attribute ID.

Calling Sequence for TKSSSACALL TKSSSA (STRMID, SUBSID, ISATT, SATID,

NELEM)

Argument List Descriptions for TKSSSAVariable I/O † Type Dimension Description

STRMID I CHARACTER*(*) — Stream IDSUBSID I CHARACTER*8 — Substream IDISATT I INTEGER — Attribute sequence

numberSATID O CHARACTER*8 — Attribute IDNELEM O INTEGER — Number of elements† I = Input to subroutine

O = Output from subroutine

Determining theNumber of SubstreamAttributes

DeterminingSubstream AttributeSize

Aspen Plus 11.1 Summary File Toolkit Stream Result Subroutines •••• 5-9

Call subroutine TKSSAT to retrieve results for substream attributes.

Calling Sequence for TKSSATCALL TKSSAT (STRMID, SUBSID, SATID, NELEM,

VALUES, IERR)

Argument List Descriptions for TKSSATVariable I/O † Type Dimension Description

STRMID I CHARACTER*(*) — Stream IDSUBSID I CHARACTER*8 — Substream IDSATID I CHARACTER*8 — Attribute IDNELEM I INTEGER — Number of elementsVALUES O REAL*8 NELEM Real valuesIERR O INTEGER — Error flag (0=No error)† I = Input to subroutine

O = Output from subroutine

Stream Property Set ResultsYou can retrieve results for additional property sets specified in thestandard stream report using a two-step process:1 Call subroutine TKNSPR to get the number of properties.2 Call TKSPRP to retrieve the property values.

Call subroutine TKNSPR to determine the number of property setresults for a stream.

Calling Sequence for TKNSPRCALL TKNSPR (STRMID, NVAL, IERR)

Argument List Descriptions for TKNSPRVariable I/O † Type Dimension Description

STRMID I CHARACTER*(*) — Stream IDNVAL O INTEGER — Number of values† I = Input to subroutine

O = Output from subroutine

Retrieving SubstreamAttribute Values

DeterminingDimensions of StreamProperty Values

5-10 •••• Stream Result Subroutines Aspen Plus 11.1 Summary File Toolkit

Call subroutine TKSPRP to retrieve the property values for astream. TKSPRP returns the property qualifiers to identify eachproperty value.

Calling Sequence for TKSPRPCALL TKSPRP (STRMID, NVAL, PNAME, SUBSID,

PHASE, COMPID, WETDRY, BASIS,RVALS, TYPES, LABELS, IERR)

Argument List Descriptions for TKSPRPVariable I/O † Type Dimension Description

STRMID I CHARACTER*(*) — Stream IDNVAL I INTEGER — Number of valuesPNAME O CHARACTER*12 NVAL Property name. See

Chapter 11 for adescription.

SUBSID O CHARACTER*8 NVAL Substream IDPHASE O CHARACTER*8 NVAL PhaseCOMPID O CHARACTER*8 NVAL Component IDWETDRY O CHARACTER*4 NVAL Wet/dry basis

(WET or DRY) ††

BASIS O CHARACTER*4 NVAL Units basis (MOLE,MASS, or FLOW)

RVALS O REAL*8 NVAL Real resultsTYPES O CHARACTER*12 NVAL Units typesLABELS O CHARACTER*16 NVAL Units labelsIERR O INTEGER — Error flag (0=No error)† I = Input to subroutine

O = Output from subroutine†† Can be left unspecified.

Retrieving StreamProperty Results

Aspen Plus 11.1 Summary File Toolkit Physical Property Table Results Subroutines •••• 6-1

Physical Property Table ResultsSubroutines

You can retrieve all property table results using a standard set ofsubroutines. There is a separate set of subroutines for retrievingpressure-temperature envelope results.This chapter describes:• Property table identification• Property and flashcurve table results• Pressure-temperature envelope results

Property Table IdentificationCall subroutine TKNPPT to get the next property table in sequencefrom the summary file.

Calling Sequence for TKNPPTCALL TKNPPT (ITABLE, TABID, TYPE, IERR)

Argument List Descriptions for TKNPPTVariable I/O † Type Dimension Description

ITABLE I INTEGER — Property table sequencenumber

TABID O CHARACTER*(*) — Property table IDTYPE O CHARACTER*12 — Property table type

(PROPS,FLASHCURVE, orPTENVELOPE)

IERR O INTEGER — Error flag (0=No error)† I = Input to subroutine

O = Output from subroutine

6-2 •••• Physical Property Table Results Subroutines Aspen Plus 11.1 Summary File Toolkit

Property and Flashcurve TableResultsYou can retrieve property and flashcurve table results by callingeither of the following two subroutines:• TKNPPR to retrieve the next sequential property• TKPPRP to retrieve a specific propertyWhen you use either of these subroutines, you must call subroutineTKSPPT to determine the dimensions of the property table.Call subroutine TKSPPT to determine the dimensions of a propertytable. TKSPPT returns the number of points and the number ofproperties.

Calling Sequence for TKSPPTCALL TKSPPT (TABID, NPOINT, NPROP, IERR)

Argument List Descriptions for TKSPPTVariable I/O † Type Dimension Description

TABID I CHARACTER*(*) — Property table IDNPOINT O INTEGER — Number of pointsNPROP O INTEGER — Number of propertiesIERR O INTEGER — Error flag (0=No error)† I = Input to subroutine

O = Output from subroutine

Call subroutine TKNPPR to retrieve the next property in sequencefrom the property table. Identify the property using the propertysequence number. TKNPPR returns the stream property qualifiers.

Calling Sequence for TKNPPRCALL TKNPPR (TABID, NPOINT, IPROP, PNAME,

SUBSID, PHASE, COMPID, WETDRY,BASIS, RVALS, TYPE, LABEL, IERR)

Argument List Descriptions for TKNPPRVariable I/O † Type Dimension Description

TABID I CHARACTER*(*) — Property table IDNPOINT I INTEGER — Number of pointsIPROP I INTEGER — Property numberPNAME O CHARACTER*12 — Property name. See

Chapter 11 for adescription.

SUBSID O CHARACTER*8 — Substream ID

Determining PropertyTable Dimensions

Retrieving SequentialProperties in a Table

Aspen Plus 11.1 Summary File Toolkit Physical Property Table Results Subroutines •••• 6-3

Variable I/O † Type Dimension Description

PHASE O CHARACTER*8 — PhaseCOMPID O CHARACTER*8 — Component IDWETDRY O CHARACTER*4 — Wet/dry basis

(WET or DRY) ††

BASIS O CHARACTER*4 — Units basis (MOLE,MASS, or FLOW)

RVALS O REAL*8 NPOINT Real valuesTYPE O CHARACTER*12 — Units typeLABEL O CHARACTER*16 — Units labelIERR O INTEGER — Error flag (0=No error)† I = Input to subroutine

O = Output from subroutine†† Can be left unspecified.

Call subroutine TKPPRP to retrieve a specific property from theproperty table. Specify the property by listing its qualifiers.

Calling Sequence for TKPPRPCALL TKPPRP (TABID, NPOINT, PNAME, SUBSID,

PHASE, COMPID, WETDRY, BASIS,RVALS, TYPE, LABEL, IERR)

Argument List Descriptions for TKPPRPVariable I/O † Type Dimension Description

TABID I CHARACTER*(*) — Property table IDNPOINT I INTEGER — Number of pointsPNAME I CHARACTER*12 — Property name. See

Chapter 11 for a list ofvalid property names.

SUBSID I CHARACTER*8 — Substream IDPHASE I CHARACTER*8 — PhaseCOMPID I CHARACTER*8 — Component IDWETDRY I CHARACTER*4 — Wet/dry basis

(WET or DRY) ††

BASIS I CHARACTER*4 — Units basis (MOLE,MASS, or FLOW)

RVALS O REAL*8 NPOINT Real valuesTYPE O CHARACTER*12 — Units typeLABEL O CHARACTER*16 — Units labelIERR O INTEGER — Error flag (0=No error)† I = Input to subroutine

O = Output from subroutine†† Can be left unspecified.

Retrieving SpecificProperties from aTable

6-4 •••• Physical Property Table Results Subroutines Aspen Plus 11.1 Summary File Toolkit

Pressure-Temperature EnvelopeResultsYou can retrieve pressure-temperature envelope results using afour-step process:1 Call TKNENV to determine the number of envelopes and

properties in a property table.2 Call TKSENV to determine the size of each branch of an

envelope.3 Call TKPTEV to retrieve the temperature and pressure along

each branch of an envelope.4 Retrieve the property set for each branch of an envelope. You

can retrieve each property sequentially using TKNPEV, orretrieve a specific property using TKPPEV.

Call subroutine TKNENV to determine the number of envelopesand the number of properties.

Calling Sequence for TKNENVCALL TKNENV (TABID, NENVL, NPROP, IERR)

Argument List Descriptions for TKNENVVariable I/O † Type Dimension Description

TABID I CHARACTER*(*) — Property table IDNENVL O INTEGER — Number of envelopesNPROP O INTEGER — Number of propertiesIERR O INTEGER — Error flag (0=No error)† I = Input to subroutine

O = Output from subroutine

Call subroutine TKSENV to determine the dimensions of anenvelope. TKSENV returns the number of points for each branchof the envelope. For an envelope at a vapor fraction of .5, zero isreturned as the dimension of the complementary branch.

Calling Sequence for TKSENVCALL TKSENV (TABID, IENVL, NP1, NP2)

Argument List Descriptions for TKSENVVariable I/O † Type Dimension Description

TABID I CHARACTER*(*) — Property table IDIENVL I INTEGER — Envelope number

DeterminingDimensions forProperties in theEnvelope

DeterminingEnvelope Dimensions

Aspen Plus 11.1 Summary File Toolkit Physical Property Table Results Subroutines •••• 6-5

Variable I/O † Type Dimension Description

NP1 O INTEGER — Number of points in thefirst branch

NP2 O INTEGER — Number of points in thecomplementary branch

† I = Input to subroutineO = Output from subroutine

Call subroutine TKPTEV to retrieve the temperature and pressurefor each branch along an envelope. TKPTEV also returns the vaporfraction values for each branch.

Calling Sequence for TKPTEVCALL TKPTEV (TABID, IENVL, NP1, NP2, VFRAC1,

VFRAC2, TEMP1, PRES1, TEMP2, PRES2)

Argument List Descriptions for TKPTEVVariable I/O † Type Dimension Description

TABID I CHARACTER*(*) — Property table IDIENVL I INTEGER — Envelope numberNP1 I INTEGER — Number of points in the

first branchNP2 I INTEGER — Number of points in the

complementary branchVFRAC1 O REAL*8 — Vapor fraction for the

first branchVFRAC2 O REAL*8 — Vapor fraction for the

complementary branchTEMP1 O REAL*8 NP1 Temperature values for

the first branchPRES1 O REAL*8 NP1 Pressure values for the

first branchTEMP2 O REAL*8 NP2 Temperature values for

the complementarybranch

PRES2 O REAL*8 NP2 Pressure values for thecomplementary branch

† I = Input to subroutineO = Output from subroutine

RetrievingTemperature andPressure forEnvelope Branch

6-6 •••• Physical Property Table Results Subroutines Aspen Plus 11.1 Summary File Toolkit

Call subroutine TKNPEV to retrieve the next sequential propertyfor an envelope. TKNPEV returns the property values for bothbranches of the envelope and the vapor fraction values.

Calling Sequence for TKNPEVCALL TKNPEV (TABID, IENVL, IPROP, NP1, NP2,

VFRAC1, VFRAC2, PNAME, SUBSID,PHASE, COMPID, WETDRY, BASIS,VALS1, VALS2, TYPE, LABEL)

Argument List Descriptions for TKNPEVVariable I/O † Type Dimension Description

TABID I CHARACTER*(*) — Table IDIENVL I INTEGER — Envelope numberIPROP I INTEGER — Property sequence

numberNP1 I INTEGER — Number of points along

the first branchNP2 I INTEGER — Number of points along

the complementarybranch

VFRAC1 O REAL*8 — Vapor fraction for thefirst branch

VFRAC2 O REAL*8 — Vapor fraction for thecomplementary branch

PNAME O CHARACTER*12 — Property name. SeeChapter 11 for adescription.

SUBSID O CHARACTER*8 — Substream IDPHASE O CHARACTER*8 — PhaseCOMPID O CHARACTER*8 — Component IDWETDRY O CHARACTER*4 — Wet/dry basis

(WET or DRY) ††

BASIS O CHARACTER*4 — Units basis (MOLE,MASS, or FLOW)

VALS1 O REAL*8 NP1 Property values for thefirst branch

VALS2 O REAL*8 NP2 Property values for thecomplementary branch

TYPE O CHARACTER*12 — Units typeLABEL O CHARACTER*16 — Units label† I = Input to subroutine

O = Output from subroutine†† Can be left unspecified.

Retrieving SequentialEnvelope Properties

Aspen Plus 11.1 Summary File Toolkit Physical Property Table Results Subroutines •••• 6-7

Call subroutine TKPPEV to retrieve a specific property set from apressure-temperature envelope.

Calling Sequence for TKPPEVCALL TKPPEV (TABID, IENVL, NP1, NP2, PNAME,

SUBSID, PHASE, COMPID, WETDRY,BASIS, VFRAC1, VFRAC2, VALS1,VALS2, TYPE, LABEL)

Argument List Descriptions for TKPPEVVariable I/O † Type Dimension Description

TABID I CHARACTER*(*) — Table IDIENVL I INTEGER — Envelope numberNP1 I INTEGER — Number of points along

the first branchNP2 I INTEGER — Number of points along

the complementarybranch

PNAME I CHARACTER*12 — Property name. SeeChapter 11 for a list ofvalid property names.

SUBSID I CHARACTER*8 — Substream IDPHASE I CHARACTER*8 — PhaseCOMPID I CHARACTER*8 — Component IDWETDRY I CHARACTER*4 — Wet/dry basis

(WET or DRY)††

BASIS I CHARACTER*4 — Units basis (MOLE,MASS, or FLOW)

VFRAC1 O REAL*8 — Vapor fraction of thefirst branch

VFRAC2 O REAL*8 — Vapor fraction of thecomplementary branch

VALS1 O REAL*8 NP1 Property values for thefirst branch

VALS2 O REAL*8 NP2 Property values for thecomplementary branch

TYPE O CHARACTER*12 — Units typeLABEL O CHARACTER*16 — Units label† I = Input to subroutine

O = Output from subroutine†† Can be left unspecified.

Retrieving SpecificEnvelope Properties

6-8 •••• Physical Property Table Results Subroutines Aspen Plus 11.1 Summary File Toolkit

Aspen Plus 11.1 Summary File Toolkit Costing Results Subroutines •••• 7-1

Costing Results Subroutines

This chapter describes the use of costing equipment item retrievalsubroutines in the summary file toolkit. Use the subroutinesdescribed in this chapter for retrieving this information aboutequipment items:• Identification• Costing and sizing results

7-2 •••• Costing Results Subroutines Aspen Plus 11.1 Summary File Toolkit

Equipment Item IdentificationThe subroutines used to identify costing equipment items in thesummary file are:Subroutine Returns

TKNEQ Number of equipment items in the summary fileTKEIDS List of equipment items in the summary fileTKNEQP Equipment item IDs sequentially

Call TKNEQ to determine the number of equipment items in thesummary file.

Calling Sequence for TKNEQCALL TKNEQ (NEQUIP)

Argument List Descriptions for TKNEQVariable I/O † Type Dimension Description

NEQUIP O INTEGER — Number of equipment items† I = Input to subroutine

O = Output from subroutine

Call subroutine TKEIDS to get the list of equipment items andtypes.

Calling Sequence for TKEIDSCALL TKEIDS (NEQUIP, EQPID, EQPTYP, IERR)

Argument List Descriptions for TKEIDSVariable I/O † Type Dimension Description

NEQUIP I INTEGER — Number of equipmentitems

EQPID O CHARACTER*8 NEQUIP Equipment item IDEQPTYP O CHARACTER*12 NEQUIP Equipment typeIERR O INTEGER — Error flag (0=No error)† I = Input to subroutine

O = Output from subroutine

Determining Numberof Equipment Items

Listing EquipmentItems

Aspen Plus 11.1 Summary File Toolkit Costing Results Subroutines •••• 7-3

Call subroutine TKNEQP to find the name of the next equipmentitem.To find the ID of the first equipment item, set IEQUIP to 1. Tofind the name of the second item, set IEQUIP to 2, and so on.

Calling Sequence for TKNEQPCALL TKNEQP (IEQUIP, EQPID, EQPTYP, IERR)

Argument List Descriptions for TKNEQPVariable I/O † Type Dimension Description

IEQUIP I INTEGER — Equipment item numberEQPID O CHARACTER*8 — Equipment item IDEQPTYP O CHARACTER*12 — Equipment typeIERR O INTEGER — Error flag (0=No error)† I = Input to subroutine

O = Output from subroutine

Equipment Item ResultsThe following subroutines are used to return results for equipmentitems in the summary file:

Subroutine Returns

TKEQCR Costing results for an equipment itemTKNEQS Number of sizing results for an equipment itemTKEQSR Sizing results for an equipment item

Call subroutine TKEQCR to retrieve the calculated number ofequipment items, the carbon steel cost, and the purchased cost.

Calling Sequence for TKEQCRCALL TKEQCR (EQPID, EQPTYP, NCALC, CSCOST,

PCOST, IERR)

Argument List Descriptions for TKEQCRVariable I/O † Type Dimension Description

EQPID I CHARACTER*8 — Equipment Item IDNCALC O INTEGER — Calculated number of

equipment itemsCSCOST O REAL*8 — Carbon steel costPCOST O REAL*8 — Purchased costIERR O INTEGER — Error flag (0=No error)† I = Input to subroutine

O = Output from subroutine

Determining NextEquipment Item

Retrieving EquipmentItem Costing Results

7-4 •••• Costing Results Subroutines Aspen Plus 11.1 Summary File Toolkit

Call subroutine TKNEQS to determine the number of equipmentitem sizing results.

Calling Sequence for TKNEQSCALL TKNEQS (EQPID, NVAL, IERR)

Argument List Descriptions for TKNEQSVariable I/O † Type Dimension Description

EQPID I CHARACTER*8 — Equipment Item IDNVAL O INTEGER — Number of resultsIERR O INTEGER — Error flag (0=No error)† I = Input to subroutine

O = Output from subroutine

Call subroutine TKEQSR to retrieve the equipment item sizingresults.

Calling Sequence for TKEQSRCALL TKEQSR (EQPID, NVAL, PNAMES, ITYPES,

IVALS, CVALS, RVALS, UTYPES,LABELS, IERR)

Argument List Descriptions for TKEQSRVariable I/O † Type Dimension Description

EQPID I CHARACTER*8 — Equipment item IDNVAL I INTEGER — Number of resultsPNAMES O CHARACTER*12 NVAL Property names. See

Chapter 11 for adescription.

ITYPES O INTEGER NVAL Result type(1 = Integer value, 2 = Real*8 value, 3 = Character value)††

IVALS O INTEGER NVAL Integer resultCVALS O CHARACTER*12 NVAL Character resultRVALS O REAL*8 NVAL Real resultUTYPES O CHARACTER*12 NVAL Units typeLABELS O CHARACTER*16 NVAL Units labelIERR O INTEGER — Error flag (0=No error)† I = Input to subroutine

O = Output from subroutine†† For each result, the value in ITYPE specifies which array contains the

result (IVALS, CVALS, or RVALS). For example, if ITYPE(4) is 2, thenIVALS(4) is 0, CVALS(4) is blank and RVALS(4) contains the result.

DeterminingEquipment ItemSizing Results

Retrieving EquipmentItem Sizing Results

Aspen Plus 11.1 Summary File Toolkit Pressure Relief Subroutines •••• 8-1

Pressure Relief Subroutines

This chapter describes the use of pressure relief retrievalsubroutines in the summary file toolkit. Use the subroutinesdescribed in this chapter for:• Pressure relief model identification• Dynamic and steady-state results• Scalar results• Profile results• Vessel results• Vent results• Accumulator results

Pressure Relief Block IdentificationThe following subroutines are used to identify the pressure reliefblocks in the summary file:• TKNPRS returns the number of pressure relief blocks in the

summary file.• TKPIDS returns a list of pressure relief IDs in the summary

file.• TKNXPR retrieves the pressure relief IDs sequentially.There is no additional type information, unlike the correspondingblock routines.

8-2 •••• Pressure Relief Subroutines Aspen Plus 11.1 Summary File Toolkit

Call subroutine TKNPRS to determine the number of pressurerelief blocks in the summary file.

Calling Sequence for TKNPRSCALL TKNPRS (NPR)

Argument List Descriptions for TKNPRSVariable I/O † Type Dimension Description

NPR O INTEGER — Number of pressure relief blocks† I = Input to subroutine

O = Output from subroutine

Call subroutine TKPIDS to get a list of pressure relief blocks.

Calling Sequence for TKPIDSCALL TKPIDS (NPR, PRID, IERR)

Argument List Descriptions for TKPIDSVariable I/O † Type Dimension Description

NPR I INTEGER — Number of pressurerelief blocks

PRID O CHARACTER*(*) NPR Pressure relief IDsIERR O INTEGER — Error flag

(0=No error)† I = Input to subroutine

O = Output from subroutine

Call subroutine TKNXPR to find the ID of the next pressure reliefblock in sequence.To find the first ID, set IPR to 1. To find the ID of the second, setIPR to 2.

Calling Sequence for TKNXPRCALL TKNXPR (IPR, PRID, IERR)

Argument List Descriptions for TKNXPRVariable I/O † Type Dimension Description

IPR I INTEGER — Sequence number ofpressure relief blocks

PRID O CHARACTER*(*) — Pressure relief IDIERR O INTEGER — Error flag (0=No error)† I = Input to subroutine

O = Output from subroutine

Determining theNumber of PressureRelief Blocks

Listing PressureRelief Blocks

Determining the NextPressure Relief Block

Aspen Plus 11.1 Summary File Toolkit Pressure Relief Subroutines •••• 8-3

Pressure Relief ResultsYou can retrieve scalar and profile results from the summary filefor the pressure relief blocks. Results are either steady state ordynamic. You can also retrieve the vent accumulator and ventprofile results for the dynamic case. Retrieving pressure reliefresults is a five-step process:1 Call subroutine TKPSUB to determine the number of

substreams.2 Call subroutine TKPSRF to determine the dimensions of the

scalar results and profiles.3 Call TKPSSR to retrieve the dynamic scalar results; call

subroutine TKPSSS to retrieve steady-state results.4 Call subroutine TKPSRP to list the dynamic properties; call

subroutine TKPSSP to list the steady-state properties.5 For dynamic results, call subroutine TKPSR1 to retrieve the

non-component-dependent profile properties; call subroutineTKPSR2 to retrieve the component-dependent profileproperties.

– Or –For steady-state results, call subroutine TKPSS1 to retrieve theproperty values.

Retrieving the vent accumulator profiles for the dynamic resultsrequires three additional steps:6 Call subroutine TKPVPF to determine the dimensions of the

profile.7 Call subroutine TKPVRP to list the properties.8 Call subroutine TKPVR1 to retrieve the property values for

position-dependent properties. Or call subroutine TKPVR2 toretrieve the property values for component-dependentproperties.

Retrieving the vent profiles for the dynamic results requiresanother three steps:9 Call subroutine TKPAPF to determine the dimensions of the

profile.10 Call subroutine TKPAPR to list the properties.11 Call subroutine TKPAR1 to retrieve the property values for

non-component-dependent properties. Or call subroutineTKPAR2 to retrieve the property values for component-dependent properties.

8-4 •••• Pressure Relief Subroutines Aspen Plus 11.1 Summary File Toolkit

Call subroutine TKPSUB to determine the number of substreamsfor which the pressure relief block has results. If the results for thepressure relief model are at steady-state there are no substreamdependent results and a value of one is returned.

Calling Sequence for TKPSUBCALL TKPSUB (PRID, NSUB)

Argument List Descriptions for TKPSUBVariable I/O † Type Dimension Description

PRID I CHARACTER*(*) — Block IDNSUB O INTEGER — Number of substreams† I = Input to subroutine

O = Output from subroutine

Call subroutine TKPSRF to determine the sizes for the pressurerelief arrays. TKPSRF returns:• Number of scalar results• Number of profile points• Number of components present• Number of profile properties• Substream ID for the requested substream• Whether the results are steady state or dynamic

Calling Sequence for TKPSRFCALL TKPSRF (PRID, ISUB, SUBSID, ISTATE, NSCAL,

NPOINT, NCP, NPROP)

Argument List Descriptions for TKPSRFVariable I/O † Type Dimension Description

PRID I CHARACTER*(*) — Block IDISUB I INTEGER — Substream numberSUBSID O CHARACTER*8 — Substream IDISTATE O INTEGER — Results

(1=Steady state, 2=Dynamic)

NSCAL O INTEGER — Number of scalar resultsNPOINT O INTEGER — Number of output pointsNCP O INTEGER — Number of components

presentNPROP O INTEGER — Number of properties† I = Input to subroutine

O = Output from subroutine

Determining theNumber ofSubstreams

DeterminingDimensions ofPressure ReliefArrays

Aspen Plus 11.1 Summary File Toolkit Pressure Relief Subroutines •••• 8-5

Call subroutine TKPSRP to list the dynamic profile properties for aspecified substream. TKPSRP returns an array of property names,and an array indicating whether the property is component-dependent.Call subroutine TKPSSP to list the steady-state profile properties.TKPSSP returns an array of property names, and the names of thepressure relief positions for each profile point.

Calling Sequence for TKPSRPCALL TKPSRP (PRID, SUBSID, NPROP, ITYPES,

PNAMES, IERR)

Argument List Descriptions for TKPSRPVariable I/O † Type Dimension Description

PRID I CHARACTER*(*) — Block IDSUBSID I CHARACTER*8 — Substream IDNPROP I INTEGER — Number of propertiesITYPES O INTEGER NPROP Property type

(1=Not component-dependent

2=Component-dependent)PNAMES O CHARACTER*12 NPROP Property names. See

Chapter 11 for adescription.

IERR O INTEGER — Error flag (0=No error)† I = Input to subroutine

O = Output from subroutine

Calling Sequence for TKPSSPCALL TKPSSP (PRID, NPROP, NPOINT, PNAMES,

POSIDS, IERR)

Argument List Descriptions for TKPSSPVariable I/O † Type Dimension Description

PRID I CHARACTER*(*) — Block IDNPROP I INTEGER — Number of propertiesNPOINT I INTEGER — Number of profile pointsPNAMES O CHARACTER*12 NPROP Property names. See

Chapter 11 for adescription.

POSIDS O CHARACTER*32 NPOINT Position namesIERR O INTEGER — Error flag (0=No error)† I = Input to subroutine

O = Output from subroutine

Listing ProfileProperties

8-6 •••• Pressure Relief Subroutines Aspen Plus 11.1 Summary File Toolkit

Call subroutine TKPSSR to retrieve the scalar dynamic results forpressure relief blocks.

Calling Sequence for TKPSSRCALL TKPSSR (PRID, NSCAL, PNAMES, ITYPES,

IVALS, CVALS, DVALS, RVALS, TYPES,LABELS, IERR)

Argument List Descriptions for TKPSSRVariable I/O † Type Dimension Description

PRID I CHARACTER*(*) — Block IDNSCAL I INTEGER — Number of scalar resultsPNAMES O CHARACTER*12 NSCAL Property name. See Chapter

11 for a description.ITYPES O INTEGER NSCAL Data type of result

(1=Integer 2=Real 3=Character 4=Description)

IVALS O INTEGER NSCAL Integer property valuesCVALS O CHARACTER*12 NSCAL Character property valuesDVALS O CHARACTER*32 NSCAL Descriptive property valuesRVALS O REAL*8 NSCAL Real property valuesTYPES O CHARACTER*12 NSCAL Units typeLABELS O CHARACTER*16 NSCAL Units labelIERR O INTEGER — Error flag (0=No error)† I = Input to subroutine

O = Output from subroutine

Call subroutine TKPSSS to retrieve steady-state scalar results.

Calling Sequence for TKPSSSCALL TKPSSS (PRID, NSCAL, PNAMES, ITYPES,

NPOINT, IVALS, CVALS, DVALS, RVALS,TYPES, LABELS, IERR)

Argument List Descriptions for TKPSSSVariable I/O † Type Dimension Description

PRID I CHARACTER*(*) — Block IDNSCAL I INTEGER — Number of scalar resultsPNAMES O CHARACTER*12 NSCAL Property name. See Chapter

11 for a description.

Retrieving DynamicScalar Results

Retrieving Steady-State Scalar Results

Aspen Plus 11.1 Summary File Toolkit Pressure Relief Subroutines •••• 8-7

Variable I/O † Type Dimension Description

ITYPES O INTEGER NSCAL Data type of result(1=Integer 2=Real 3=Character 4=Description)

IVALS O INTEGER NSCAL Integer property valuesCVALS O CHARACTER*8 NSCAL Character property valuesDVALS O CHARACTER*32 NSCAL Descriptive property valuesRVALS O REAL*8 NSCAL Real property valuesTYPES O CHARACTER*12 NSCAL Units typeLABELS O CHARACTER*16 NSCAL Units labelIERR O INTEGER — Error flag (0=No error)† I = Input to subroutine

O = Output from subroutine

Call subroutine TKPSR1 to retrieve profiles for non-component-dependent properties. The results are independent of the substream.

Calling Sequence for TKPSR1CALL TKPSR1 (PRID, PNAME, NPOINT, ITYPES,

CVALS, RVALS, TYPE, LABEL, IERR)

Argument List Descriptions for TKPSR1Variable I/O † Type Dimension Description

PRID I CHARACTER*(*) — Block IDPNAME I CHARACTER*12 — Property name. See

Chapter 11 for a list ofvalid property names.

NPOINT I INTEGER — Number of outputpoints

ITYPES O INTEGER — Data type of results(2=Real 3=Character)

CVALS O CHARACTER*8 NPOINT Character propertyvalues

RVALS O REAL*8 NPOINT Property valuesTYPE O CHARACTER*12 — Units typeLABEL O CHARACTER*16 — Units labelIERR O INTEGER — Error flag (0=No error)† I = Input to subroutine

O = Output from subroutine

Retrieving Non-Component-Dependent DynamicProfiles

8-8 •••• Pressure Relief Subroutines Aspen Plus 11.1 Summary File Toolkit

Call subroutine TKPSR2 to retrieve profiles for component-dependent properties.

Calling Sequence for TKPSR2CALL TKPSR2 (PRID, PNAME, SUBSID, NCP, COMPID,

NPOINT, RVALS, TYPE, LABEL, IERR)

Argument List Descriptions for TKPSR2Variable I/O † Type Dimension Description

PRID I CHARACTER*(*) — Block IDPNAME I CHARACTER*12 — Property name. See Chapter 11

for a list of valid property names.SUBSID I CHARACTER*8 — Substream IDNCP I INTEGER — Number of components presentCOMPID O CHARACTER*8 NCP Component IDsNPOINT I INTEGER — Number of output pointsRVALS O REAL*8 NCP*

NPOINTProperty values

TYPE O CHARACTER*12 — Units typeLABEL O CHARACTER*16 — Units labelIERR O INTEGER — Error flag (0=No error)† I = Input to subroutine

O = Output from subroutine

Call subroutine TKPSS1 to retrieve profiles for the steady-stateresults.

Calling Sequence for TKPSS1CALL TKPSS1 (PRID, PNAME, NPOINT, RVALS, TYPE,

LABEL, IERR)

Argument List Descriptions for TKPSS1Variable I/O † Type Dimension Description

PRID I CHARACTER*(*) — Block IDPNAME I CHARACTER*12 — Property name. See Chapter 11

for a list of valid property names.NPOINT I INTEGER — Number of output pointsRVALS O REAL*8 NPOINT Property valuesTYPE O CHARACTER*12 — Units typeLABEL O CHARACTER*16 — Units labelIERR O INTEGER — Error flag (0=No error)† I = Input to subroutine

O = Output from subroutine

Retrieving DynamicComponent-Dependent Profiles

Retrieving Steady-State Profiles

Aspen Plus 11.1 Summary File Toolkit Pressure Relief Subroutines •••• 8-9

Call subroutine TKPAPF to determine the sizes of profile arraysfor the vent accumulator. TKPAPF returns the number of:• Output points• Components present• Properties

Calling Sequence for TKPAPFCALL TKPAPF (PRID, NPOINT, NCP, NPROP)

Argument List Descriptions for TKPAPFVariable I/O † Type Dimension Description

PRID I CHARACTER*(*) — Block IDNPOINT O INTEGER — Number of output pointsNCP O INTEGER — Number of components

presentNPROP O INTEGER — Number of properties† I = Input to subroutine

O = Output from subroutine

Call subroutine TKPAPR to list the vent accumulator profileproperties. TKPAPR returns an array of property names, and anarray indicating whether the property is component-dependent.

Calling Sequence for TKPAPRCALL TKPAPR (PRID, NPROP, ITYPES, PNAMES, IERR)

Argument List Descriptions for TKPAPRVariable I/O † Type Dimension Description

PRID I CHARACTER*(*) — Block IDNPROP I INTEGER — Number of propertiesITYPES O INTEGER NPROP Property type

(1=Non-component-dependent

2=Component-dependent)

PNAMES O CHARACTER*12 NPROP Property names. SeeChapter 11 for adescription.

IERR O INTEGER — Error flag (0=No error)† I = Input to subroutine

O = Output from subroutine

Determining VentAccumulator ProfileDimensions

Listing VentAccumulator ProfileProperties

8-10 •••• Pressure Relief Subroutines Aspen Plus 11.1 Summary File Toolkit

Call subroutine TKPAR1 to retrieve vent accumulator profiles fornon-component-dependent properties. The corresponding times foreach profile point are retrieved using the property name TIME.

Calling Sequence for TKPAR1CALL TKPAR1 (PRID, PNAME, NPOINT, RVALS, TYPE,

LABEL, IERR)

Argument List Descriptions for TKPAR1Variable I/O † Type Dimension Description

PRID I CHARACTER*(*) — Block IDPNAME I CHARACTER*12 — Property name. See

Chapter 11 for a list ofvalid property names.

NPOINT I INTEGER — Number of output pointsRVALS O REAL*8 NPOINT Property valuesTYPE O CHARACTER*12 — Units typeLABEL O CHARACTER*16 — Units labelIERR O INTEGER — Error flag (0=No error)† I = Input to subroutine

O = Output from subroutine

Call subroutine TKPAR2 to retrieve vent accumulator profiles forcomponent-dependent properties. The corresponding times foreach profile point are retrieved using the property name TIME inTKPAR1.

Calling Sequence for TKPAR2CALL TKPAR2 (PRID, PNAME, NCP, COMPID, NPOINT,

RVALS, TYPE, LABEL, IERR)

Argument List Descriptions for TKPAR2Variable I/O † Type Dimension Description

PRID I CHARACTER*(*) — Block IDPNAME I CHARACTER*12 — Property name. See

Chapter 11 for a list ofvalid property names.

NCP I INTEGER — Number of componentspresent

COMPID O CHARACTER*8 NCP Component IDsNPOINT I INTEGER — Number of output pointsRVALS O REAL*8 NCP*

NPOINTProperty values

TYPE O CHARACTER*12 — Units type

Retrieving Non-Component-Dependent VentAccumulator Profiles

RetrievingComponent-Dependent VentAccumulator Profiles

Aspen Plus 11.1 Summary File Toolkit Pressure Relief Subroutines •••• 8-11

Variable I/O † Type Dimension Description

LABEL O CHARACTER*16 — Units labelIERR O INTEGER — Error flag (0=No error)† I = Input to subroutine

O = Output from subroutine

Call subroutine TKPVPF to determine the sizes of the profilearrays for the vent. TKPVPF returns the number of:• Output points• Components present• Positions

Calling Sequence for TKPVPFCALL TKPVPF (PRID, NPOINT, NCP, NPROP, NPOS)

Argument List Descriptions for TKPVPFVariable I/O † Type Dimension Description

PRID I CHARACTER*(*) — Block IDNPOINT O INTEGER — Number of output pointsNCP O INTEGER — Number of components

presentNPROP O INTEGER — Number of propertiesNPOS O INTEGER — Number of positions† I = Input to subroutine

O = Output from subroutine

Call subroutine TKPVRP to list the vent profile properties.TKPVRP returns an array of property names, the correspondingtimes for each profile point, and an array indicating whether theproperty is position-dependent or component-dependent.

Calling Sequence for TKPVRPCALL TKPVRP (PRID, NPROP, ITYPES, PNAMES,

TIMES, TYPE, LABEL, IERR)

Argument List Descriptions for TKPVRPVariable I/O † Type Dimension Description

PRID I CHARACTER*(*) — Block IDNPROP I INTEGER — Number of propertiesNPOINT I INTEGER — Number of points

Determining PressureRelief Vent ProfileDimensions

Listing Vent ProfileProperties

8-12 •••• Pressure Relief Subroutines Aspen Plus 11.1 Summary File Toolkit

Variable I/O † Type Dimension Description

ITYPES O INTEGER NPROP Property type(1=Position-dependent 2= Component-

dependent)PNAMES O CHARACTER*12 NPROP Property names. See

Chapter 11 for adescription.

TIMES O REAL*8 NPOINT Time intervalsTYPE O CHARACTER*12 — Time typeLABEL O CHARACTER*16 — Time labelIERR O INTEGER — Error flag (0=No error)† I = Input to subroutine

O = Output from subroutine

Call subroutine TKPVR1 to retrieve vent profiles for properties atthe listed positions. The times for each profile point are retrieved inTKPVRP.

Calling Sequence for TKPVR1CALL TKPVR1 (PRID, PNAME, NPOINT, RVALS, TYPE,

LABEL, IERR)

Argument List Descriptions for TKPVR1Variable I/O † Type Dimension Description

PRID I CHARACTER*(*) — Block IDPNAME I CHARACTER*12 — Property name. See

Chapter 11 for a list ofvalid property names.

NPOS I INTEGER — Number of positionsPOSIDS O CHARACTER*16 NPOS Names of positionsNPOINT I INTEGER — Number of output

pointsRVALS O REAL*8 NPOS*

NPOINTProperty values

TYPE O CHARACTER*12 — Units typeLABEL O CHARACTER*16 — Units labelIERR O INTEGER — Error flag (0=No error)† I = Input to subroutine

O = Output from subroutine

Retrieving Position-Dependent VentProfiles

Aspen Plus 11.1 Summary File Toolkit Pressure Relief Subroutines •••• 8-13

Call subroutine TKPVR2 to retrieve vent profiles for component-dependent properties. The times for each profile point are retrievedin TKPVRP.

Calling Sequence for TKPVR2CALL TKPVR2 (PRID, PNAME, NCP, COMPID, NPOINT,

RVALS, TYPE, LABEL, IERR)

Argument List Descriptions for TKPVR2Variable I/O † Type Dimension Description

PRID I CHARACTER*(*) — Block IDPNAME I CHARACTER*12 — Property name. See Chapter

11 for a list of validproperty names.

NCP I INTEGER — Number of componentspresent

COMPID O CHARACTER*8 NCP Component IDsNPOINT I INTEGER — Number of output pointsRVALS O REAL*8 NCP*

NPOINTProperty values

TYPE O CHARACTER*12 — Units typeLABEL O CHARACTER*16 — Units labelIERR O INTEGER — Error flag (0=No error)† I = Input to subroutine

O = Output from subroutine

RetrievingComponent-Dependent VentProfiles

8-14 •••• Pressure Relief Subroutines Aspen Plus 11.1 Summary File Toolkit

Aspen Plus 11.1 Summary File Toolkit Examples •••• 9-1

Examples

This chapter presents a series of examples to illustrate thedevelopment and use of an application program using theSummary File Toolkit:

Example Title

1 Stream Heat and Material Balance Table Generation2 Interactive Heating/Cooling Curve Table Generation3 Column Profile Results Written to Plot File4 Distillation Column Diagram Generation

The Fortran source code for these examples is in the Engine\userdirectory of the Aspen Plus installation.

A summary file (sftex.sum) and the input file used to generate it(sft.inp) are also in the same directory.

9-2 •••• Examples Aspen Plus 11.1 Summary File Toolkit

Example 1: Stream Heat and MaterialBalance Table GenerationThis example retrieves stream results from the summary file. Bothstandard stream results and property set results are retrieved. Theresults are written to a file in table format.

The toolkit routines used in this program require a variety ofcharacter variables and arrays. Space is needed to store resultsretrieved from the toolkit routines. This program assumes only 5streams per printed page of the table, 1000 properties at most foreach stream, and a maximum of 100 components.

CC Variable declarations; reals are double precision.C

IMPLICIT REAL*8 (A-H, O-Z)CHARACTER*80 SUMFIL, RCPROP, RCUNIT, ASPDIRCHARACTER UNISET*4, VERSN*20, RUNID*8, DATE*80, INFILE*80,+ ID*8, TYPE*12, IDS*8, QUALS*16, TYPES*12, LABELS*16,+ OLDNAM*16, PLUS*16, EXCL*16, PNAMES*12, SSID*8,+ COMPID*8, PHASE*8, WETDRY*4, BASIS*4, OLDPHS*8, KFF*1,+ OLDLAB*16, SOURCE*8, DEST*8

CC Dimension arrays for the toolkit routines.C Arrays are dimensioned for 5 streams, 1000 properties,C and 100 components.C

DIMENSION QUALS(4,1000), TYPES(1000), LABELS(1000), PNAMES(1000),+ SSID(1000), COMPID(1000), PHASE(1000), WETDRY(1000),+ BASIS(1000)DIMENSION SVALS(1000, 5), IDS(5)DIMENSION XMW(100)

Declaring Variablesand Dimensioning

Aspen Plus 11.1 Summary File Toolkit Examples •••• 9-3

The executable section of the application program begins byinitializing the summary file toolkit. The steps are:1 Get the name of the Aspen Plus Simulation Engine directory

by prompting the user.2 Get the name of the summary file by prompting the user.3 Call TKINIT to perform the initialization.

CC Begin executable code.CC Get file names for the toolkit.CC Get rcpropnu.dat and rcunits.dat by prompting the userC for the name of the directory where the Aspen PlusC Simulation Engine is installed.C

WRITE(6, *) ' Enter the Aspen Plus Simulation Engine' //+ 'directory name: 'READ(5, FMT='(A)') ASPDIRDO 50 LEN = 80, 1, -1

IF (ASPDIR(LEN:LEN) .NE. ' ') GO TO 5550 CONTINUE55 CONTINUE

RCPROP = ASPDIR(1:LEN) // '\toolkit\rcpropnu.dat'RCUNIT = ASPDIR(1:LEN) // '\toolkit\rcunits.dat'

CC Prompt the user for the name of the summary file:C

WRITE(6, *) ' Enter the summary file name: 'READ(5, FMT='(A)') SUMFIL

C --------------------------------------------------------CC Open the summary file and call TKINIT to initializeC the toolkit. If there is an error, end execution.C

OPEN(UNIT=2, FILE=SUMFIL, STATUS='UNKNOWN')CALL TKINIT(UNISET, 1, 2, 3, RCPROP, 4, RCUNIT, RMISS, IERR)IF (IERR .NE. 0) GO TO 9999

To find the streams, TKINFO is called to determine the number ofsimulation objects in the summary file. The variable NSTRM is thetotal number of streams.

C Get the number of streams by calling TKINFO.C

CALL TKINFO(VERSN, RUNID, DATE, INFILE, ISTAT, IWORK,+ NBLK, NSTRM, NTABLE, NSENS )

Initializing the Toolkit

Finding Number ofStreams

9-4 •••• Examples Aspen Plus 11.1 Summary File Toolkit

For component-dependent properties, the molecular weight iswritten for each component in the table. Molecular weight isretrieved by calling TKCOMP to determine the number ofconventional components, and TKCPRP to retrieve the propertyvalues.

CC Get the number of components and molecular weight values.C

CALL TKCOMP(NCC, NNCC)PNAMES(1) = 'MW'CALL TKCPRP(PNAMES, NCC, XMW, LABELS)

For each material stream, both standard and property set results areretrieved. TKSINF determines the dimensions of the standardresults, and TKSTRM retrieves them. For property set results,TKNSPR determines the number of results, and TKSPRP retrievesthem.

CC Call TKSINF and TKSTRM to retrieve the basic stream results.C

CALL TKSINF(ID, SOURCE, DEST, NSUBS, LEN, IERR)CALL TKSTRM(ID, LEN, QUALS, SVALS(1, NPPG), TYPES, LABELS,

+ IERR)CC If an error occurred retrieving the results, skip this stream.C

IF (IERR .NE. 0) THENWRITE(6, *) ' ERROR ON STREAM ',IDNPPG = NPPG - 1GO TO 1000

ENDIFCC Call TKNSPR and TKSPRP to retrieve the property sets.C Check for an error, and skip this stream if one occurs.C

CALL TKNSPR(ID, NPROP, IERR)IF (IERR .NE. 0) THEN

WRITE(6, *) ' ERROR ON STREAM ',IDNPPG = NPPG - 1GO TO 1000

ENDIFLL = LEN + 1CALL TKSPRP(ID, NPROP, PNAMES, SSID, PHASE, COMPID,

+ WETDRY, BASIS, SVALS(LL, NPPG), TYPES(LL),+ LABELS(LL), IERR)

Finding ComponentMolecular Weight

Retrieving StreamProperties

Aspen Plus 11.1 Summary File Toolkit Examples •••• 9-5

Writing Stream TableEvery five streams, or when the last stream is processed, the tableis written to the file hmbtable.out. The standard results are writtenfirst; the molecular weight associated with each component iswritten with the first component-dependent property. The propertysets follow the standard results. An example of one page of outputis shown in Figure 8.1.

CC If this is the 5th stream, or the last stream, write theC table for the set of streams.C

IF (NPPG .NE. 5 .AND. I .NE. NSTRM) GO TO 1000WRITE(7, 30) KFFWRITE(7, 31) (PLUS,II=1,NPPG), EXCLWRITE(7, 10) (IDS(II),II=1,NPPG)WRITE(7, 31) (PLUS,II=1,NPPG), EXCLOLDNAM = ' 'ICOMP = 1

CC Loop through the basic stream properties. Check to see if eachC is component-dependent.C

DO 500 J = 1, LENCC For non-component-dependent properties, write the name,C the unit label, and the values.C

IF (QUALS(3,J) .EQ. ' ') THENWRITE(7, 20) QUALS(1,J), LABELS(J),

+ (SVALS(J,JJ),JJ=1,NPPG)WRITE(7, 31) (PLUS,II=1,NPPG), EXCLOLDNAM = QUALS(1,J)

ELSECC For component-dependent properties, write the name if theC previous name is different.C

IF (QUALS(1,J) .NE. OLDNAM)+ WRITE(7, 21) QUALS(1,J),LABELS(J),(EXCL,II=1,NPPG),EXCL

OLDNAM = QUALS(1,J)IF (ICOMP .GT. NCC) THEN

CC Write the molecular weight with the component nameC if this is the first component-dependent property.C

WRITE(7, 22) QUALS(3,J), (SVALS(J,JJ),JJ=1,NPPG)ELSE

WRITE(7, 23) QUALS(3,J), XMW(ICOMP),+ (SVALS(J,JJ),JJ=1,NPPG)

ENDIFIEND = MOD(ICOMP, NCC)IF (IEND .EQ. 0) WRITE(7, 31) (PLUS,II=1,NPPG), EXCLICOMP = ICOMP + 1

ENDIF500 CONTINUE

9-6 •••• Examples Aspen Plus 11.1 Summary File Toolkit

CC Loop through the PROP-SET properties. The properties areC sorted by phase. If the current phase is different fromC the previous phase, then print a new phase header.C

OLDNAM = ' 'OLDPHS = ' 'OLDLAB = ' 'IFIRST = 1DO 600 J = 1, NPROP

L = J + LENIF (PHASE(J) .NE. OLDPHS) THEN

C First item is already preceded by a lineIF (IFIRST .EQ. 0) THEN

WRITE(7, 31) (PLUS,II=1,NPPG), EXCLELSE

IFIRST = 0ENDIF

WRITE(7, 40) PHASE(J), (EXCL,II=1,NPPG), EXCLENDIF

CC Check for a component qualifier on the property.C

IF (COMPID(J) .EQ. ' ') THENWRITE(7, 31) (PLUS,II=1,NPPG), EXCLWRITE(7, 20) PNAMES(J), LABELS(L),

+ (SVALS(L,JJ),JJ=1,NPPG)OLDNAM = PNAMES(J)OLDLAB = LABELS (L)

ELSECC For component-dependent properties, write the name forC the set of components only once.C

IF (PNAMES(J) .NE. OLDNAM .OR. LABELS(L) .NE. OLDLAB) THENWRITE(7, 31) (PLUS,II=1,NPPG), EXCL

+ WRITE(7, 21) PNAMES(J),LABELS(L),(EXCL,II=1,NPPG),EXCLENDIFOLDNAM = PNAMES(J)OLDLAB = LABELS(L)WRITE(7, 22) COMPID(J), (SVALS(L,JJ),JJ=1,NPPG)ENDIFOLDPHS = PHASE(J)

600 CONTINUEC Underline the final item

WRITE(7,31) (PLUS, II=1, NPG), EXCL

Aspen Plus 11.1 Summary File Toolkit Examples •••• 9-7

Figure 8.1 – Stream Table Results ExcerptVAP LIQ H2RCY CHRCY PRODUCT

MOLEFLOW KMOL/HR

H2 (MW = 2.02) 13.663 0.25941 12.570 0.77824E-01 0.38241E-11N2 (MW = 28.01) 6.7132 0.23753 6.1762 0.71260E-01 0.14270E-10C1 (MW = 16.04) 17.519 2.0170 16.118 0.60509 0.13065E-07BZ (MW = 78.11) 0.11318E-02 0.89643E-01 0.10412E-02 0.26893E-01 0.62739E-01CH (MW = 84.16) 0.78883 64.619 0.72573 19.386 45.229MOLEFLMX KMOL/HR 38.686 67.222 35.591 20.167 45.291MASSFLMX KG/HR 563.14 5485.0 518.09 1645.5 3811.4VLSTDMX L/MIN 805.90 131.48 741.43 39.445 123.98TEMP K 322.04 322.04 322.04 322.04 474.15PRES ATM 21.094 21.094 21.094 21.094 13.609VFRAC 1.0000 0.00000E+00 1.0000 0.00000E+00 0.00000E+00LFRAC 0.00000E+00 1.0000 0.00000E+00 1.0000 1.0000SFRAC 0.00000E+00 0.00000E+00 0.00000E+00 0.00000E+00 0.00000E+00HMX CAL/MOL -8542.1 -35492. -8542.1 -35492. -29055.HMX CAL/GM -586.81 -434.98 -586.81 -434.98 -345.26HMX CAL/SEC -91794. -0.66274E+06 -84450. -0.19882E+06 -0.36554E+06SMX CAL/MOL-K -14.579 -138.84 -14.579 -138.84 -125.29SMX CAL/GM-K -1.0016 -1.7016 -1.0016 -1.7016 -1.4888RHOMX MOL/CC 0.80005E-03 0.85210E-02 0.80005E-03 0.85210E-02 0.60884E-02RHOMX GM/CC 0.11646E-01 0.69527 0.11646E-01 0.69527 0.51236MWMX 14.557 81.595 14.557 81.595 84.154

** VAPOR PHASE **

DMXH2 0.35103E-01 0.10000E+36 0.35103E-01 0.10000E+36 0.10000E+36N2 0.16453E-01 0.10000E+36 0.16453E-01 0.10000E+36 0.10000E+36C1 0.19524E-01 0.10000E+36 0.19524E-01 0.10000E+36 0.10000E+36BZ 0.69972E-02 0.10000E+36 0.69972E-02 0.10000E+36 0.10000E+36CH 0.67625E-01 0.10000E+36 0.67625E-01 0.10000E+36 0.10000E+36MUMX 0.13021E-01 0.10000E+36 0.13021E-01 0.10000E+36 0.10000E+36

** LIQUID PHASE **

DMX SQCM/SECH2 0.10000E+36 0.11111E-03 0.10000E+36 0.11111E-03 0.41453E-03N2 0.10000E+36 0.99235E-04 0.10000E+36 0.99235E-04 0.36919E-03C1 0.10000E+36 0.91460E-04 0.10000E+36 0.91460E-04 0.35104E-03BZ 0.10000E+36 0.54343E-04 0.10000E+36 0.54343E-04 0.20117E-03CH 0.10000E+36 0.20065E-03 0.10000E+36 0.20065E-03 0.14933E-03MUMX CP 0.10000E+36 0.25699 0.10000E+36 0.25699 0.10380

9-8 •••• Examples Aspen Plus 11.1 Summary File Toolkit

Example 2: InteractiveHeating/Cooling Curve TableGenerationThis example retrieves heating/cooling curve results from unitoperation blocks. The summary file is queried for a list of blockscontaining curve results. This example uses a toolkit utility routineTKUPPR, that takes a character string as an argument anduppercases it. A sample of the program dialog is shown in Figure8.2. A sample of the output is shown in Figure 8.3.

Declarations and dimensions are similar to those in Example 1. Butin this example, the paths for the properties and units files arecoded into the program.

CC Data statementsC

DATA UNISET / 'ENG' /DATA PLUS / '-----------------+' /DATA EXCL / '-----------------!'/DATA RMISS / 1.0D35 /DATA RCPROP / 'C:\Aspen Plus\Engine\Toolkit\RCPROPNU.DAT' /DATA RCUNIT / 'C:\Aspen Plus\Engine\Toolkit\RCUNITS.DAT' /

The user is prompted for the name of the summary file. Thesummary file must be opened before TKINIT is called.

CC Prompt the user for the name of the summary file.C

WRITE(6, *) ' Enter the summary file name: 'READ(5, FMT='(A)') SUMFIL

CC Open the summary file and call TKINIT to initializeC the toolkit. If there is an error, end execution.C

OPEN(UNIT=2, FILE=SUMFIL, STATUS='UNKNOWN')CALL TKINIT(UNISET, 1, 2, 3, RCPROP, 4, RCUNIT, RMISS, IERR)IF (IERR .NE. 0) GO TO 9999

Declaring Variables

Initializing the Toolkit

Aspen Plus 11.1 Summary File Toolkit Examples •••• 9-9

The number of blocks is determined by calling TKINFO.

CC Get the number of blocks by calling TKINFO.C

CALL TKINFO(VERSN, RUNID, DATE, INFILE, ISTAT, IWORK,+ NBLK, NSTRM, NTABLE, NSENS )

One method of listing the blocks is to loop through them by callingTKNBLK. This allows a check of each block for the existence ofheating/cooling curves.

CC Prompt the user to have Hcurves checked for the block.C To check for Hcurves, loop through all the blocks by callingC TKNHCV.C If the block has an Hcurve, load its ID and model type into theC ID arrays.C100 CONTINUE

NITEM = 0NSET = 0DO 200 I = 1, NBLK

I1 = NITEM + 1CALL TKNBLK(I, ID8(I1), ID12(I1), IERR)IF (IERR .NE. 0) GO TO 200CALL TKNHCV(ID8(I1), NCURVE)IF (NCURVE .EQ. 0) GO TO 200NITEM = NITEM + 1

CC If there are more than 100 blocks with Hcurves,C the work area will be filled. Write the first 100 blocks toC the list.C

IF (NITEM .LT. 100 .OR. I .EQ. NBLK) GO TO 200IF (NSET .EQ. 0) THEN

WRITE(6, *) ' The following blocks contain Hcurve results:'WRITE(6, *) ' Block ID Model'WRITE(6, *) ' ======================='

ENDIFDO 190 J = 1, NITEM

WRITE(6, FMT='(1X,A8,2X,A12)') ID8(J), ID12(J)190 CONTINUE

IF (I .NE. NBLK) NSET = 1NITEM = 0

200 CONTINUECC If there are any unwritten entries in the list, write the listC of blocks with Hcurves.C

IF (NITEM .NE. 0) THENIF (NSET .EQ. 0) THEN

WRITE(6, *) ' The following blocks contain Hcurve results:'WRITE(6, *) ' Block ID Model'WRITE(6, *) ' ======================='

ENDIFDO 210 J = 1, NITEM

WRITE(6, FMT='(1X,A8,2X,A12)') ID8(J), ID12(J)210 CONTINUE

ENDIF

Finding Number ofBlocks

Finding Blocks withHeating/CoolingCurves

9-10 •••• Examples Aspen Plus 11.1 Summary File Toolkit

When the blocks with heating/cooling curves are listed, prompt theuser for the block IDs. Since all IDs in the summary file are inuppercase, user-specified IDs must be converted to uppercase.TKNHCV is called for each ID, to check whether or not a valid IDhas been entered.

CC Prompt the user for the block to be checked;C remember to convert the block ID to uppercase.C

WRITE(6, *) ' 'WRITE(6, *) ' Please select a block from the list:'READ(5, FMT='(A)') ID

C Uppercase the response using a toolkit utility routineCALL TKUPPR (ID)CALL TKNHCV(ID, NCURVE)IF (NCURVE .LE. 0) THEN

WRITE(6, *) ' ',ID,' is not a valid block ID.'WRITE(6, *) ' Please select again.'GO TO 100

ENDIF

Once a valid block ID is given, the heating/cooling curves in theblock are listed by calling TKLHCV. The routine CHKREP checksthat an integer is specified for the heating/cooling curve ID.

CC For a valid block with Hcurve data, print a list ofC the Hcurves for the block.C240 CONTINUE

WRITE(6, *) ' ',ID,' contains the following Hcurves:'WRITE(6, *) ' ID Type Hcurve No.'WRITE(6, *) ' ======================='CALL TKLHCV(ID, NCURVE, ID16, INTS, IERR)DO 250 I = 1, NCURVE

WRITE(6, FMT='(1X,I2,2X,A16,1X,I4)') I, ID16(I), INTS(I)250 CONTINUE

WRITE(6, *) ' Please select an Hcurve by specifying its ID:'READ(5, '(A4)') REPLYCALL CHKREP (REPLY, II, ISTAT)IF ( ISTAT .EQ. 1 ) THEN

WRITE(6, *)'"',REPLY,'" is not an integer. Please select again:'GO TO 240

ENDIFIF (II .LE. 0 .OR. II .GT. NCURVE) THEN

WRITE(6, *) '"',II,'" is not a valid ID. Please select again:'GO TO 240

ENDIF

Prompting for BlockName

FindingHeating/CoolingCurves for SelectedBlock

Aspen Plus 11.1 Summary File Toolkit Examples •••• 9-11

TKSHCV checks the dimensions of the data for the curve that isselected. If the dimensions are larger than the arrays aredimensioned, an exit with an error may occur.

CC For a specific Hcurve, get its size, andC print the standard properties.C

IHCNO = INTS(II)CALL TKSHCV(ID, ID16(II), IHCNO, NPOINT, NPROP)

CC The TVAL array is dimensioned for 100 points and 100C properties.C That means only 99 stream properties can be stored. If thereC are more than 99, or more than 100 points, print error.C

IF (NPROP .GT. 99 .OR. NPOINT .GT. 100) THENWRITE(6, *) ' *** Error - This Hcurve is too large ***'GO TO 700

ENDIF

This program allows the user to choose one of the standard results(temperature, pressure, heat duty, or vapor fraction) as theindependent variable in the table. The table of these standardresults is written, so the user can choose one of them. TKHCRV iscalled to retrieve the standard results.

CC Call TKHCRV to get the standard properties.C

CALL TKHCRV(ID, ID16(II), IHCNO, NPOINT, INTS, TVAL(1,1),+ TVAL(1,2), TVAL(1,3), TVAL(1,4), IERR)

CC Get unit label information for standard properties.C

TYPES(1) = 'TEMPERATURE'TYPES(2) = 'PRESSURE'TYPES(3) = 'ENTHALPY-FLOW'CALL TKLABL(3, TYPES, LABELS)LABELS(4) = LABELS(3)LABELS(3) = ' '

CC Write the table of standard results, so that the user canC select an independent variable.C

WRITE(6, 31) (PLUS,JJ=1,3),EXCLWRITE(6, 10) (PROPS(JJ),JJ=1,4)WRITE(6, 10) (LABELS(JJ),JJ=1,4)WRITE(6, 31) (PLUS,JJ=1,3),EXCLDO 500 I = 1, NPOINT

WRITE(6, 20) (TVAL(I,JJ),JJ=1,4)500 CONTINUE

WRITE(6, 31) (PLUS,JJ=1,3),EXCL

Finding Dimensionsof Heating/CoolingCurve

Retrieving StandardHeating/CoolingCurve Results

9-12 •••• Examples Aspen Plus 11.1 Summary File Toolkit

The user is prompted for the property sets to be included in thetable. TKNHPR is called to retrieve the name of the propertieswith their qualifiers, and to retrieve the values.

CC Loop through the property sets to create a list ofC properties for the user to choose from. Store the propertiesC in the TVAL array.C

WRITE(6, *) ' Select properties from the following list:'WRITE(6, *) ' ID Property Phase Component'WRITE(6, *) ' ==============================='DO 600 I = 1, NPROP

CALL TKNHPR(ID, ID16(II), IHCNO, NPOINT, I,+ PNAMES(I+1), SSID, PHASE(I+1), COMPID(I+1), WETDRY,+ BASIS, TVAL(1,I+1), TYPES(I+1), LABELS(I+1), IERR)

WRITE(6, 11) I, PNAMES(I+1), PHASE(I+1), COMPID(I+1)600 CONTINUE

NCOL = 2605 CONTINUE

WRITE(6, *) ' Please enter the ID number of the property:'READ(5, '(A4)') REPLYCALL CHKREP (REPLY, JCOL, ISTAT)IF ( ISTAT .EQ. 1 ) THEN

WRITE(6, *)'"',REPLY,'" is not an integer. Please select again:'GO TO 605

ENDIFIF (JCOL .LT. 1 .OR. JCOL .GT. NPROP) THEN

WRITE(6, *) ' "',JCOL,'" is not a valid ID'GO TO 605

ENDIFICOL(NCOL) = JCOL + 1WRITE(6, *) ' Do you want another property (Y/N)?'INFILE = ' 'READ(5, FMT='(A)') INFILE

C Uppercase the response using a toolkit utility routineCALL TKUPPR(INFILE)

After the user has chosen the properties to be tabulated, they arewritten to the file hcurve.out.

Figure 8.2 Example 2 Program DialogEnter the summary filename:MANU.SUMThe following blocks contain Hcurve results:

Block ID Model

FEED-MIX HEATERHP-SEP FLASH2

Retrieving PropertySets

Aspen Plus 11.1 Summary File Toolkit Examples •••• 9-13

Please select a block from the list:FEED-MIXFEED-MIX contains the following Hcurves:

ID Type Hcurve No.

1 HCURVE 12 HCURVE 2

Select an Hcurve by specifying its ID.

TEMPERATURE(F)

PRESSURE(PSI)

VAPORFRACTION

DUTY(BTU/HR)

103.76 330.00 0.73446 0.00000E+00156.99 330.00 0.75237 0.52969E+06198.86 330.00 0.78232 0.10594E+07231.90 330.00 0.82372 0.15891E+07258.28 330.00 0.87527 0.21188E+07279.65 330.00 0.93567 0.26485E+07296.36 330.00 1.0000 0.31507E+07300.00 330.00 1.0000 0.31782E+07

Specify the independent variable –either TEMP, PRES, VFRAC, or DUTY.

TEMPSelect properties from the following list:

ID Property Phase Component

1 KMX VAPOR2 KMX LIQUID3 MUMX VAPOR4 MUMX LIQUID

Enter the ID number of the property.1

Do you want another property (Y/N)?Y

Enter the ID number of the property.3

Do you want another property (Y/N)?N

Do you want to generate another table (Y/N)?N

9-14 •••• Examples Aspen Plus 11.1 Summary File Toolkit

Figure 8.3 Sample Output File hcurve.out

Temperature(F)

KMX Vapor(BTU-FT/HR-SQFT-R)

MUMX Vapor(CP)

103.76 0.72312E-01 0.10226E-01156.99 0.71705E-01 0.11065E-01198.86 0.67680E-01 0.11734E-01231.28 0.62145E-01 0.12190E-01258.28 0.56470E-01 0.12467E-01279.65 0.51312E-01 0.12626E-01296.36 0.47088E-01 0.12712E-01300.00 0.47323E-01 0.12763E-01

Example 3: Column Profile ResultsWritten to Plot FileThis example demonstrates retrieving column profile results andwriting the results to a plot file. The program prompts the user forthe property to be retrieved, along with labels for the axes.

The first step is to identify the file names. The properties and unitsfiles are in the TOOLKIT subdirectory of the Aspen Plussupplemental directory on Windows systems. The environmentvariable ASPTOP points to this top level directory. Theenvironment variable XSUM is used in this example to pass thename of the summary file into the program. Both environmentvariables are decoded using the subroutine GETENV.The following example uses subroutine TKOPEN to open thesummary file. You must use TKOPEN if the summary file toolkitDLL is called. The plot file is not written by the summary filetoolkit DLL, and therefore does not use TKOPEN.

Opening Files andInitializing Toolkit

Aspen Plus 11.1 Summary File Toolkit Examples •••• 9-15

C Open the plot file as HYDRAUL.PLF.C

OPEN(UNIT=7,FILE='HYDRAUL.PLF', STATUS='UNKNOWN')CC Set file names and unit set.C

CALL GETENV('ASPTOP',ASPTOP)DO 55 I = 255, 1, -1

IF (ASPTOP(I:I) .NE. ' ') THENILEN = IGO TO 56

ENDIF55 CONTINUE56 CONTINUE

RCPROP = ASPTOP(1:ILEN) // '\TOOLKIT\RCPROPNU.DAT'RCUNIT = ASPTOP(1:ILEN) // '\TOOLKIT\RCUNITS.DAT'UNISET = 'ENG'

CC Read the summary file name from the environment variable XSUM.C

CALL GETENV ('XSUM', SUMFIL)C Open the summary file with TKOPEN.

ACCESS = 'SEQUENTIAL'FORM = 'FORMATTED'MODE = 'READ'STATUS = 'OLD'CALL TKOPEN(1, SUMFIL, ACCESS, FORM, 80, STATUS, MODE, IERR)

CC Call TKINI2 to initialize the toolkit.C

XMISS = 1D35CALL TKINI2(UNISET,2,1,3,RCPROP,4,RCUNIT,XMISS,IERR, 6)

One option for listing the blocks is calling TKBIDS to return thelist of block IDs and block types. The block types array can bechecked for the correct type before prompting the user for theblock ID.

C Call TKINFO to get the number of blocks, and TKBIDS toC get the list. Allow the user to choose from RADFRAC blocks.C

CALL TKINFO(VERSN , RUNID , DATE , INFILE, ISTAT , IWORK ,+ NBLK , NSTRM , NTABLE, NSENS )CALL TKBIDS(NBLK, BLKID, BLKTYP, IERR)

100 CONTINUEWRITE(6, *) 'Select a block from the following list:'WRITE(6, *) '---------------------------------------'DO 110 I = 1, NBLK

IF (BLKTYP(I) .NE. 'RADFRAC') GO TO 110WRITE(6, *) BLKID(I)

110 CONTINUE

Finding List of Blocks

9-16 •••• Examples Aspen Plus 11.1 Summary File Toolkit

This program allows the user to choose from the availableproperties for those to plot. TKPROF determines the dimensions ofthe data, including the number of properties. TKPROP lists theproperties and identifies them as component- or non-component-dependent.

CC Call TKPROF and TKPROP to get a list of properties.C

CALL TKPROF(ID,ICOL,NSTAGE,NCP,NPROP)CALL TKPROP(ID,ICOL,NPROP,ITYPES,PNAMES,IERR)

CC Prompt the user for the desired property to plot.C120 CONTINUE

WRITE(6,*) 'Choose from the following properties:'WRITE(6,*) '-------------------------------------'WRITE(6,*) ' 'ITER = ((NPROP-1/5))DO 130 I = 0,ITER

WRITE(6,*) (PNAMES(5*I+J),J=1,5)130 CONTINUE

WRITE(6,*) ' 'WRITE(6,*) 'ENTER THE ABBREVIATED NAME OF THE PROPERTY'READ(5,10) PNAME

C Uppercase the response using a toolkit utility routineCALL TKUPPR (PNAME)INDEX = 0

DO 150 I = 1,NPROPIF (PNAMES(I) .EQ. PNAME) THEN

INDEX=IGO TO 151

ENDIF150 CONTINUE

IF (INDEX .EQ. 0) THENWRITE (6,*) 'PROPERTY NAME NOT FOUND. PLEASE ENTER AGAIN.'WRITE (6,*)GO TO 120

ENDIF151 CONTINUE

Finding List ofProperties

Aspen Plus 11.1 Summary File Toolkit Examples •••• 9-17

Once the property has been selected, the data must be retrieved.The value of ITYPES for the property determines whetherTKPRO1 is called for non-component- dependent properties, orTKPRO2 for component-dependent properties.

CC Call either TKPRO1 or TKPRO2 to retrieve the results.C

IF (ITYPES(INDEX) .EQ. 1) THENCALL TKPRO1(ID,PNAME,ICOL,NSTAGE,RVALS,TYPE

+ ,LABEL,IERR)C

ELSECALL TKPRO2(ID,PNAME,ICOL,NCP,COMPID,NSTAGE,RVALS,

+ TYPE,LABEL,IERR)C

ENDIF

After the values are retrieved, they can be written to the plot file. Asample plot file is shown in Figure 8.5.

The following two steps should be used when using the DLLversion of the summary file toolkit:

1 Call TKCLOS to close the files opened by the summary filetoolkit.

2 Call TKCLFL to close the summary file.

Because the plot file was not opened with TKOPEN, close it withthe Fortran CLOSE statement directly:

C Shut down the toolkit.CALL TKCLOS (1, 2, 3, 4)

C Close summary file.CALL TKCLFL (2, IERR)

C Close the plot fileCLOSE (7)

CSTOPEND

Retrieving SelectedProperty Profile

Closing theApplication

9-18 •••• Examples Aspen Plus 11.1 Summary File Toolkit

Figure 8.4 Example 3 Program Dialog

Select a block from the following list:COLUMNPlease select a block from the list:COLUMNChoose from the following properties:

B_TEMP B_PRES DUTY LIQ_FLOW VAP_FLOWFEED_LFLOW FEED_VFLOW FEED_FLOW PROD_LFLOW PROD_VFLOWLIQ_ENTH VAP_ENTH HYD_LMF HYD_VMF HYD_LVFHYD_VVF HYD_RHOL HYD_RHOV HYD_MUL HYD_MUVHYD_STEN HYD_PARM HYD_QR HYD_MWL HYD_MWVHYD_FMIDX HYD_FFR X Y B_K

Enter the name of the propertyHYD-RHOL

Enter the titleLIQUID DENSITY VS STAGE

Enter the label for x-axisSTAGE

Enter the label for y-axisLIQUID DENSITY

Enter the first legend:DENSITY

Do you want to choose another property (Y/N)N

Aspen Plus 11.1 Summary File Toolkit Examples •••• 9-19

Figure 8.5 Sample Plot File///////////////BLOCK: COLUMN SENTENCE:PLOTNDEP NPTS LTITLE LHLABEL LVLABEL LEG1 LEG2 LEG3 LEG4 LEG51 15 12 10 10 10 0 0 0 0LIQUID DENSITY VS STAGESTAGELIQUID DENSITYDENSITY

1 45.8722 36.1303 34.7084 34.4745 34.4346 34.4277 34.4258 34.0079 32.15010 32.00011 31.98712 31.98613 31.98614 31.98615 31.986

9-20 •••• Examples Aspen Plus 11.1 Summary File Toolkit

Example 4: Distillation ColumnDiagram GenerationThis example uses the summary file toolkit to retrieve basicinformation about a distillation model. The information retrievedincludes feed and product flows, reflux and boilup ratios,condenser and reboiler duties, and stage information. These resultsare used to create an annotated diagram of the column.

The first step is getting the file names for toolkit initialization. Inthis example, the paths to the properties and units files are fixed.The summary file name is read from the file toolkit.dat.

CC Get filenames for the toolkit - rcpropnu.dat and rcunits.datC

RCPROP = 'C:\Aspen Plus\Engine\Toolkit\RCPROPNU.DAT'RCUNIT = 'C:\Aspen Plus\Engine\Toolkit\RCUNITS.DAT'

CC Open the summary file and call TKINIT to initializeC the toolkit. If there is an error, end execution.C

OPEN(UNIT=2, FILE='TOOLKIT.DAT',STATUS='UNKNOWN')READ(2,FMT='(A)') SUMFILCLOSE(2)OPEN(UNIT=2, FILE=SUMFIL, STATUS='OLD')UNISET = 'ENG'CALL TKINIT(UNISET, 1, 2, 3, RCPROP, 4, RCUNIT, RMISS, IERR)IF (IERR .NE. 0) GO TO 9999

Initializing the Toolkit

Aspen Plus 11.1 Summary File Toolkit Examples •••• 9-21

After the user has selected a block, the basic results must beretrieved. This is a two-step process:1 Call TKNRES to determine the dimensions of the data.2 Call TKBRES to retrieve the results.Four results are selected from the list of values returned byTKBRES: Q1, QN, RR, and BU_RATIO.

CC Get the basic scalar results for the column, to provideC values for Q1, QN, RR, and BR.C140 CONTINUE

CALL TKNRES(ID, NRES, NQUAL, IERR)IF (NRES .EQ. 0 .OR. IERR .NE. 0) THEN

WRITE(6, *) ' *** Error occurred in block'GO TO 9999

ENDIFIF (NQUAL .EQ. 0) NQUAL = 1CALL TKBRES(ID, NRES, NQUAL, PNAMES, QUALS, ITYPES, INTS,+ CW8, TVALS, TYPES, LABELS)

CC Search the results array for the values wanted.C

DO 150 I = 1, NRESIF (PNAMES(I) .EQ. 'RR') I1=IIF (PNAMES(I) .EQ. 'BU_RATIO') I2=IIF (PNAMES(I) .EQ. 'COND_DUTY') I3=IIF (PNAMES(I) .EQ. 'REB_DUTY') I4=IIF (PNAMES(I) .EQ. 'TOP_LFLOW') I5=IIF (PNAMES(I) .EQ. 'BOT_LFLOW') I6=I

150 CONTINUERR = TVALS(I1,1)BR = TVALS(I2,1)Q1 = TVALS(I3,1)QN = TVALS(I4,1)TVFLOW = TVALS(I5,1)BLFLOW = TVALS(I6,1)

Retrieving BasicBlock Results

9-22 •••• Examples Aspen Plus 11.1 Summary File Toolkit

To find the inlet and outlet stream flows, profile results areretrieved for the feed and product properties. TKPROF finds thedimensions of the data, and TKPROP lists the properties. TKPRO1is called to retrieve the values.

CC Call TKPROF to get the dimensions, and TKPRO1 toC get the values.C

CALL TKPROF(ID, 1, NSTAGE, NCP, NPROP)CALL TKPROP(ID,1,NPROP,ITYPES,PNAMES,IERR)PNAME = 'PROD_VFLOW'CALL TKPRO1(ID, PNAME, 1, NSTAGE, RVALS, TYPES,+ LABELS, IERR)PNAME='PROD_LFLOW'CALL TKPRO1(ID,PNAME,1,NSTAGE,RLALS,TYPES,LABELS,IERR)II = 0DO 133 I = 1,NSTAGE

IF (RVALS(I) .NE. 0.0) THENII = II + 1ISP(II) = I

ENDIFIF (RLALS(I) .NE. 0.0) THEN

II = II + 1ISP(II) = I

ENDIF133 CONTINUE

PNAMES(1) = 'FEED_LFLOW'CALL TKPRO1(ID, PNAMES, 1, NSTAGE, TVALS(1,6), TYPES,+ LABELS, IERR)PNAMES(1) = 'FEED_VFLOW'CALL TKPRO1(ID, PNAMES, 1, NSTAGE, TVALS(1,7), TYPES,+ LABELS, IERR)

Retrieving Inlet andOutlet Stream Flows

Aspen Plus 11.1 Summary File Toolkit Examples •••• 9-23

The connectivity routines are called to list the inlet and outletstreams. TKSTRM is called for each stream to determine the flowrate. The flow rate is matched against the feed or product flow todetermine the stage for each stream. The feed stream checkfollows:

CC Call the connectivity routines.C

CALL TKCNTN(ID, NIN, NOUT, IERR)CALL TKCNCT(ID, NIN, NOUT, BLKIN, TYPIN, BLKOUT, TYPOUT, IERR)

CC Feed and products are matched with stage numbers,C by matching flowrates with the streams.CC Loop through the inlet streams and get the moleflows.C

DO 200 I = 1, NININTS(I) = 0IF (TYPIN(I) .NE. 'MATERIAL') GO TO 200CALL TKSINF(BLKIN(I), SOURCE, DEST, NSUBS, LEN, IERR)CALL TKSTRM(BLKIN(I), LEN, QUALS, TVALS(1,8), TYPES,

+ LABELS, IERR)DO 160 J = 1, LEN

IJ = 4*J – 3IF (QUALS(IJ) .EQ. 'MOLEFLMX') THEN

FLOW = TVALS(J,8)FX = TVALS(J,8)L5 = LABELS(J)

ENDIF160 CONTINUE

DO 170 J = 1, NSTAGEIF (J .EQ. 1) TFLOW = TVALS(J,6)IF (J .GT. 1) TFLOW = TVALS(J,6) + TVALS(J-1,7)FDIFF = DABS(TFLOW - FLOW) / FLOWIF (FDIFF .GT. 1D-5) GO TO 170INTS(I) = JNPOS = J

170 CONTINUE200 CONTINUE

With the values retrieved, and the stages matched to the feeds andproducts, the diagram can be written. Sample output is shown inFigure 8.5.

Finding Inlet andOutlet Stream IDs

9-24 •••• Examples Aspen Plus 11.1 Summary File Toolkit

Figure 8.6 Sample Column Diagram

+-------+! ! COND-DUTY= -112659.17200 BTU/HR

+-----------+ !! +---+---+

+----+----+ !! -------+ T-PROD= 3.89 LBMOL/HR!------- !! -------!!------- ! BOILUP RATIO= 1.55! -------! REFLUX RATIO= 1.20!------- !! -------!

->+------- ! FEED = 103.74 LBMOL/HR! -------!!------- !! -------!!------- !!------- +<-----++----+----+ ! REB-DUTY= 1415130.30000 BTU/HR

! +---+----++-------+ +-------- B-PROD= 99.85 LBMOL/HR

! !+--------+

Aspen Plus 11.1 Summary File Toolkit Units •••• 10-1

Units

Table A.1 lists the most frequently used units of measurementconversion options available in Aspen Plus. A complete, up-to-datelist of all units is contained in the file units.lis in the toolkit sourcedirectory. See Chapter 1 for the directory name on all operationsystems. The entries in the table show the units labels used toidentify units of measurement. Most of the units labels in this tableare self-explanatory. Labels that may require explanation are:

Label Explanation

ATMG Atmosphere, gaugeBARG Bar, gaugeKG/SQCMG Kilogram per square centimeter, gaugeMLB Thousand poundsMMBTU Million BTUMMKCAL Million kcalMMSCF Million standard cubic ft. Standard conditions are ideal gas at 14.696 psi and 60°F.MMSCFD Million standard cubic ft/day. Standard conditions are ideal gas at 14.696 psi and 60°F.MMSCFH Million standard cubic ft/hr. Standard conditions are ideal gas at 14.696 psi and 60°F.MMSCM Million standard cubic meters. Standard conditions are ideal gas at 1 atmosphere and 0°C.MMSCMH Million standard cubic meters/hr. Standard conditions are ideal gas at 1 atmosphere and 0°C.MN MilliNewtonsMSCFD Thousand standard cubic ft/day. Standard conditions are ideal gas at 14.696 psi and 60°F.PCU Pound centigrade unitPSIG Pound per square inch, gaugeSCFM Standard cubic ft/minute. Standard conditions are ideal gas at 14.696 psi and 60°F.SCM Standard cubic meters. Standard conditions are ideal gas at 1 atm and 0°C.SCMH Standard cubic meters/hr. Standard conditions are ideal gas at 1 atm and 0°C.TONNE Metric ton (1000 kg)

10-2 •••• Units Aspen Plus 11.1 Summary File Toolkit

Table A.1 - Units Options

UNITS TYPE SI SET ENG SET MET SET OTHER UNITS OPTIONSANGLE RAD DEG DEGAREA SQM SQFT SQM SQCM SQIN SQMILEBOND-WORK-INDEX J/KG KWHR/TON KWHR/TON KJ/KGCONTENTS FRACTION PERCENT FRACTION PPMDELTA-T K F K C RDIFFUSIVITY SQM/SEC SQFT/HR SQCM/SEC CSDIPOLEMOMENT (J*CUM)**.5 (BTU*CUFT)**.5 DEBYE (KJ*CUM)**.5ELEC-POWER WATT KW KWENTHALPY-FLOW WATT BTU/HR CAL/SEC J/SEC

MMKCAL/HRMMPCU/HRKJ/SEC

GJ/HRMMKCAL/DAYMMBTU/HRKW

KCAL/HRPCU/HRMMBTU/DAY

FILTER-RESISTANCE 1/M 1/FT 1/M 1/CM 1/INFORCE NEWTON LBF DYNEFREQUENCY HZ RPM RPM RAD/SECHEAD J/KG FT-LBF/LB M-KGF/KG SQM/SQSEC

METERINCHKJ/KG

FT

HEAT J BTU CAL KCALPCUGJ

MMKCALMMPCU

MMBTUKJ

HEAT-TRANS-COEF WATT/SQM-K BTU/HR-SQFT-R CAL/SEC-SQCM-K KCAL/SEC-SQM-KKW/SQM-KMMBTU/HR-SQFT-R

KCAL/HR-SQM-KJ/SEC-SQM-K

PCU/HR-SQFT-KKJ/SEC-SQM-K

INVERSE-AREA 1/SQM 1/SQFT 1/SQMINVERSE-HT-C SQM-K/WATT HR-SQFT-R/BTU SEC-SQCM-K/CAL SEC-SQM-K/KCAL

SQM-K/KWHR-SQFT-K/PCUSEC-SQM-K/J

HR-SQM-K/KCALSEC-SQM-K/KJ

INVERSE-LENGTH 1/M 1/FT 1/CM 1/IN 1/MMLENGTH METER FT METER CM

MMINMILE

MUKM

MASS KG LB KG GMTONNE

TON MLB

MASS-CONC KG/CUM LB/CUFT GM/L GM/CC MG/L MG/CCMASS-DENSITY KG/CUM LB/CUFT GM/CC LB/GALMASS-ENTHALPY J/KG BTU/LB CAL/GM KCAL/KG

MMBTU/LBKJ/KGPCU/LB

MMKCAL/KGMMPCU/LB

MASS-ENTROPY J/KG-K BTU/LB-R CAL/GM-K KCAL/KG-K KJ/KG-KMASS-FLOW KG/SEC LB/HR KG/HR LB/SEC

TONS/DAYKG/DAY

LB/DAYTONS/HRTONNE/HR

MLB/HRTONS/YEARGM/SEC

MASS-HEAT-CAPACITY J/KG-K BTU/LB-R CAL/GM-K KCAL/GM-K PCU/LB-K KJ/KG-KMASS-TRANS-COEF KG/S-SQM-KG/CUM LB/HR-SQF-LB/CUF GM/S-SQCM-GM/CC

MOLE-CONC KMOL/CUM LBMOL/CUFT MOL/CC MOL/L MMOL/CC MMOL/LMOLE-DENSITY KMOL/CUM LBMOL/CUFT MOL/CC LBMOL/GAL MOL/LMOLE-ENTHALPY J/KMOL BTU/LBMOL CAL/MOL KCAL/MOL

PCU/LBMOLGJ/KMOL

MMKCAL/MOLMMPCU/LBMOL

MMBTU/LBMOLKJ/KMOL

MOLE-ENTROPY J/KMOL-K BTU/LBMOL-R CAL/MOL-K KCAL/MOL-K KJ/KMOL-K TCAL/MOL-KMOLE-FLOW KMOL/SEC LBMOL/HR KMOL/HR MOL/SEC

KMOL/DAYMMSCFHMSCFD

LBMOL/SECSCMHMMSCFD

LBMOL/DAYMMSCMHSCFM

Aspen Plus 11.1 Summary File Toolkit Units •••• 10-3

UNITS TYPE SI SET ENG SET MET SET OTHER UNITS OPTIONSMOLE-HEAT-CAPACITY J/KMOL-K BTU/LBMOL-R CAL/MOL-K KCAL/MOL-K

KJ/KMOL-KTCAL/MOL-K PCU/LBMOL-K

MOLE-VOLUME CUM/KMOL CUFT/LBMOL CC/MOLMOLES KMOL LBMOL KMOL SCM

MMSCFMMSCM MSCF

PACK-FACTOR 1/M 1/FT 1/MPOP-DENSITY NO/M/CUM NO/FT/CUFT NO/M/L NO/MM/L NO/MU/CC NO/IN/CUINPOWER WATT HP KW FT-LBF/SEC BTU/HR CAL/SECPRESSURE † N/SQM PSI ATM LBF/SQFT

IN-WATERKPAPSIGKG/SQCMG

BARKG/SQCMMM-WATERATMG

TORRMMHGMBARBARG

PDROP N/SQM PSI ATM LBF/SQFTIN-WATERKPA

BARKG/SQCMMM-WATER

TORRMMHGMBAR

PDROP-PER-HT N/CUM IN-WATER/FT MM-WATER/M MBAR/M MMHG/FTSOLUPARAM (J/CUM)**.5 (BTU/CUFT)**.5 (CAL/CC)**.5 (KCAL/CUM)**.5 (KJ/CUM)**.5SPEC-FLT-RESISTANCE M/KG FT/LB M/KG CM/GMSURFACE-TENSION N/M DYNE/CM DYNE/CM LBF/FT MN/MTEMPERATURE K F K C RTHERMAL-CONDUCTIVITY WATT/M-K BTU-FT/

HR-SQFT-RKCAL-M/ HR-SQM-K

BTU-IN/ HR-SQFT-RKW/M-K

C-CM/ SEC-SQCM-K

CAL-CM/ SEC-SQCM-K

TIME SEC HR HR DAY MIN YEARVELOCITY M/SEC FT/SEC M/SEC MILE/HR KM/HRVFLOW-LENGTH SQM/SEC GPM/F SQCM/SEC SQM/HR SQF/MINVISCOSITY N-SEC/SQM CP CP LB/FT-HR MN-SEC/SQMVOLUME CUM CUFT L CUIN

CCGAL BBL

VOL-HEAT-CAPACITY J/CUM-K BTU/CUFT-R CAL/CC-K KCAL/CUM-K KJ/CUM-KVOLUME-FLOW CUM/SEC CUFT/HR L/MIN GAL/MIN

BBL/DAYCUM/YEARCUFT/SEC L/DAYMMCUFT/DAY

GAL/HRCUM/HRCUM/MINL/HRKBBL/DAYMCUFT/DAY

BBL/HRCUM/DAYCUFT/MINL/SECMMCUFT/HR

WORK J HP-HR KW-HR FT-LBF KJ† Absolute and gauge pressure

10-4 •••• Units Aspen Plus 11.1 Summary File Toolkit

Aspen Plus 11.1 Summary File Toolkit Property Names •••• 11-1

Property Names

This chapter lists the property names that are returned in thePNAME or QUALS arguments of the toolkit routines. It also liststhe property names that you can specify where PNAME andQUALS are input arguments.

Table B.1 - Standard Property Names

Property Name Description

ABVSRG Percentage above surge for a compressorACT_AREA Active area/panel for traysACT_DPINLET Actual pressure drop reached in inlet pipeACT_DPTAIL Actual pressure drop reached in tail pipeACT_REFLUX Actual reflux ratioACT_STAGES Actual number of stagesALLW_DPINLET Maximum pressure drop allowed in inlet pipeALLW_DPTAIL Maximum pressure drop allowed in tail pipeALLW_PRES Maximum pressure allowed in vesselALLW_TEMP Maximum temperature allowed in vesselANGLE Angle of pipe segmentAREA_CALC Calculated areaAREA_RATIO Ratio of outside finned area to inside tube areaAVGDP_HT Average pressure drop/heightBACKUP_LOC Downcomer location (side/center)BAFFLE_CUT Baffle cut as a fraction of shell diameterBAFFLE_TYPE Baffle type (segmental or rod)BELSWL Percentage below stonewall for a compressor

11-2 •••• Property Names Aspen Plus 11.1 Summary File Toolkit

Property Name Description

BOTTHICK Bottom shell thicknessBOTTOM_TEMP Bottoms temperatureBOT_L1FLOW Bottom stage liquid1 flowBOT_L2FLOW Bottom stage liquid2 flowBOT_LFLOW Bottom stage liquid flowBOT_VFLOW Bottom stage vapor flowBR Boilup ratioBRAKE_POWER Brake powerBU_RATIO Boilup ratioBWG Birmingham wire gauge for the tubesBYPASS Bypass fractionB_K Block vapor-liquid K-valueB_MASSFLOW Mass flowB_MASSFRAC Mass fractionB_MOLEFLOW Mole flowB_MOLEFRAC Mole fractionB_PRES Block pressureB_TEMP Block temperatureB_VFRAC Block vapor fractionCALC Variable calculated valueCAPAC_FAC Capacity factorCAV_INDX Valve cavitation indexCEFF Calculated efficiencyCHOK_STAT Valve choked flow statusCHOKE_POUT Valve outlet pressure for choked flowCODE_COMPLY Code complianceCOLDIN Cold side inlet stream IDCOLDINP Cold side inlet pressureCOLDINT Cold side inlet temperatureCOLDINVF Cold side inlet vapor fractionCOLDOUT Cold side outlet stream IDCOLD_FRAC Cold side vapor fractionCOLD_KODE Cold side flash calculation codeCOLD_LRATIO Cold side liquid1/total liquid ratioCOLD_PRES Cold side pressureCOLD_TEMP Cold side temperatureCOMP-ATTR Component attribute valueCOMP-STAGES Compressor stage

Aspen Plus 11.1 Summary File Toolkit Property Names •••• 11-3

Property Name Description

COMPFRAC Component fractionCOMPRESS CompressibilityCOMPTYPE Compressor typeCOND_DUTY Condenser dutyCOND_Q_NSC Condenser duty without subcoolingCOND_RES_TIM Residence time of condensed phases (RCSTR)COND_VOL Volume occupied by the condensed phases

(RCSTR)COOL-PRES Coolant pressureCOOL-TEMP Coolant temperatureCOOLANT_TEMP Coolant temperatureCOR_PDRP_FAC Pressure drop ratio factor with pipe fittingsCOR_PREC_FAC Pressure recovery factor with pipe fittingsCOSTID Unit label for user2 sizing resultCPCV_FAC Ratio of specific heats factorCRIT_PRS_FAC Liquid critical pressure ratio factorCSCOST Carbon steel cost for the equipmentCSD-PHASE Conventional solid destination phaseCUM_DPACC Cumulative accelerational pressure dropCUM_DPELEV Cumulative elevational pressure dropCUM_DPFRIC Cumulative frictional pressure dropCUM_DPTOTL Cumulative total pressure dropCYCLE_TIME Cycle timeC_LIQ_FLOW Component liquid mole flow in streamC_VAP_FLOW Component vapor mole flow in streamDCAREA Downcomer area/column area ratioDCBACKUP Downcomer backupDCBSPACE Backing/tray spacingDCRATIO Velocity/design velocity ratioDCVELOC Downcomer velocityDELT Temperature changeDENSITY Liquid densityDEVICE_TYPE Safety relief device typeDIAM DiameterDIAM50 50% diameter sizeDIAM-RATIO Diameter ratioDIAM_CYL Cylinder diameterDIAM_OUT Diameter of outlet

11-4 •••• Property Names Aspen Plus 11.1 Summary File Toolkit

Property Name Description

DIAM_SOL Solid diameterDIS DisplacementDISTIL_TEMP Distillate temperatureDIST_VS_FEED Distillate-to-feed ratioDPACC Accelerational pressure drop for the segmentDPELEV Elevational pressure drop for the segmentDPFRIC Frictional pressure drop for the segmentDPTOTL Total pressure drop for the segmentDP_SECTION Section pressure dropDUTY Calculated dutyEFF EfficiencyEFFICIENCY Fin efficiencyELEC_POWER Electrical powerENTH_BAL Enthalpy balance differenceENTH_CYCLE Enthalpy per cycleENTH_TIME Enthalpy flow during operationEPC Polytropic efficiencyEQUIV-LEN Pipe equivalent lengthERO_VEL Erosion velocity at the nodeERR ErrorERR_TOL Error/toleranceEV Volumetric efficiencyEXHTS Extra height of the vesselEXP_FAC Expansion factorEXTENT Reaction extentF Feed mole fractionFACTOR Geometric or packing factorFEED-QUALITY Feed qualityFEED_FLOW Feed flowFEED_LFLOW Liquid feed flowFEED_LOCATN Feed stage locationFEED_TRAY_T Feed tray temperatureFEED_VFLOW Vapor feed flowFHEIGHT Fin heightFILT_DIAM Filter diameterFILT_RESIST Filter resistanceFINDEX Fractionation indexFIN_PRES Final pressure

Aspen Plus 11.1 Summary File Toolkit Property Names •••• 11-5

Property Name Description

FIN_TEMP Final temperatureFIRE-FACTOR Credit factor calculated for the Fire scenarioFLOOD Percentage floodingFLOOD_FAC Flooding factorFLOOD_PANEL Panel indicating the flooding regimeFLOW_COEF Valve flow coefficientFLOW-COF Compressor flow coefficientFLOWP Flow parameterFLUID_POWER Fluid powerFTHICKNESS Fin thicknessFWDECANT Free-water decant rateFWREFLUX Free-water reflux ratioGAS-VEL Vapor superficial velocity at the nodeGAS_FLOW Gas flow rateHCRATIO Heat capacity ratioHEAD HeadHEAD-COF Compressor head coefficientHEAT_FLUX Heat fluxHEAT_RATE Total heat transfer rateHEAT_REAC Heat of reactionHEIGHT HeightHETP Stage height equivalent of a theoretical plateHOLDUP Total liquid holdupHOTIN Hot side inlet stream IDHOTINP Hot side inlet pressureHOTINT Hot side inlet temperatureHOTINVF Hot side inlet vapor fractionHOTOUT Hot side outlet stream IDHOT_KODE Hot side flash calculation codeHOT_LRATIO Hot side liquid1/total liquid ratioHOT_PRES Hot side pressureHOT_TEMP Hot side temperatureHOT_VFRAC Hot side vapor fractionHT_FROM_TOP Height from top of sectionHX_AREAC Calculated (required) areaHX_AREAP Actual (physical) areaHX_DELT Delta-T between hot and cold streamsHX_DTLM Log-mean temperature difference

11-6 •••• Property Names Aspen Plus 11.1 Summary File Toolkit

Property Name Description

HX_DUTY Calculated heat dutyHX_FMTD Log-mean temperature difference correction

factorHX_NTUC Number of transfer unitsHX_OVERD Percent over designHX_PTNO Point number within a zoneHX_SBDP Shell stream baffled flow area pressure dropHX_SFLM Shellside film coefficientHX_SMCR Shell stream crossflow Reynolds numberHX_SMCV Shell stream crossflow velocityHX_SMWR Shell stream window Reynolds numberHX_SMWV Shell stream window velocityHX_SNDP Shell stream nozzle pressure dropHX_SPR Shell stream Prandtl numberHX_STDP Shell stream total pressure dropHX_STMP Shell stream temperatureHX_TBDP Tube stream tube pressure dropHX_TFLM Tubeside film coefficientHX_TMR Tube stream Reynolds numberHX_TMV Tube stream velocityHX_TNDP Tube stream nozzle pressure dropHX_TPR Tube stream Prandtl numberHX_TTDP Tube stream total pressure dropHX_TTMP Tube stream temperatureHX_UAVC Average heat transfer coefficient for clean

serviceHX_UAVD Average heat transfer coefficient for dirty serviceHX_WTMP Wall temperatureHX_XIC Thermal effectivenessHX_ZNNO Exchanger zone numberHYD_FFR Reduced F factorHYD_FMIDX Marangoni foaming indexHYD_LMF Hydraulic liquid mass flowHYD_LVF Hydraulic liquid volume flowHYD_MUL Hydraulic liquid viscosityHYD_MUV Hydraulic vapor viscosityHYD_MWV Vapor molecular weightHYD_PARM Hydraulic flow parameter

Aspen Plus 11.1 Summary File Toolkit Property Names •••• 11-7

Property Name Description

HYD_QR Hydraulic reduced vapor throughputHYD_RHOL Hydraulic liquid densityHYD_RHOV Hydraulic vapor densityHYD_STEN Hydraulic surface tensionHYD_VMF Hydraulic vapor mass flowHYD_VVF Hydraulic vapor volume flowH_GAS Vapor phase enthalpyH_LIQ Liquid phase enthalpyH_MIX Mixture enthalpyIN-MACH Compressor inlet Mach numberIND_POWER Indicated horsepowerINIT_PRES Initial pressure in vesselINIT_TEMP Initial temperature in vesselINLET_D80 Inlet 80% diameter sizeINSIDE_DIAM Tube inside diameterIN_BFL_SP Inlet baffle spacing for segmental bafflesIN_EROVEL Erosional velocity at inletIN_LVFRAC Liquid volume fraction at inletIN_NODE Inlet node nameIN_PRES Inlet pressureIN_REGIME Flow regime at inletIN_REYNO Reynolds Number at inletIN_TEMP Inlet temperatureIN_VELOC Velocity at inletIN_VF Inlet vapor fractionIN_VVFRAC Vapor volume fraction at inletINT_TEMP Interface temperatureINT_X Interface liquid mole fractionsINT_Y Interface vapor mole fractionsITYPE Type of pumpK Equilibrium constantK1 Vapor-liquid1 K-valueK2 Vapor-liquid2 K-valueKLL Liquid1-liquid2 K-valueKODE Flash calculation codeL1_ENTH Liquid1 enthalpyL1_FLOW Liquid1 flowL1_MW Liquid1 molecular weight

11-8 •••• Property Names Aspen Plus 11.1 Summary File Toolkit

Property Name Description

L2_ENTH Liquid2 enthalpyL2_FLOW Liquid2 flowL2_MW Liquid2 molecular weightLENGTH LengthLEN_CONE Cone lengthLEN_CYL Length of cylinderLEN_OUT Length of outletLEN_VORTEX Length of vortexLIQ_ENTH Liquid enthalpyLIQ_FLOW Liquid flowLIQ_FRAC Liquid volume fraction at the nodeLIQ_MF_TOT Sum of liquid mole fractions in streamLIQ_RATIO Liquid1/total liquid ratioLIQ_VEL Liquid superficial velocity at the nodeLIQ_VOL Volume occupied by liquid phase (RCSTR)LIQ1_VOL Volume occupied by liquid1 phase (RCSTR)L_CONDUC Liquid conduction transfer rateLL_RATIO Liquid/liquid ratioLMTD Log-mean temperature differenceMASSFLWS Solid mass flow rateMASSFRC_CAKE Mass fraction of cakeMASS_ABS Absolute mass balanceMASS_CYCLE Mass per cycleMASS_RATE Mass transfer rateMASS_REL Relative mass balanceMASS_TIME Mass flow during operationMATERIAL Tube material of constructionMATFAC Material of construction factor for equipmentMATFAC1 Material of construction factor for the traysMAXBACKUP Stage with maximum downcomer backupMAXFLOOD Stage with maximum floodingMAXSTAGE Stage with maximum diameterMAXVELOC Stage with max velocityMAX_MASSFLOW Maximum mass-based vent flow rate reachedMAX_MOLEFLOW Maximum mole-based vent flow rate reachedMAX_PRES Maximum pressure reached in vesselMAX_TEMP Maximum temperature reached in vesselMAX_VENTFLOW Maximum mass-based vent flow rate reached

Aspen Plus 11.1 Summary File Toolkit Property Names •••• 11-9

Property Name Description

MAX_VOLFLOW Maximum volume-based vent flow rate reachedMF_LIQ Component liquid mole fraction in streamMF_VAP Component vapor mole fraction in streamMID_BFL_SP Center baffle spacing for segmental bafflesMIN_REFLUX Minimum reflux ratioMIN_STAGES Minimum number of equilibrium stagesMODE Filter modeMOISTURE Moisture contentMOLE_ABS Absolute mole balanceMOLE_CYCLE Moles per cycleMOLE_REL Relative mole balanceMOLE_TIME Moleflow during operationMW Molecular weightMW_LIQ Liquid phase molecular weightNBAGS Number of bagsNCELLS Number of cellsNCLEAN Number of cells being cleanedNODENAME Node nameNOMINAL-SIZE Standard tube outside diameterNPER_LENGTH Number of fins per unit lengthNPHASE Number of phasesNPSH-AVAIL Net positive suction head availableNSBAFFLE Number of baffles in the shellNSEAL_STRIP Number of sealing strip pairsNTRAIN Number of trainsNTURNS Number of turnsNUMBER Number of cyclonesOIL_FLOW Oil flow rateOIL_VISC Oil viscosityOPER_TIME Operating timeORIENTATION Exchanger physical orientationOUTLET_D80 Outlet 80% diameter sizeOUTSIDE_DIAM Tube outside diameterOUTSTREAM Outlet stream IDOUT_BFL_SP Outlet baffle spacing for segmental bafflesOUT_EROVEL Erosional velocity at outletOUT_LVFRAC Liquid volume fraction at outletOUT_NODE Outlet node name

11-10 •••• Property Names Aspen Plus 11.1 Summary File Toolkit

Property Name Description

OUT_PRES Outlet pressureOUT_REGIME Flow regime at outletOUT_REYNO Reynolds Number at outletOUT_TEMP Outlet temperatureOUT_VELOC Velocity at outletOUT_VVFRAC Vapor volume fraction at outletPART_DIAM Particle diameterPATTERN Tube bank layout patternPCOST Purchase cost for the equipmentPDROP Stage pressure dropPDROP_FAC Pressure drop ratio factorPDRP Pressure dropPHASE PhasePHASE-FRAC Phase fractionPIPE_FIT_FAC Pipe fittings geometry factorPITCH Center to center distance between adjacent tubesPLACED-STRM Stream for phase placementPOC Outlet pressurePOROSITY PorosityPOS Isentropic outlet pressurePOWER Calculated powerPPOINT Pinch pointPPSTAT Property table statusPRES-RATIO Pressure ratioPROD_L1FLOW Liquid1 product flowPROD_L2FLOW Liquid2 product flowPROD_LFLOW Product flowPROD_VFLOW Vapor product flowPRREC_FAC Pressure recovery factorPVOLS Volume per tankPWGHT Weight of each section of the Tray-TowerP_OUT Valve outlet pressureQCALC Calculated dutyQNET Calculated net heat dutyQZONE Duty for zoneQ-FIRE Heat input calculated for the Fire scenarioRADIUS RadiusREAC_LRATE Rates of generation in liquid phase

Aspen Plus 11.1 Summary File Toolkit Property Names •••• 11-11

Property Name Description

REAC_VRATE Rates of generation in vapor phaseREB_DUTY Reboiler dutyRECT_STAGES Number of rectification stagesREGIME Flow regime at the nodeREL_VOL Relative volatilityRES_TIME Residence timeREYNO Reynolds NumberRHOS Solid densityRHO_GAS Vapor phase densityRHO_LIQ Liquid phase densityRING_INDIAM Baffle ring inside diameterRING_OUTDIAM Baffle ring outside diameterROD_BFL_SP Baffle spacing for rod bafflesROD_DIAM Support rod diameterROD_LENGTH Total length of support rods per rod baffleROOT_DIAM Root mean diameter of finned tubeRR Reflux ratioRUN_TYPE Run typeRXN_GEN Reaction generationS-SONICV Suction sonic velocity of a compressorSADD Stream added to outletSALT_VOL Volume occupied by the salts (RCSTR)SAUTER_DIAM Sauter diameterSCDUTY Subcooled dutySCENARIO ScenarioSCTEMP Subcooled temperatureSECTION Section IDSELECT SelectivitySETPOINT Set pointSH-SPEED Compressor shaft speedSHELL_BFL_SP Clearance between the shell and the bafflesSHELL_BND_SP Clearance between shell and tube bundleSHELL_DIAM Shell inside diameterSHELL_MIXED Is the shell stream unmixed/mixed?SIDE Heat exchanger sideSIDE_AREA Side downcomer area/panelSIDE_DRAW Side draw flow rateSNOZ_INDIAM Shell inlet nozzle diameter

11-12 •••• Property Names Aspen Plus 11.1 Summary File Toolkit

Property Name Description

SNOZ_OUTDIAM Shell outlet nozzle diameterSOL_FLOW Solid flowSONVEL Sonic velocitySP-DIAM Specific diameter of a compressor wheelSP-SPEED Specific shaft speed of a compressorSPACE Floor space requiredSPAREA Packing surface areaSPCHNG Phase changeSPC_MASSFLOW Specified mass-based vent flow rateSPC_MOLEFLOW Specified mole-based vent flow rateSPC_VOLFLOW Specified volume-based vent flow rateSPEC Variable specified valueSPEED SpeedSTAGE_NO Stage numberSTART_STG Number of first stage in sectionSTATUS Choke status of pressure relief systemSTDVFLOW Standard volume flowSTDVFRAC Standard volume fractionSTDVOL_CYCLE Standard volume per cycleSTDVOL_TIME Standard volume flow during operationSTEAM-FLOW Steam flow rateSTEN Surface tensionSTICH1 1st Stichlmair constantSTICH2 2nd Stichlmair constantSTICH3 3rd Stichlmair constantSTOP-CRIT Stop criterionSTOP-TIME Stop timeSTOP_STG Number of last stage in sectionSTREAMFRAC Stream fractionSTRENGTH StrengthSUBS-ATTR Substream attribute valueSURFTEN Surface tensionS_LINEAR Linear s-plot valueS_LOG Logarithmic s-plot valueTAMBIENT Ambient temperature at the nodeTB Boiling point temperatureTEMA_TYPE Standard TEMA shell typeTHGHT Total height of the equipment

Aspen Plus 11.1 Summary File Toolkit Property Names •••• 11-13

Property Name Description

THICKNESS ThicknessTH_BETA Thermosyphon liquid1/total liquid ratioTH_DUTY Thermosyphon dutyTH_MOLEFLOW Thermosyphon mole fractionTH_PRES Thermosyphon pressureTH_TEMP Thermosyphon temperatureTH_VFRAC Thermosyphon vapor factionTH_X Thermosyphon liquid mole fractionTH_X1 Thermosyphon liquid1 mole fractionTH_X2 Thermosyphon liquid2 mole fractionTH_Y Thermosyphon vapor mole fractionTIME TimeTIP-MACH Rotor tip Mach number for a compressor wheelTMAX Maximum temperatureTMIN Minimum temperatureTNOZ_INDIAM Tube inlet nozzle diameterTNOZ_OUTDIAM Tube outlet nozzle diameterTOC Outlet temperatureTOLERANCE ToleranceTOPTHICK Top shell thicknessTOP_L1FLOW Top stage liquid1 flowTOP_L2FLOW Top stage liquid2 flowTOP_LFLOW Top stage liquid flowTOP_TEMP Top stage temperatureTOP_VFLOW Top stage vapor flowTOS Isentropic outlet temperatureTOTAL-MASS Total massTOTAL_NUMBER Total number of tubesTOT_AREA Total tray areaTOT_ENTH_ABS Absolute total enthalpy balanceTOT_ENTH_REL Relative total enthalpy balanceTOT_MASS_ABS Absolute total mass balanceTOT_MASS_REL Relative total mass balanceTOT_MOLE_ABS Absolute total mole balanceTOT_MOLE_REL Relative total mole balanceTRAY_NUMBER Actual number of traysTRYSPS Tray spacing in the tray-towerTTLEN Tangent to tangent length of the vessel

11-14 •••• Property Names Aspen Plus 11.1 Summary File Toolkit

Property Name Description

TUBES_IN_WIN Are there tubes in the baffle windows?TUBE_BFL_SP Clearance between the tubes and the bafflesTUBE_FLOW Direction of tubeside flow for vertical exchangersTUBE_LENGTH Effective tube lengthTUBE_MIXED Is the tube stream unmixed/mixed?TUBE_NPASS Number of tube passesTUBE_TYPE Bare or finned tubes?TWGHT Total weight of the equipmentTYPE Type of cycloneUA Area time heat transfer coefficientUAZONE Area time heat transfer coefficient for zoneVALVE_DP Delta-P across valveVALVE_POSN Operating valve position (as percentage of max

opening)VAP_ENTH Vapor enthalpyVAP_FLOW Vapor flowVAP_MF_TOT Sum of vapor mole fractions in streamVAP_RES_TIM Residence time of vapor phase (RCSTR)VAP_VOL Volume occupied by vapor phase (RCSTR)VELOCITY VelocityVELOC_LOC Stage with maximum downcomer velocityVENT_FLOW Mass-based vent flowVFLOW Volume flowVL_RATIO Vapor/liquid ratioVMIX Mixture velocity at the nodeVOIDFR Packing void fractionVOLFLOW Volumetric flowVOLTAGE VoltageVSTD Standard liquid volumeV_CONDUC Vapor conduction transfer rateV_CONVEC Vapor convection transfer rateWALL-THICK Tube wall thicknessWATER-FRAC Water volume fraction in streamWATER_FLOW Water flow rateWEIRLEN Side weir lengthWETTED_AREA Wetted vessel areaWIDTH WidthWNET Calculated net work

Aspen Plus 11.1 Summary File Toolkit Property Names •••• 11-15

Property Name Description

X Liquid mole fractionX1 Liquid1 mole fractionX2 Liquid2 mole fractionY Vapor mole fraction

Table B.2 - Mixture ThermodynamicProperties

Property Name Description

RHOLSTD Standard liquid densityRHOMX DensityVLSTDMX Standard liquid volumeVMX VolumeVVSTDMX Standard vapor volume

Property Name Description

BETA Molar fraction of liquid that is L1LFRAC Liquid fractionMASSFLMX Mass flow rateMASSVFRAC Mass vapor fractionMASSSFRAC Mass solid fractionMOLEFLMX Mole flow rateSFRAC Solid fractionVFRAC Mole vapor fractionVOLFLMX Volume flow rate

Property Name Description

AVAILMX Availability, H-ToS To=298.15 KCPCVMX Heat capacity ratio (CPMX/CVMX)CPIGMX Ideal gas heat capacityCPMX Constant pressure heat capacityCSATMX Specific heat at saturationCVMX Constant volume heat capacityDGMIX Gibbs free energy of mixing

Volume

Flow Rates, Fractions

Enthalpy, Entropy,Gibbs Energy, HeatCapacity

11-16 •••• Property Names Aspen Plus 11.1 Summary File Toolkit

Property Name Description

DGMX Free energy departureDHMX Enthalpy departureDSMX Entropy departureGIGMX Ideal gas free energyGMX Free energyGXS Excess free energyHIGMX Ideal gas enthalpyHMX EnthalpyHXS Excess enthalpySIGMX Ideal gas entropySMX Entropy

Property Name Description

ABSHUMID Absolute humidityCOMB-02 Amount of oxygen need to combust a mixtureMWMX Molecular weightPBUB Bubble point pressurePCMX Critical pressurePDEW Dew point pressurePRES PressurePRMX Reduced pressureRELHUMID Percentage relative humiditySONVELMX Sonic velocityTBUB Bubble point temperatureTCMX Critical temperatureTDEW Dew point temperatureTEMP TemperatureTRMX Reduced temperatureVCMX Critical volumeZCMX Critical compressibility factorZMX Compressibility factor

Other properties

Aspen Plus 11.1 Summary File Toolkit Property Names •••• 11-17

Table B.3 - ThermodynamicProperties of Components inMixturesProperty Name Description

GAMMA Activity coefficientGAMPC Activity coefficient pressure correctionGAMUS Unsymmetrically normalized activity coefficientKLL2 Liquid-liquid K-valueKVL Vapor-liquid K-valueKVL2 Vapor-liquid2 K-valueMASSCONC Mass concentrationMASSFLOW Mass flow rateMASSFRAC Mass fractionMOLECONC Molar concentrationMOLEFLOW Mole flow rateMOLEFRAC Mole fractionPHIMX Fugacity coefficientPPMX Partial pressureSSOLFACT Solubility safety factorSSOLUB Equilibrium solubility of a freeze-out componentTFREEZ Freeze-out temperature of a componentTFRZMARG Temperature safety marginVLSTD Standard liquid volumeVLSTDFR Standard liquid volume fractionVVSTD Standard vapor volumeVVSTDFR Standard vapor volume fraction

Table B.4 - Pure ComponentThermodynamic Property SetsProperty Name Description

AVAIL Availability, H-ToS To=298.15 KCP Constant pressure heat capacityCPCV Heat capacity ratio (CP/CV)CPIG Ideal gas heat capacityCV Constant volume heat capacityDG Free energy departure

11-18 •••• Property Names Aspen Plus 11.1 Summary File Toolkit

Property Name Description

DGPC Free energy departure pressure correctionDH Enthalpy departureDHVL Enthalpy of vaporizationDHPC Enthalpy departure pressure correctionDS Entropy departureG Free energyGIG Ideal gas free energyH EnthalpyHIG Ideal gas enthalpyPHI Fugacity coefficientPHIPC Fugacity coefficient pressure correctionPL Vapor pressureRHO DensityS EntropySIG Ideal gas entropySONVEL Sonic velocityV Volume

Table B.5 - Electrolyte Property SetsProperty Name Description

FAPP Apparent component molar flow rateFTRUE True species molar flow ratesGXTRUE Activity coefficient of a true species (mole fraction

scale)GMTRUE Activity coefficient of a true species (molality scale)IONSM Ionic strength (molality scale)IONSX Ionic strength (mole fraction scale)MAPP Apparent component molalityMTRUE True species molalityOSMOT Osmotic coefficientPH25 pH at 25°CPH pHPOH25 pOH at 25°CPOH pOHSOLINDEX Solubility index (ratio of activity in mixture to

activity at saturation)

Aspen Plus 11.1 Summary File Toolkit Property Names •••• 11-19

Property Name Description

WAPP Apparent component mass flow rateWTRUE True species mass flow rateWXAPP Apparent component mass fractionWXTRUE True species mass fractionXAPP Apparent component mole fractionXTRUE True species mole fraction

Table B.6 - Transport PropertiesProperty Name Description

KINVISC Kinematic viscosityKMX Thermal conductivityMUMX ViscosityPR Prandtl NumberSIGMAMX Surface tensionTHRMDIFF Thermal diffusivity

Property Name Description

DMX Diffusion coefficient

Property Name Description

K Thermal conductivityMU ViscositySIGMA Surface tension

Mixture

Component in aMixture

Pure Components

11-20 •••• Property Names Aspen Plus 11.1 Summary File Toolkit

Table B.7 - Petroleum-RelatedProperties for MixturesProperty Name Description

ANILPT Aniline pointAPI API gravityCETANENO Cetane numberCHRATIO Carbon to hydrogen ratioFLPT-API Flash point (API method)MABP Mean average boiling pointPHYDRATE Hydrate formation pressurePRPT-API Pour point (API method)QVALGRS Gross heating valueQVALNET Net heating valueREFINDEX Refractive indexRVP-ASTM Reid vapor pressure (ASTM method)RVP-API Reid vapor pressure (API method)SG Specific gravitySGAIR Specific gravity (ref.AIR at 60°F)THYDRATE Hydrate formation temperatureVABP Volume average boiling pointVISINDEX Liquid viscosity indexWAT Watson UOP K-factor

Property Name Description

APICRV API gravity curve (liquid volume basis)APICRVWT API gravity curve (weight basis)D86CRK ASTM D86 distillation curve with cracking

correction (liquid volume basis)D86CRV ASTM D86 curve (liquid volume basis)D86CRVWT ASTM D86 curve (weight basis)D86WTCRK ASTM D86 distillation curve with cracking

correction (weight basis)D1160CRV ASTM D1160 curve (liquid volume basis)D1160CVW ASTM D1160 curve (weight basis)D2887CRV ASTM D2887 distillation curve (weight basis)GRVCRV Gravity curve (liquid volume basis)GRVCRVWT Gravity curve (weight basis)

Distillation Curves

Aspen Plus 11.1 Summary File Toolkit Property Names •••• 11-21

Property Name Description

MWCRV Molecular weight curve (liquid volume basis)MWCRVWT Molecular weight curve (weight basis)TBPCRV True boiling point curve (liquid volume basis)TBPCRVWT True boiling point curve (weight basis)VACCRV Vacuum curve (liquid volume basis)VACCRVWT Vacuum curve (weight basis)

Property Name Description

D2887T ASTM D2887 temperature, at a given liquid volumepercent

D86TCK ASTM D86 temperature with cracking correction, ata given liquid volume percent

D86TWTCK ASTM D86 temperature with cracking correction, ata given weight percent

D86T ASTM D86 temperature, at a given liquid volumepercent

D86TWT ASTM D86 temperature, at a given weight percentD1160T ASTM D1160 temperature, at a given liquid volume

percentD1160TWT ASTM D1160 temperature, at a given weight

percentTBPT True boiling point temperature, at a given liquid

volume percentTBPTWT True boiling point temperature, at a given weight

percentVACT Vacuum temperature, at a given liquid volume

percentVACTWT Vacuum temperature, at a given weight percent

DistillationTemperature

11-22 •••• Property Names Aspen Plus 11.1 Summary File Toolkit

Property Name Description

D2887WT ASTM D2887 weight percentD86LVCK ASTM D86 liquid volume percent with cracking

correctionD86WTCK ASTM D86 weight percent with cracking correctionD86LV ASTM D86 liquid volume percentD86WT ASTM D86 weight percentD1160LV ASTM D1160 liquid volume percentD1160WT ASTM D1160 weight percentTBPLV True boiling point liquid volume percentTBPWT True boiling point weight percentVACLV Vacuum liquid volume percentVACWT Vacuum weight percent

Property Name Description

ANILPT Aniline pointAROMATIC Aromatic contentBASIC-N2 Basic nitrogen contentCARBON Carbon contentFLASHPT Flash pointFREEZEPT Freeze pointHYDROGEN Hydrogen contentIRON Iron contentKNOCKIDX Anti knock indexKVISC Kinematic viscosityLUMI-NO Luminometer numberMERCAPTAN Mercaptan contentMETAL Metal contentMOC-NO Motor octane numberNAPHTHENE Naphthene contentNICKEL Nickel contentOLEFIN Olefin contentOXYGEN Oxygen contentPARAFFIN Paraffin contentPOURPT Pour pointREFINDEX Refractive indexROC-NO Research octane numberRVP Reid vapor pressureSMOKEPT Smoke point

Distillation Volumeand Weight Percent

Bulk PetroleumProperty Values fromAssay Curves

Aspen Plus 11.1 Summary File Toolkit Property Names •••• 11-23

Property Name Description

SULFUR Sulfur contentTOTAL-N2 Total nitrogen contentVANADIUM VanadiumVISC ViscosityVLOCKIDX Vapor lock indexWARMIDX Warm-up index

Property Name Description

<100F Flow rates for petroleum cuts boiling below 100°F100-200F Flow rates for petroleum cuts boiling between 100

and 200°F200-300F Flow rates for petroleum cuts boiling between 200

and 300°F300-400F Flow rates for petroleum cuts boiling between 300

and 400°F400-500F Flow rates for petroleum cuts boiling between 400

and 500°F500-600F Flow rates for petroleum cuts boiling between 500

and 600°F600-700F Flow rates for petroleum cuts boiling between 600

and 700°F700-800F Flow rates for petroleum cuts boiling between 700

and 800°F800-900F Flow rates for petroleum cuts boiling between 800

and 900°F900-999F Flow rates for petroleum cuts boiling between 900

and 1000°F>1000F Flow rates for petroleum cuts boiling above 1000°F50-100C Flow rates for petroleum cuts boiling between 50

and 100°C100-150C Flow rates for petroleum cuts boiling between 100

and 150°C150-200C Flow rates for petroleum cuts boiling between 150

and 200°C200-250C Flow rates for petroleum cuts boiling between 200

and 250°C250-300C Flow rates for petroleum cuts boiling between 250

and 300°C300-350C Flow rates for petroleum cuts boiling between 300

and 350°C

Petroleum Cuts

11-24 •••• Property Names Aspen Plus 11.1 Summary File Toolkit

Property Name Description

350-400C Flow rates for petroleum cuts boiling between 350and 400°C

400-450C Flow rates for petroleum cuts boiling between 400and 450°C

450-500C Flow rates for petroleum cuts boiling between 450and 500°C

500-550C Flow rates for petroleum cuts boiling between 500and 550°C

>550C Flow rates for petroleum cuts boiling above 550°CCUTS-E Flow rates for petroleum cuts in 100°F incrementsCUTS-M Flow rates for petroleum cuts in 50°C incrementsLT-ENDS Flow rates for light ends

Property Name Description

ANILCRV Aniline point curveAROMCRV Aromatic content curveBAS-NCRV Basic Nitrogen content curveCARBCRV Carbon content curveFLASHCRV Flash point curveFREEZECRV Freeze point curveHYDROCRV Hydrogen content curveIRONCRV Iron content curveKNOCKCRV Antiknock index curveKVISCCRV Kinematic viscosity curveLUM-NCRV Luminometer number curveMERCCRV Mercaptan content curveMETALCRV Metal content curveMOCNCRV Motor octane number curveNAPHCRV Naphthene content curveNICKCRV Nickel content curveOLEFCRV Olefin content curveOXYGCRV Oxygen content curvePARACRV Paraffin content curvePOURCRV Pour point curveREFICRV Refractive index curveROCNCRV Research octane number curveRVPCRV Reid vapor pressure curveSMOKCRV Smoke point curve

Petroleum PropertyCurves

Aspen Plus 11.1 Summary File Toolkit Property Names •••• 11-25

Property Name Description

SULFCRV Sulfur content curveTOT-NCRV Total nitrogen content curveUOPKCRV Watson UOP K curveVANACRV Vanadium content curveVISCCRV Viscosity curveVLOCKCRV Vapor knock index curveWARMICRV Warm-up index curve

Table B.8 - Elemental Analysis ofMixturesProperty Name Description

MOLEFLC Mole flow of carbon atomMOLEFLH Mole flow of hydrogen atomsMOLEFLN Mole flow of nitrogen atomsMOLEFLS Mole flow of sulfur atomsMOLEFLF Mole flow of fluorine atomsMOLEFLCL Mole flow of chlorine atomsMOLEFLBR Mole flow of bromine atomsMOLEFLI Mole flow of iodine atomsMOLEFLAR Mole flow of argon atomsMOLEFLHE Mole flow of helium atomsMASSFLC Mass flow of carbon atomsMASSFLH Mass flow of hydrogen atomsMASSFLO Mass flow of oxygen atomsMASSFLN Mass flow of nitrogen atomsMASSFLS Mass flow of sulfur atomsMASSFLF Mass flow of fluorine atomsMASSFLCL Mass flow of chlorine atomsMASSFLBR Mass flow of bromine atomsMASSFLI Mass flow of iodine atomsMASSFLHE Mass flow of helium atomsMOLEFRC Mole fraction of carbon atomsMOLEFRH Mole fraction of hydrogen atomsMOLEFRO Mole fraction of oxygen atomsMOLEFRN Mole fraction of nitrogen atoms

11-26 •••• Property Names Aspen Plus 11.1 Summary File Toolkit

Property Name Description

MOLEFRS Mole fraction of sulfur atomsMOLEFRF Mole fraction of fluorine atomsMOLEFRCL Mole fraction of chlorine atomsMOLEFRBR Mole fraction of bromine atomsMOLEFRI Mole fraction of iodine atomsMOLEFRAR Mole fraction of argon atomsMOLEFRHE Mole fraction of helium atomsMASSFRC Mass fraction of carbon atomsMASSFRH Mass fraction of hydrogen atomsMASSFRO Mass fraction of oxygen atomsMASSFRN Mass fraction of nitrogen atomsMASSFRS Mass fraction of sulfur atomsMASSFRF Mass fraction of fluorine atomsMASSFRCL Mass fraction of chlorine atomsMASSFRBR Mass fraction of bromine atomsMASSFRI Mass fraction of iodine atomsMASSFRAR Mass fraction of argon atomsMASSFRHE Mass fraction of helium atoms

Table B.9 - NonconventionalComponent PropertiesProperty Name Description

DENSITY DensityENTHALPY EnthalpyHEAT-CAPACITY Heat capacity

Table B.10 - Property Names forCosting ResultsProperty Name Description

NUMBER Total number of heat exchangersCSCOST Carbon steel cost per exchangerPCOST Purchased cost per exchangerVARID Material of constructionBBCOST Total carbon steel cost

Equipment Type:HEATX

Aspen Plus 11.1 Summary File Toolkit Property Names •••• 11-27

TCOST Total purchased costMATFAC Material of construction factorPAREAS Heat transfer area per unitAREA_CALC Total heat transfer areaSCDUTY Total scaled heat dutyLMTD Log mean temperature differenceFACTOR Exchanger geometry correction factor

Property Name Description

NUMBER Total number of air coolersCSCOST Carbon steel cost per coolerPCOST Purchased cost per coolerVARID Material of constructionBBCOST Total carbon steel costTCOST Total purchased costMATFAC Material of construction factorPAREAS Bare tube area per coolerAREA_CALC Total bare tube areaSCDUTY Total scaled heat dutyLMTD Log mean temperature difference

Property Name Description

NUMBER Total number of fired-heatersCSCOST Carbon steel cost per heaterPCOST Purchased cost per heaterVARID Material of constructionBBCOST Total carbon steel costTCOST Total purchased costMATFAC Material of construction factorSCDUTY Scaled duty per fired-heaterDUTY Scaled total heat dutyQCALC Energy required per fired-heaterB_PRES Defaulted pressure

Equipment Type:AIRCOOL

Equipment Type:FIRED-HEATER

11-28 •••• Property Names Aspen Plus 11.1 Summary File Toolkit

Property Name Description

NUMBER Total number of pumpsITYPE Pump typeCSCOST Carbon steel cost per pumpPCOST Purchased cost per pumpVARID Material of constructionBBCOST Total carbon steel costTCOST Total purchased costMATFAC Material of construction factorPROD_VFLOW Total scaled volumetric flowL1_FLOW Volumetric flow per pumpB_PRES Pressure riseHEAD Pump headDENSITY Liquid densityEFF Pump efficiencyCEFF Motor efficiencyELEC_POWER Power required per pump

Property Name Description

NUMBER Total number of compressorsITYPE Compressor typeCSCOST Carbon steel cost per compressorPCOST Purchased cost per compressorVARID Material of constructionBBCOST Total carbon steel costTCOST Total purchased costPOWER Indicated horsepowerMATFAC Material of construction factorLIQ_FLOW Volumetric flow per compressorVAP_FLOW Total scaled volumetric flowB_PRES Pressure riseHCRATIO Heat capacity ratioEFF Compressor efficiencyELEC_POWER Power required per compressor

Equipment Type:PUMP

Equipment Type:COMPR

Aspen Plus 11.1 Summary File Toolkit Property Names •••• 11-29

Property Name Description

NUMBER Total number of blowersTYPE Blower classSPEED Motor speedCSCOST Carbon steel cost per blowerPCOST Purchased cost per blowerVARID Material of constructionBBCOST Total carbon steel costTCOST Total purchased costMATFAC Material of construction factorPAREAS Outlet area per blowerAREA_CALC Total outlet areaLIQ_FLOW Scaled total volumetric flowVAP_FLOW Scaled flow per blowerVELOCITY Outlet gas velocityB_PRES Corrected static pressureEFF Motor efficiencyCEFF Blower efficiencyELEC_POWER Power required per blower

Property Name Description

NUMBER Total Number of Tray-TowersCSCOST Carbon steel cost per towerPCOST Purchased cost per towerVARID Material of constructionBBCOST Total carbon steel costTCOST Total purchased costMATFAC Tower material factorMATFAC1 Tray material factorTWGHT Total shell weightTHGHT Tower tangent-to-tangent lengthTHICKNESS Average shell thickness

Equipment Type:BLOWER

Equipment Type:TRAY-TOWER

11-30 •••• Property Names Aspen Plus 11.1 Summary File Toolkit

Property Name Description

PWGHT WeightLIQ_FLOW Liquid flowVAP_FLOW Vapor flowFLOWP Flow parameterDIAM DiameterTRYSPS Tray spacingEFF Tray efficiencyTRAY_NUMBER Number of traysEXHTS Extra heightTTLEN Tangent-to-tangent length

Property Name Description

NUMBER Total number of equipmentCSCOST Carbon steel cost per piecePCOST Purchased cost per pieceVARID Material of constructionBBCOST Total carbon steel costTCOST Total purchased costVAR_VAL Scaled capacity

Property Name Description

NUMBER Total number of v-vesselsCSCOST Carbon steel cost per v-vesselPCOST Purchased cost per v-vesselVARID Material of constructionBBCOST Total carbon steel costTCOST Total purchased costMATFAC Material of construction factorVAP_FLOW Scaled vapor flowLIQ_FLOW Scaled liquid flowVOLUME Volume per vesselDIAMETER DiameterTTLEN Tangent-to-tangent lengthTOPTHICK Top shell thicknessBOTTHICK Bottom shell thicknessTWGHT Total shell weight

Equipment Type:TRAY-TOWERSection Results

Equipment Type:USER

Equipment Type:V-VESSEL

Aspen Plus 11.1 Summary File Toolkit Property Names •••• 11-31

Property Name Description

NUMBER Total number of h-vesselsCSCOST Carbon steel cost per h-vesselPCOST Purchased cost per h-vesselVARID Material of constructionBBCOST Total carbon steel costTCOST Total purchased costMATFAC Material of construction factorVAP_FLOW Scaled vapor flowLIQ_FLOW Scaled liquid flowVOLUME Volume per vesselDIAMETER DiameterTTLEN Tangent-to-tangent lengthTOPTHICK Top shell thicknessBOTTHICK Bottom shell thicknessTWGHT Total shell weight

Property Name Description

NUMBER Total number of tanksTYPE Tank typeCSCOST Carbon steel cost per tankPCOST Purchased cost per tankVARID Material of constructionBBCOST Total carbon steel costTCOST Total purchased costMATFAC Material of construction factorLIQ_FLOW Scaled liquid flowVOLUME Total volume requiredPVOLS Volume per tank

Equipment Type:H-VESSEL

Equipment Type:TANK

11-32 •••• Property Names Aspen Plus 11.1 Summary File Toolkit

Aspen Plus 11.1 Summary File Toolkit Index of Subroutines •••• 1

Index of Subroutines

TKACCT, 3-7TKALIS, 3-11TKBIDS, 4-2TKBRES, 4-8TKCIDS, 3-11TKCLFL, 3-5TKCLOS, 3-4TKCNCT, 4-3TKCNTN, 4-3TKCNVT, 3-9TKCOMP, 3-10TKCPRP, 3-12TKEIDS, 7-2TKEQCR, 7-3TKEQSR, 7-4TKFLWB, 3-7TKFRCM, 4-34TKHCID, 4-79TKHCPR, 4-78TKHCUR, 4-76TKHXBA, 4-19TKHXD1, 4-15TKHXD2, 4-16TKHXNO, 4-19TKHXPF, 4-21TKHXPP, 4-21TKHXPR, 4-22TKHXSH, 4-17TKHXTU, 4-18TKHXZO, 4-17TKICST, 4-28TKINFO, 3-6TKINI2, 3-3TKINIT, 3-2TKLABL, 3-10TKLHCR, 4-75TKLRRP, 4-60

TKLSEC, 4-42TKMCCP, 4-13TKMCPR, 4-13TKNBLK, 4-2TKNCOL, 4-23TKNENV, 6-4TKNEQ, 7-2TKNEQP, 7-3TKNEQS, 7-4TKNEXT, 3-12TKNHCP, 4-77TKNHCR, 4-74TKNHXD, 4-15TKNHXT, 4-16TKNICS, 4-28TKNMCP, 4-12TKNPER, 4-10TKNPET, 4-30TKNPEV, 6-6TKNPIP, 4-71TKNPPR, 6-2TKNPPT, 6-1TKNPRS, 8-2TKNRES, 4-7TKNRRP, 4-61TKNSEC, 4-42TKNSEN, 3-13TKNSPR, 5-9TKNSTR, 5-2TKNTPR, 4-39TKNWHL, 4-11TKNXPR, 8-2TKOPEN, 3-4TKPAPF, 8-9TKPAPR, 8-9TKPAR1, 8-10TKPAR2, 8-10

TKPERF, 4-10TKPIDS, 8-2TKPINP, 4-70TKPIPR, 4-70TKPISP, 4-69TKPLCO, 4-65TKPLCP, 4-65TKPLIO, 4-64TKPLND, 4-67TKPLNP, 4-67TKPLPP, 4-68TKPLPR, 4-68TKPLSG, 4-66TKPLSP, 4-66TKPLSZ, 4-63TKPORT, 4-4TKPPEV, 6-7TKPPRP, 6-3TKPRO1, 4-24TKPRO2, 4-25TKPROF, 4-23TKPROP, 4-24TKPSEC, 4-44TKPSR1, 8-7TKPSR2, 8-8TKPSRF, 8-4TKPSRP, 8-5TKPSS1, 8-8TKPSSP, 8-5TKPSSR, 8-6TKPSSS, 8-6TKPSUB, 8-4TKPTAD, 4-32TKPTCN, 4-35TKPTEV, 6-5TKPTFR, 4-33TKPTPP, 4-34

TKPTPR, 4-32TKPTRS, 4-31TKPVPF, 8-11TKPVR1, 8-12TKPVR2, 8-13TKPVRP, 8-11TKRCAT, 4-50TKRFSP, 4-51TKRNAC, 4-49TKRNCA, 4-49TKRNFS, 4-51TKRPIP, 4-72TKRPR1, 4-48TKRPR2, 4-48TKRPRF, 4-47TKRPRP, 4-47TKRRHR, 4-58TKRRNS, 4-58TKRRPF, 4-57TKRRPR, 4-57TKRRRP, 4-62TKRRSL, 4-59TKRSCA, 4-50TKRSUB, 4-46TKRTNL, 4-38TKRTNR, 4-36TKRTRS, 4-37TKRTSP, 4-37TKRTSR, 4-38TKSCAT, 5-7TKSCPR, 4-45TKSCRS, 4-43TKSENS, 3-14TKSENV, 6-4TKSHCR, 4-76TKSIDS, 5-2TKSINF, 5-3

2 •••• Index of Subroutines Aspen Plus 11.1 Summary File Toolkit

TKSNAC, 5-6TKSNCA, 5-6TKSNSA, 5-8TKSPIR, 4-71TKSPPT, 6-2TKSPRP, 5-10TKSRRP, 4-60TKSSAT, 5-9TKSSCA, 5-7TKSSEC, 4-43TKSSID, 5-3TKSSSA, 5-8TKSTRA, 5-5TKSTRM, 5-4TKSVAL, 5-4TKTITL, 3-6TKTPRP, 4-40TKTREP, 4-39TKTRNR, 4-26TKTRRS, 4-26TKUNIT, 3-8TKVAPF, 4-52TKVAPR, 4-53TKVAR1, 4-53TKVAR2, 4-54TKVLE, 4-73TKVTPF, 4-55TKVTPR, 4-55TKVTR1, 4-56TKVTR2, 4-56TKWHLR, 4-11