Professional Documents
Culture Documents
SP 0030
SP 0030
SP 0030
SP_0030
November 2011
Copyright Notice
Since the equipment explained in this document has a variety of uses, the user and those
responsible for applying this equipment must satisfy themselves as to the acceptability of each
application and use of the equipment. Under no circumstances will Emerson Process
Management be responsible or liable for any damage, including indirect or consequential losses
resulting from the use, misuse, or application of this equipment.
The text, illustrations, charts, and examples included in this manual are intended solely to explain
TM
the use and application of the Ovation Unit. Due to the many variables associated with specific
uses or applications, Emerson Process Management cannot assume responsibility or liability for
actual use based upon the data provided in this manual.
No patent liability is assumed by Emerson Process Management with respect to the use of
circuits, information, equipment, or software described in this manual.
No part of this publication may be reproduced, stored in a retrieval system, or transmitted in any
form or by any means, including electronic, mechanical, photocopying, recording or otherwise
without the prior express written permission of Emerson Process Management.
The document is the property of and contains Proprietary Information owned by Emerson Process
Management and/or its subcontractors and suppliers. It is transmitted in confidence and trust, and
the user agrees to treat this document in strict accordance with the terms and conditions of the
agreement under which it was provided.
This manual is printed in the USA and is subject to change without notice.
Ovation is the mark of Emerson Process Management. Other marks are the property of their
respective holders.
Copyright © Emerson Process Management Power & Water Solutions, Inc. All rights reserved.
Emerson Process Management
Power & Water Solutions
200 Beta Drive
Pittsburgh, PA 15238
USA
E-Mail: Technical.Communications@Emerson.com
Website: https://www.ovationusers.com
Contents
1 Introduction to GPA 1
1.1 What is the GPA? ................................................................................................................ 1
1.2 What does the GPA do? ..................................................................................................... 2
1.3 What does the GPA consist of? .......................................................................................... 3
1.4 How does the GPA work? ................................................................................................... 4
1.5 GPA module description ..................................................................................................... 4
1.5.1 Combustion turbine performance module .............................................................. 5
1.5.2 Heat recovery steam generator (HRSG) ................................................................ 6
1.5.3 Steam turbine performance module ....................................................................... 7
1.5.4 Condenser module ................................................................................................. 8
1.5.5 HRSG calculation method ...................................................................................... 9
1.5.6 Combustion turbine calculation method ............................................................... 10
1.6 Quality assurance features for GPA.................................................................................. 10
1.6.1 Quality propagation .............................................................................................. 10
1.6.2 Analog input filtering ............................................................................................. 10
1.6.3 Performance monitoring graphics ........................................................................ 11
1.6.4 Steam table interface ........................................................................................... 11
1.7 Optional GPA module description ..................................................................................... 11
1.7.1 Large pump modules ........................................................................................... 11
1.7.2 Cooling tower performance module ..................................................................... 12
3 Startup 19
3.1 To create a new workspace .............................................................................................. 19
3.2 To create a new project ..................................................................................................... 21
3.3 Separating projects ........................................................................................................... 23
3.3.1 Single workspace containing multiple projects .................................................... 24
3.3.2 Multiple Workspaces containing a single project ................................................. 24
3.3.3 To execute multiple workspaces .......................................................................... 24
3.3.4 GPADCS window ................................................................................................. 26
3.4 Creating a function block diagram (FBD) .......................................................................... 27
3.4.1 To create a function block diagram ...................................................................... 27
SP_0030 i
Table of Contents
5 Run/Debug mode 39
5.1 Starting Run/Debug mode................................................................................................. 40
5.1.1 To save highway values ....................................................................................... 41
5.1.2 Loading highway values ....................................................................................... 42
5.1.3 Historical data retrieval......................................................................................... 43
5.1.4 Fbdorder ............................................................................................................... 46
5.1.5 Pntvalidate............................................................................................................ 48
ii SP_0030
Table of Contents
SP_0030 iii
Table of Contents
iv SP_0030
Table of Contents
SP_0030 v
Table of Contents
vi SP_0030
Table of Contents
SP_0030 vii
Table of Contents
viii SP_0030
Table of Contents
SP_0030 ix
Table of Contents
x SP_0030
Table of Contents
SP_0030 xi
Table of Contents
Index 729
xii SP_0030
S E C T I O N 1
Introduction to GPA
IN THIS SECTION
The GPA (Global Performance Advisor) is a software package that integrates advanced digital
and analog control functionality, data management, and networking into a complete process
automation solution providing a variety of performance operations and calculations.
As a system engineer and operator, you will want to identify areas to improve efficiency and
reduce operating costs of your plant. The GPA software package offers a complete set of
calculations to help you identify controllable losses, track equipment performance against design
specifications, and help identify areas in need of improvement.
The Global Performance Advisor gives you the capability of tracking equipment performance over
time. The GPA software package provides the software you need to evaluate performance and
achieve the desired plant efficiency.
The GPA offers multiple benefits that ultimately help your plant operate more efficiently. Through
open communication and detailed reporting, the GPA allows plants to consolidate performance
information from multiple units that use different control systems. By tracking and documenting
controllable losses, the GPA provides immediate feed back to help your plant operate more
efficiently and allow operators to capitalize on the opportunities for process improvements.
SP_0030 1
1.2 What does the GPA do?
The GPA package collects data through Data Agents and uses this data throughout its
calculations. Upon completion of the calculations, GPA broadcasts the calculated values and
qualities through the Data Agent.
Thus, plants having different and multiple control systems can unify their performance
calculations into a single, centralized location with all units utilizing one standard calculation
methodology. GPA also includes a web server that dynamically updates performance results over
a plant or corporate LAN or WAN.
Results that you can expect to receive by using the GPA are:
Reduced operating costs by tracking unit heat rate penalty costs over time and indicating
amount of dollars lost due to equipment performance deviations.
The calculation of net unit heat rate and heat rate deviation tracking.
Displays deviations and cost of deviations to help operators determine corrective action
through either operator action or by equipment repair or maintenance.
The GPA models plant equipment and overall heat balance to determine your plant's most
efficient operating modes.
GPA performs several calculations for various applications and offers a variety of options
applicable to your plant.
For example:
GPA provides a central location to consolidate plant performance information for multiple
units regardless of the control system manufacturer.
GPA identifies unit heat rate penalty costs and deviations from plant equipment design
specifications.
GPA includes a Web browser based graphic option.
GPA Includes a fully configured dynamic link library of plant-specific performance
calculations.
GPA shares calculations and values with business information systems through Highway
Tags.
GPA delivers a unified software solution and a consistent mathematical approach for
calculation performance across multiple units.
The GPA tracks performance levels of all power plant components.
2 SP_0030
1.3 What does the GPA consist of?
1. GPADCS Software - The GPADCS software is the main software package comprised of a
standard group or base set of calculations.
2. PCalcs Software - PCalcs software is a software overlay adding several additional
algorithms. These algorithms contain custom calculations which perform a variety of functions
providing a thorough evaluation of your plant. PCalcs are used to calculate plant performance.
Together, both software packages provide several algorithms and calculations. The following are
attributes of the GPA:
A Windows PC provides the hardware platform for software development and module
execution.
DCS Interface where the hardware and software (Data Agent) links between PC and existing
DCS.
Custom displays provide an operator interface to the Global Performance Advisor results.
GPA provides a complete set of boiler and turbine performance calculations customized to
match the specific plant equipment set.
GPA provides a full set of steam and air property tables.
Includes a data validation module which is used on signals that have a tendency to drift.
Customized modules are also included in the GPA package and can be applied to your system to
meet plant-specific monitoring requirements. Depending on the type of plant that you are
monitoring and the amount of information available, the GPA provides specific modules targeting
and evaluating the following equipment and process performance:
SP_0030 3
1.4 How does the GPA work?
The Global Performance Advisor receives required plant data through analog and digital signals
from your control system. All calculations are configured to execute every two minutes and all
analog inputs are smoothed over a two-minute interval; however, the actual time interval is user
configurable.
All pertinent values are assigned tag names, which are displayed on the workstation and can be
configured for alarm functions. All data is included in the performance reports and stored in the
historian.
The Global Performance Advisor consists of evaluation modules targeting specific areas for plant
improvement. Each module is configured to plant-specific performance objectives. The GPA
utilizes GPADCS software to provide performance calculations in a functional block structure that
is easily configured using standard drag and drop functions.
The Global Performance Advisor includes customized modules that meet specific performance
monitoring requirements for your plant. Depending on the type of plant and available information,
specific modules target and evaluate plant equipment and process performance factors including:
Steam Turbine
Condenser
Turbine Cycle Heat Rate
Boiler Performance – Thermal Loss Method
Heat Recovery Steam Generator
Combustion Turbine
Unit Performance
Optional Cooling Tower modules are also available with GPA. Refer to the following module types
listed in the following sections.
4 SP_0030
1.5 GPA module description
Calculated in accordance with ASME PTC 22, “Performance Test Code on Gas Turbines,” 1997,
the combustion turbine calculation adjusts for either natural gas or fuel oil input. These fuel
parameters can be adjusted through the data entry screens so the system can correlate between
volumetric to a mass basis.
If the combustion turbine is also fired by a liquid fuel, a breakdown of that fuel is manually entered
and is combined with a breakdown of the converted natural gas. This results in an analysis of the
fuel mix based on the relative weights of each fuel.
Thermal efficiency of the combustion turbine is computed as the reciprocal of heat rate. The
generated power output and the heat and thermal efficiency rates are adjusted to guaranteed (or
ISO) conditions using correction curves provided by the combustion turbine manufacturer. These
adjusted rates are then compared to the expected heat and thermal efficiency rates (based on
manufacturer’s performance data). All information is displayed to the operator.
Typical Inputs
Ambient air temperature, relative humidity, and barometric pressure.
Compressor inlet air temperature and relative humidity.
Combustion turbine exhaust gas temperature.
Injection water or steam flow, temperature and pressure.
Combustion turbine output.
Combustion turbine auxiliary power.
Fuel flow(s).
Temperature and pressure of the fuel(s).
Combustion turbine inlet and exhaust pressures.
Compressor discharge temperature and pressure.
Compressor inlet pressure and temperature.
Key Outputs
Combustion turbine heat rate.
Combustion turbine thermal efficiency.
Corrected combustion turbine heat rate.
Corrected turbine thermal efficiency.
Corrected power output.
Design heat rate.
Design thermal efficiency.
Corrected heat rate deviation from design.
Corrected efficiency deviation from design.
SP_0030 5
1.5 GPA module description
In accordance with ASME PTC 4.4, “Gas Turbine Heat Recovery Steam Generators,” 1981. The
HRSG module calculates the efficiency of the plant’s heat recovery steam generator input/output
and measures thermal-loss. The system then compares these values to design efficiency values
that are based on plant performance data.
Output is defined as the heat that is absorbed by the working fluid. Input is defined as the sensible
heat in the exhaust gas that supplies the heat recovery steam generator plus the chemical heat in
the supplementary fuel (for duct burners) plus the heat credit supplied by the sensible heat in the
supplementary fuel. (Per ASME PTC 4.4)
Typical Inputs
Supplemental fuel gas flow (if duct burners are present).
Temperature and pressure of supplemental fuel (if duct burners are present).
Economizer water inlet flow, temperature and pressure for each stage.
Output steam flow, temperature and pressure for each stage.
Steam drum pressure for each stage.
Steam flow to inlet air cooling system (if present).
Superheater spray water flow.
Superheater steam temperature and pressure.
Blowdown flow for each stage.
Stack gas outlet temperature.
Key Outputs
Heat input.
Heat output.
Input-output efficiency.
Heat losses.
Thermal loss efficiency.
Design input-output efficiency.
Design thermal loss efficiency.
Input-output efficiency deviation from design.
Thermal loss efficiency deviation from design
6 SP_0030
1.5 GPA module description
Using design performance data provided by the steam turbine manufacturer, the system conducts
a heat balance around the turbine and calculates the overall turbine efficiency for single-stage
casing, non-extracting turbines. Using PTC 6, “Performance Test Code 6 on Steam Turbines,”
1996, the system calculates turbine cycle heat rate.
These calculations are corrected to reference conditions using correction curves provided by the
steam turbine manufacturer.
For two-stage casing turbines, the system calculates individual high pressure and
intermediate/low pressure stage efficiencies and then compares them to design stage efficiencies.
For extraction turbines, the system calculates the reference generator output as a function of the
characteristic curves of the turbine manufacturer’s throttle flow and extraction flow. Using these
correction curves, generator output is corrected to reference conditions. The corrected result is
compared to the actual output.
Typical Inputs
Generator gross power output.
Generator megavars.
Hydrogen pressure (if generator is hydrogen cooled).
Auxiliary power.
Steam temperatures and pressures at turbine extraction points (if not measured at feedheater
shell).
Turbine throttle steam temperature and pressure.
High pressure turbine exhaust or cold reheat steam temperature and pressure.
Intermediate (or reheat) turbine inlet steam temperature and pressure (if applicable).
Crossover steam temperature and pressure.
Turbine exhaust pressure.
Auxiliary steam flows, temperatures and pressures (if applicable).
Controlled extraction steam flow, temperature and pressure for co-generation systems.
Key Outputs
Generator losses and efficiency.
Turbine section extraction steam flows.
Turbine section enthalpies
Turbine section efficiencies
Turbine section design efficiencies
Turbine
SP_0030 7
1.5 GPA module description
This module computes the thermal transmittance and cleanliness factor in accordance with ASME
PTC 12.2, “Steam Surface Condensers,” 1983 and The Heat Exchange Institute’s “Standards for
Steam Surface Condensers,” 9th Edition.
If the circulating water flow can be measured, the system computes the condenser duty by
measuring the heat that is transferred to the circulating water. If the circulating water flow can not
be measured, the system calculates the steam heat balance around the condenser. The system
then calculates the circulating water flow based on the condenser duty and the rise in the
circulating water temperature.
The system calculates actual transmittance and clean thermal transmittance and compares them
in order to calculate the condenser cleanliness factor. The expected backpressure (based on
clean tubes) is compared to the actual backpressure.
Typical Inputs
Cooling water inlet temperature.
Cooling water outlet temperature.
Condenser back pressure.
Makeup water flow.
Makeup water temperature.
Hotwell temperature.
Flow and temperature of condensate return to condenser (if applicable).
Number of plugged tubes.
Key Outputs
Terminal temperature difference.
Log mean temperature difference.
Condenser subcooling.
Circulating water flow.
Condenser duty.
Heat transfer coefficient and cleanliness factor.
Expected condenser back pressure, based on clean tubes and deviation from actual back
pressure.
Fuel cost(s) per million btus.
8 SP_0030
1.5 GPA module description
Calculations are performed in accordance with ASME PTC 4.4 (input-output and thermal-loss
efficiencies). These calculated efficiencies are compared to design efficiency values calculated
from performance data. Using ASME PTC 4.4
Output is the heat absorbed by the working fluid.
Input is the sensible heat in the exhaust gas supplied to the heat recovery steam generator,
plus the chemical heat in the supplementary fuel, plus the heat credit supplied by the sensible
heat in the supplementary fuel.
HRSG Key Outputs
Heat input.
Heat output.
Heat losses.
Input-output efficiency.
Thermal loss efficiency.
Design input-output efficiency.
Design thermal loss efficiency.
Input-output efficiency deviation from design.
Thermal loss efficiency deviation from design.
SP_0030 9
1.6 Quality assurance features for GPA
Calculations are performed in accordance with ASME PTC 22. Corrected output, heat rate, and
thermal efficiency are calculated based on correction curves provided by the turbine
manufacturer. Design combustion turbine heat rate and efficiency are calculated based on turbine
design data and compared to the corrected values.
Gross and net plant heat rate and plant thermal efficiency are calculated. Plant heat rate penalty
costs and output deviations are calculated for combustion turbine parameters, steam turbine
parameters, and the condenser.
Note: steam turbine and combustion turbine correction curves are required.
Typical Inputs
Output from the other Global Performance Advisor modules.
The GPA system has multiple features to ensure the integrity of the calculated results. These
features are listed in the following sections:
This feature permits plant personnel to evaluate the quality of signals used in the Global
Performance Advisor. Quality Propagation indicates the actual quality of the system’s original
input signals and includes this quality in the resulting calculated values. The system broadcasts
the quality of the input/output data, as well as the calculated results on the network.
The Analog Input Filtering feature ensures the reliability of the combined-cycle calculations. If key
instrumentation fails, or if the value of an input parameter is outside a pre-defined range, plant
personnel can substitute values and/or Ovation point names through a password-protected
interface. If a substitute point name or value is used for performance calculations, the quality of
the point is marked “fair.” The “fair” quality is indicated through subsequent calculations.
10 SP_0030
1.7 Optional GPA module description
Performance monitoring graphics are customized to reflect the specific facility. Graphic displays
indicate the results of each performance calculation at any workstation.
This attribute provides an interactive steam table interface based on the 1997 ASME Steam
Properties for Industrial Calculations.
In addition to the Standard GPA modules, the following program modules are optionally available:
Large Pump Modules calculate pump efficiency and compare corrected pump head to design
head to determine if the pump is meeting its capacity/head curve within a given tolerance.
Typical Inputs
Suction pressure and temperature.
Discharge pressure and temperature.
Pump water flow.
Pump speed.
Pump in service flag.
Pump current.
Pump (or house) voltage.
Key Outputs
Pump efficiency.
Pump head.
Corrected pump head.
Ratio of corrected head to design head.
SP_0030 11
1.7 Optional GPA module description
Cooling Tower Performance Modules compute expected outlet temperature from the cooling
tower and tower capability.
Typical Inputs
Hot water inlet temperature.
Cold water outlet temperature.
Individual fan in-service status.
Individual fan input volts and current.
Circulating water inlet flow.
Cooling Tower wet bulb temperature.
Ambient temperature.
Barometric pressure.
Key Outputs
Estimated cold water outlet temperature.
Cooling tower capability.
12 SP_0030
S E C T I O N 2
IN THIS SECTION
GPA software runs on a Windows based PC. To ensure the GPA program runs smoothly, your
computer should have at least:
900 MHz
256 MB of RAM
SP_0030 13
2.1 Installation requirements
During installation of GPADCS, a Data Agent configuration dialog box appears. The choices on
this dialog box define which data agents are loaded when executing GPADCS in ONLine mode.
Therefore, these choices are not needed unless the ONLine mode is used.
The associated client software for these data agents must be loaded when GPADCS ONLine
mode is started, or errors will occur upon startup.
Note: In GPADCS OFFLine mode, these data agents are not loaded.
The GPADCS configuration dialog can be invoked at a later time with the
Start > Programs > GPADCS > Configure selections.
14 SP_0030
2.2 To install GPA software
During development of a project, the following files need to be backed-up on a periodic basis to
prevent data loss:
Project_name.xref (under %FACTORYSOFTHOME%)
Workspace_name.feqp
Workspace_name.fwsp
Project_name.cprj
All .ffbd documents
All .fdsp files (display sheets)
The .feqp and .fwsp files are found under the directory where the Workspace was created. The
.cprj and .ffbd files are found under the directory where the project was created.
SP_0030 15
2.3 Porting a project to another machine
Note: When EDS is installed on a system where the Historical Offline Interface is going to be
executed, EDS must be at version 7_3_4c or later.
ONLINE mode - The ONLINE GPA package is used after the OFFLINE GPA package has
been debugged.
Note: Two shortcuts are created after installing the GPA package.
Porting a GPA project requires copying only the GPADCS specific files, not the supporting DLLs
(such as pcalcs.dll, stmtable.dll, useralgssharedres.dll, stminterface.dll and calccommon.dll).
Note: Each project within a Workspace has its own directory; therefore Workspaces with
multiple projects have multiple directories.
Also, each project within a Workspace has its own .xref file, therefore Workspaces with
multiple projects will have multiple .xref files.
The .const and .fx files are saved from within algorithms.
Recommended file storage: store files in sub-directories within a project directory or, at least
on the same disk partition.
The .xref files are in %FACTORYSOFTHOME%. These files contain all of the Tag Group
definitions which define the tag configurations for ALL algorithms in the project.
To simplify the zip file to be built:
1. Add the .fwsp and .feqp files.
2. Cursively zip ALL FILES in the project(s) directories.
3. Add all the project .xref files from %FACTORYSOFTHOME%.
16 SP_0030
2.4 Program introduction
The following definitions may help you understand the layering that GPADCS uses in building
Projects.
Workspace - Pulls together one or more results provided by a project or set of projects to form a
more complicated or complex result for use in a process.
Project - A set (or sets) of algorithms combined together to input information, process the
information, and output useful information.
Algorithm - An Individual building block or module used to perform calculations, and output
information to perform a dedicated function.
Setting Preferences and/or Properties for various aspects of the programs and projects.
Setting different levels of security.
SP_0030 17
S E C T I O N 3
Startup
IN THIS SECTION
To begin using the GPA, you must first create a new Workspace. This should be a one-time
process that sets up all the projects for the complete facility.
SP_0030 19
3.1 To create a new workspace
4. Select Navigate and find the Location where the project will be kept (or make a new
location), then select OK. This places the Workspace with all its components and files in the
selected folder.
Notice that other directories were developed when the Workspace was created:
Equipment List - Shows a list of the projects and their running order.
Event Log - A chronological list of events, which can be used for troubleshooting.
Gallery - Not used.
20 SP_0030
3.2 To create a new project
Note: It is important not to name any project the same name as the Workspace, as the GPA
program may confuse the two.
1. Right-click the Workspace name in the Workspace Window and select New Project.
("Workspace Emerson PWS" in this example is the workspace name). The New dialog box
appears with "Control Project" selected automatically.
2. Enter the desired project name in the Name text box (usually the unit or facility name). Leave
the selection of Add to Current Workspace as is. The Location option will, by default, be the
same as the Workspace and can be changed if desired.
SP_0030 21
3.2 To create a new project
3. Select OK, which will place the new project and its components in the folder.
Note: For ease of viewing, set the Zoom factor under the View menu to 75%. For multiple
projects, other New Projects and New Documents can be created. Don't forget to save
periodically!
It is recommended that all the information for each physical facility (building or unit) be placed in
the same Project. If the plant has more than one unit, each one operating independently, a project
file should be set up for each. Use Steps 1 through 3 in the above procedure to develop each
Project.
When working with more than one Project, a separate dummy New Project must be created. This
project does not need any New Documents but will always have to be started first.
Make sure to give the dummy New Project a name that will allow it to be started first, (such as
Aaadummy).
The dummy project is needed to start all the data agent's data points. If one project is stopped,
the other project's points will still be collected and broadcast since the “dummy” project which
started all the data agents points will still be running.
Follow the above procedure, steps 1 through 3, to develop each project, again making sure the
“Dummy” project has a name ensuring it will start first.
22 SP_0030
3.3 Separating projects
The name becomes bold, identifying it as the Active Project. See the example in the following
figure.
There are also other projects that can be added other than Control Projects. The addition of other
projects is discussed later.
Notice that other files were developed when each Project was made:
Tags - A listing of all the Tags used in the Project. Tags are useful in troubleshooting.
Separating GPA projects is driven by several factors. For example, having the ability to start/stop
projects independently or having multiple highways requiring separate data agents servers.
There are two ways to configure multiple GPA projects to run on the same machine:
1. Build a SINGLE workspace (.fwsp file) which contains MULTIPLE projects (.cprj file)
(Section Single Project Containing a Multiple Workspace).
2. Build MULTIPLE workspaces, each containing a SINGLE project (Section Multiple
Workspaces Containing a Single Project.
SP_0030 23
3.3 Separating projects
The Single Workspace containing a multiple projects configuration is recommended only for
cases where the total number of highway tags for ALL projects number in the low 100's.
GPA performance issues come into affect when the total number of highway tags exceed the
300-350 tag range for workspaces containing multiple projects.
(The above information was obtained from tests performed on a PC with 333 MHz, 128 MB RAM.
Since these results may vary for PC's with different configurations, you may want to make your
own tests).
# of Highway Tags = # Analog Input + # Digital Input + # Digital Out + (2 X # Analog Out)
(Each analog output tag has an associated quality tag that contains a data agent's item)
Multiple Workspaces containing a single project is the most commonly used configuration. With
single workspace/project combinations, there are currently no known limits (as of PCalcs 3.1) for
the total number of highway tags that will affect performance.
The one requirement when automatically starting multiple Workspaces upon reboot is that the
subsequent Workspaces must wait or (Sleep) until the previous Workspaces have started and are
gathering samples. This is true even if each project has a different data agent's Server on
different machines.
This requirement is VERY important when different projects are accessing the SAME data agents
server. This interval between startups of Workspaces must be determined by observation or
experimentation.
A batch (.com or .bat) file can be built to control this operation. The GPASleep.exe is included in
the 3.1 PCalcs release to help facilitate the startup control.
24 SP_0030
3.3 Separating projects
Below is a sample batch file which starts up two workspaces on the same machine:
REM
REM Batch File for Starting GPA for Units 1 & 2, with a 60 second Delay
in-between
REM
REM
************************************************************************
**
REM Launch Unit #1
REM
************************************************************************
**
start c:\gpadcs\bin\gpadcs -r d:\pcalcs\UNIT1.fwsp
REM
REM
************************************************************************
**
REM Sleep 60 seconds, wait for Unit #1 to start gathering samples
REM
************************************************************************
**
GPASleep 60
REM
REM
************************************************************************
**
REM Launch Unit # 2
REM
************************************************************************
**
start d:\gpadcs\bin\gpadcs -r d:\pcalcs\UNIT2.fwsp
Note: Notice that GPASleep has one parameter, which is the number of SECONDS to sleep.
Not milliseconds!
SP_0030 25
3.3 Separating projects
Workspaces are the basis of the GPADCS development framework. The following window is an
illustration of the GPADCS workspace. Each Workspace contains one or more projects and all the
components required for each project. You can only open one Workspace at a time.
Note: Before beginning the GPA, it is recommended that you read the GPADCS tutorial.
The GPADCS tutorial is a document explaining how to build a project. It would be helpful to
work through the GPADCS document to help you understand how to build a project.
The GPA software overlay works somewhat differently than explained in the tutorial, however,
most of the concepts are the same.
When invoking the program, the icon seems to disappear. If this happens, take the cursor to the
bottom of the screen where the GPA program bar can be seen, right-click the bar and select
maximize to display the program.
26 SP_0030
3.4 Creating a function block diagram (FBD)
One or more FBD documents will need to be created at this point. FBD documents contain the
control strategy for each Project. Each Functional Block Diagram will represent a function
consisting of inputs, main projects, or output algorithms.
Any number of optional equipment functional block diagrams can also be added. Refer to
Common Functional Block Diagrams (see page 701) for examples of different types of FBDs.
SP_0030 27
3.4 Creating a function block diagram (FBD)
GPA creates a Function Block Diagram folder, adds the new control document to it, and opens it
in the document window. When the FBD document is open, the algorithm window appears and
GPA automatically shows the menu commands and tool bars needed for the FBD document.
Note: At the bottom of the algorithm window are tabs that call up sets of algorithms. Included is
a special set of algorithms called Calculation Blocks developed for the GPA and designated by
the prefix W. The algorithms in these tabs contain specific functions for use with the
SmartProcess system.
There are many Calculation Blocks, and they are organized into several types.
Scroll through the list and look at the different types. A complete list and description of these
Calculation Blocks are listed in the following sections of this manual and are referred to as
Algorithms.
28 SP_0030
S E C T I O N 4
IN THIS SECTION
Adding algorithms.............................................................................................................. 29
Inserting FBDs into projects .............................................................................................. 34
Modifying data agent update rates .................................................................................... 35
Algorithms can be added to format FBD documents once an FBD is set up, (sometimes this is
also referred to as a sheet). Typically, each set of FBD documents contain:
An Input document with:
At least one Input Algorithm (Analog and/or Digital) from the W Input tab.
An Ordering Algorithm from the W Input tab.
A Main document with at least the Chkload Algorithm from the W Main tab, along with any
calculation algorithms needed for the project.
Any amount of documents with equipment Algorithms from the available W tab groups.
An Output document with at least one Algorithm from the W Output tab.
Note: Several pieces of equipment can be placed on one FBD document. However, for
simplicity and for easy troubleshooting, it is suggested that one FBD document be made for
each piece of equipment.
SP_0030 29
4.1 Adding algorithms
Use the Emptyproject algorithm is to be used ONLY in Workspaces that contain MULTIPLE
projects.
The purpose of this algorithm is to synchronize the startup of all projects, waiting for the dummy
project (which initializes data agents Highway Item Handles) to start before allowing all other
projects to start.
Workspaces with SINGLE projects do not need this algorithm, since they self-contain their own
startup.
When a Workspace with multiple projects is created, a dummy project needs to be added which
becomes the Active Project and is configured to be the first project to start. Refer to, To Create a
New Project (see page 21).
The dummy project's only function is to initialize data agent's handles for ALL tags in ALL
projects, thus allowing you to start/stop all the other projects independently without losing their
data agent's handles. Therefore, the dummy project should always be running.
Note: Even though the dummy project starts first, the other projects want to start immediately
afterwards in a synchronized fashion. This can cause problems on the first calculation (average)
pass, since a zero value is read for all samples in the real projects until all the data agent's
handles have been initialized. This results in false average values in the first pass and
subsequently to false “bad first qualities encountered” in the project, since the samples have the
bogus zero values averaged in. The Emptyproject algorithm is designed to prevent this from
happening.
The Emptyproject algorithm has no inputs or outputs to configure, but you must still press the
Create/Update Tags in Entire... Project button to create some behind-the-scenes required
system control tags.
Note: If you forget to create these system operation tags, you will see a run-time error in the
Event Log asking you to create them.
30 SP_0030
4.1 Adding algorithms
Note: Double-clicking an algorithm function in the algorithm window allows the addition of that
type of multiple algorithm blocks to the Document.
After placing algorithms this way (see Step 1 - 3 above), click the Selector (Arrow) button in the
drawbar to return to selection mode for normal operations.
After each algorithm is opened, add the appropriate tags and set any other special properties.
Completing the algorithm configuration will help save problems during the initial Run.
4. Double-click the algorithm block to access the Algorithm Properties dialog.
Note: Bookmark this step and go to Setting Algorithm Properties (see page 49) to set all
properties for this algorithm before returning to continuing with the next step. Don't forget to
perform a Save All.
5. Choose and place any other Input algorithm (Analog or Digital) from the W Input algorithm tab
(using Steps 1-4) as needed. Continue this process until all desired Input algorithms are
placed.
Refer to Common Functional Block Diagrams (see page 701) for more information.
Note: Bookmark this step and go to Setting Algorithm Properties (see page 49) to set all
properties for this algorithm before returning to continue with the next step. Do a Save All at this
point.
Refer to Common Functional Block Diagrams (see page 701) for more information.
SP_0030 31
4.1 Adding algorithms
Note: Bookmark this step and go to the Setting Algorithm Properties (see page 49) to set all
properties for this algorithm before returning to continuing with the next step. Don't forget to
perform a Save All.
4. Choose and place any of the Calculation algorithms from the various algorithm tabs (using
Steps 1-3) as needed. Continue this process until all desired Calculation algorithms are
placed.
Refer to Main Functional Block Diagrams in Common Functional Block Diagrams (see page 701)
for more information.
Note: Bookmark this step and refer to Setting Algorithm Properties (see page 49) to set all
properties for this algorithm before returning and continuing with the next step. Don't forget to
perform a Save All.
4. Choose and place any Equipment algorithm(s) from the various W algorithm Lists (using
Steps 1-3) as needed and place them in the proper documents. Continue this process until all
desired Equipment algorithms are chosen and placed in their appropriate document.
For additional information refer to Common Functional Block Diagrams (see page 701).
Note: Bookmark this step and refer to Setting Algorithm Properties (see page 49) to set all
properties for this algorithm before returning and continuing with the next step. Don't forget to
perform a Save All.
4. Choose and place any other W Output algorithm (Analog or Digital, using Steps 1-3) as
needed. Continue this process until all desired Output algorithms are placed.
Refer to Common Functional Block Diagrams (see page 701) for more information.
32 SP_0030
4.1 Adding algorithms
If a tag set is assigned to an algorithm that has not been configured, or only inputs are configured,
the tag set is considered unassigned and free to be used anywhere else in the project. Once an
algorithm using this tag set creates an output, the tag set officially gets assigned to that algorithm.
Note: A Configured Tag Set is a tag set that is in use (assigned to an algorithm) AND creates at
least one output.
When copying an algorithm within the same project, some of the algorithm properties are retained
and some are changed. The Tag Set Name and Project Name are retained. The FBD Name
automatically gets changed to the name of the FBD where the algorithm is pasted or (dropped).
When a copied algorithm is pasted, all configured outputs are unconfigured. This is due to the
GPADCS rule that outputs can only be created in one algorithm. All input configurations remain
as they were before the copy.
When Analoginavg and Digitalin algorithms are copied, their inputs also remain unconfigured. The
GPADCS also has a rule that data agents items can only be assigned to a single, unique tag in
the project.
The cut operation is the same as the delete operation on algorithms. This means that all outputs
that were created by that algorithm are DELETED from the project. When the paste is performed,
the output tags must be re-created.
When cutting/pasting an algorithm within the same project, some of the algorithm properties are
retained and some are changed. The Tag Set Name and Project Name are retained. The FBD
Name automatically is changed to the name of the FBD where the algorithm is pasted (dropped).
Note: Unlike copying an algorithm, a cut will not change the configuration of the algorithm since
any outputs it created will be deleted.
When cutting/pasting an algorithm to a different project, only the Tag Set Name is retained. The
Project Name and FBD name automatically are changed to the names in the new project.
All configured output tags are checked to see if some other algorithm in the project creates them,
if so, then the outputs become unconfigured, otherwise the output configuration remains
unchanged. Input configurations remain as they were before the cut.
When cutting/pasting an algorithm to a different project, the configured tag set may not be defined
within that new project.
Use the Get Tag Sets option on the Tags tab folder to copy the tag set definition from the
previous projects cross-reference (.xref) file to the new projects .xref file. This provides a quick
and convenient method of re-using previously defined tag sets and saves editing time.
SP_0030 33
4.2 Inserting FBDs into projects
Algorithms on FBDs that are being inserted into a project act the same as if they were cut and
pasted into the project. The Tag Set Name is retained. The Project Name and FBD name are
automatically changed to the names in the new project.
All configured outputs tags are checked to see if some other algorithm in the project creates them.
If so, then the outputs become unconfigured, otherwise the output configuration remains
unchanged. Input configurations remain as they were before the insert.
When inserting FBDs into a project, the configured tag set for algorithms on the FBD may not be
defined within that new project. Use the Get Tag Sets option on the Tags tab folder to copy the
tag set definition from the previous projects cross-reference (.xref) file to the new projects .xref
file. This provides a quick and convenient method of re-using previously defined tag sets and
saves editing time.
Note: If you insert the FBDs from another project's directory instead of copying them, the FBDs
will update for BOTH projects when changes are made. This also corrupts the FBD/Project
Names of algorithms on the FBD for both projects.
The next step only applies for Workspaces with Multiple Projects. Single Workspace/Project
configurations can ignore this step.
3. Make sure at the Project that the FBDs are going to be inserted into is the Active Project
BEFORE inserting them. Failure to do this may lead to the project names assigned to
algorithms on the FBD being set to the name of the project which IS currently the active
project.
4.2.2 Adding tag sets to a project from external cross-reference (.xref) files.
When algorithms are inserted from one project to another, frequently, the tag sets assigned to
those algorithms are not defined in the new project's cross-reference (.xref) file.
The Get Tag Sets... feature is invoked by pressing a button on the Tags tab page on ANY
algorithm, providing a quick method for copying already defined (template) tag sets from the
cross-reference (.xref) file of an existing project into a new project. Refer to the Tags Tab in
Setting Algorithm Properties (see page 49).
This feature will review the current project for configured tag sets and will see if they exist in the
current project's cross-reference file. If they do not, they are added to the Missing Configured Tag
Sets list on the main dialog box.
A list of all .xref files found in %FACTORYSOFTHOME% is also provided. Select a .xref file from
that list and press the Load Matches button. All tag set matches found in that .xref file are loaded
into a third list. A tag set match is found when a tag set's name is found in the external .xref file
that exactly matches that of a missing tag set AND the base algorithm type is the same. Press the
OK or Add Selected Sets buttons to copy selected tag sets from the external .xref file into the
current project's .xref file.
34 SP_0030
4.3 Modifying data agent update rates
Algorithm checklist
Check the Tag Mapping list to make sure no tags are left uncreated.
Check the Tag group list to make sure no empty tag groups exist.
SP_0030 35
4.3 Modifying data agent update rates
OLE for Process Control (OPC) is a communications protocol that enables devices to share
information. GPADCS operates as an OPC client or server for connection to virtually any
electronic device on the plant floor. OPC also provides seamless connectivity and shared tags
with many SCADA (Supervisory Control and Data Acquisition) and control products.
Open communication is one of the greatest benefits of the PC in industrial automation. GPADCS
can operate as both an OPC client and server. This enables reliable I/O connectivity with the wide
variety of OPC servers that are available. As an OPC server, GPADCS can easily integrate with
other software packages including the entire major Human Machine Interface (HMI) and SCADA
products. GPADCS communicates with proven DDE interfaces and supports bi-directional
connectivity to databases through the Open DataBase Connectivity (ODBC) standard.
Basic PI snapshot functionality is supplied with the GPADCS PI data agent. This functionality
does not include buffering of client data. If buffering of client data is desired, the associated PI
buffering software will have to be installed.
A test program is supplied with the installation of GPADCS, called apisnap.exe. This test program
can be used outside of GPADCS for testing connectivity with PI servers. To invoke this program,
navigate to the GPADCS bin directory and issue the following command:
Where: PISERVER is the name of the system where the PI server is located.
:5450” represents “port 5450” and must be appended to the name of the server for apisnap to
operate properly. After invocation, you can enter tag names, and request to get or put
snapshot data of tags in the PI server.
To use this agent, the client software WESAPI NT Client for WDPF must be installed. This agent
allows for reading and writing of all point data recognized by the WESAPI NT Client for WDPF
software. This data agent makes direct SHC calls to set and obtain data and quality without
requiring the use of OPC.
This agent is automatically available for systems where GPADCS is installed on systems which
have Ovation already installed on them. Point data can be read from anywhere on the system
when using this data agent.
Data can be written only to points which originate on the system where Ovation and GPADCS are
installed. This data agent makes direct SHC calls to set and obtain data and quality without
requiring the use of OPC.
36 SP_0030
4.3 Modifying data agent update rates
The EDS Live Data Agent supports 2 formats for database points:
IESS format - where points contain a .UNIT@NET suffix to make them look like fully-qualified
Ovation point names (e.g. A100.unit1@net1)
IDCS format - which is an ordinary point name associated with a ZDNAME.
GPADCS also provides a way to generate an EDS Database Import File to assist building
databases faster using the information from the points defined in GPADCS.
This data agent also has failure recovery. When a project is started and GPADCS can not
connect to the configured EDS Server, it will try every 5 minutes to establish a connection until
either the project is stopped or a successful connection is established. If a running project loses
an established connection to an EDS Server, (the server may get rebooted) GPADCS will try
once a minute to re-establish the connection with the EDS server.
Tuning project data agents deals with the workings of the Data agent's Server Update rate and
the Tag Database Data Manager Update Rate.
In addition to tuning Function Block Diagrams (FBD), the tag database Data Manager Update
Rate must be tuned as well. The default is 100 ms and, similar to the default for the function block
diagrams, will probably be insufficient.
Note: This Dialog Box is only visible when you perform the above procedure, it is not visible any
other way.
SP_0030 37
4.3 Modifying data agent update rates
The Data Manager Update Rate works in conjunction with the Data Agent's Server Update Rate.
The data for a Data Agent is updated in the Tag Database based on the Data Agent Server
Update Rate (in milliseconds) setting. When this event occurs, the tag database performs the
update within the time set by the Data Manager Update Rate (in milliseconds).
Note: It is recommended that both rates be set at the same interval. A time period of 2, 3, or 5
seconds is a practical length of time and is also recommend.
Pay close attention to the EVENT LOG, UPDATE RATE OVERFLOWS CAN CAUSE GPADCS
TO ABORT.
For example:
If a PI data agent data server is configured to update the tag database every five seconds, but is
only given 100 ms (Data Manager Update Rate) time to make the update, it will probably
overflow.
If the Data Manager Update Rate is set equal to the Data Agent Server Update Rate, then the tag
database will get updated every five seconds, and the tag database will have 5 seconds to make
the update.
Note: Update Rates are run-time tunable parameters. The final tuned parameters can not be
determined until after the project is built and has executed for an extended period. This will allow
time to see if any update rate overflow occurs.
At run time, if either of these parameters are exceeded, (the Data Manager Update Rate or the
Data Agent's Server Update Rate), error messages will appear in the Event Log.
38 SP_0030
S E C T I O N 5
Run/Debug mode
IN THIS SECTION
SP_0030 39
5.1 Starting Run/Debug mode
The typical Debug or (Run Mode) dialog box, shown below, is available during GPA debug or run
mode. This dialog box appears when you "double-click" on an algorithm and select the Debug tag
page.
A project is initialized when the following text appears in the GPA Event Log: "System READY.
Active (Primary) Project Starting".
During the Run/Debug mode, most algorithms typically show the information similar to the
screens below (the two exceptions are the Fbdorder and Pntvalidate, which are discussed later in
this section):
40 SP_0030
5.1 Starting Run/Debug mode
Highway values can be saved in all algorithms from either Run or Debug mode. This is available
in either ONLine or OFFLine Mode. Press the Save Values button to display the Save Values.
The Print File button will print the highway values file. A Setup dialog appears allowing you to
select font size.
Note: The CVS format for saving highway values to a file is compatible for use with the Offline
Mode "Load Inputs from CVS File..." button, available on the Run Mode tab on any algorithm of
a running project.
SP_0030 41
5.1 Starting Run/Debug mode
The Analoginavg and Digitalin algorithms are able to load highway values from either Run or
Debug mode. This is only available in OFFLine Mode. Select the Load (Read) from File button to
load the values.
The Set Input Values group box allows you to select and define inputs.
The Single (Selected) Input set allows you to individually set a highway value one at a time. The
Set Value/Quality button takes the values that are entered in the Value and Quality fields and
applies them to the selected input. The Reset to Initial Value button will reset the selected
values.
The Multiple (Project-Wide) Inputs group will apply values to a set of inputs up to and including
the highway tags in the project. The Load (Read) from File button launches the Load (set)
Highway Values dialog.
42 SP_0030
5.1 Starting Run/Debug mode
The Historical Data Retrieval Function is used to retrieve data stored in the highway's historian.
This interface will retrieve data from PI (Plant Information), EDS, and eDB historians. If no
historians are configured, you are prompted to fill in a name and IP address for the historian.
Note: When EDS is installed on a system where the Historical Offline Interface is going to be
executed, EDS must be at version 7_3_4c or later.
The following window appears by selecting the Get Historical Data button from the Run mode
window, refer to Run Mode Tab - OffLine (see page 53). This window provides historical data
retrieval options for you to retrieve historical data or view errors and data by selecting one of the
Retrieval Information buttons. You must be Offline to access this window.
To retrieve data from the EDS you must have EDS software version 6.0 or later loaded.
SP_0030 43
5.1 Starting Run/Debug mode
FIELD DESCRIPTION
Project to Retrieve Input Values Displays a list of available projects from a pull-down list.
Available Historical Devices Drop name and type must be select for the historian.
Drop(s)
(If PI or EDS, the port number must also be entered.
Retrieval File Name Name of the file where the retrieved data is sent. This file is used by
the Load(Read) from File button on the Analoginavg screen.
Unit Name Unit Name is an optional field. Used if the points are not fully qualified
in GPA but are fully qualified in the historian.
Unit Node Unit Node is an optional field. Used if the points are not fully qualified
44 SP_0030
5.1 Starting Run/Debug mode
FIELD DESCRIPTION
in GPA but are fully qualified in the historian.
Time Starting and Ending time are selected in the appropriate fields.
Retrieve Data Button After all fields are completed, the Retrieve Data button is selected.
View Data Button After the data is retrieved, select the View Data button to view the
data.
View Errors Button After the data is retrieved, select the View Errors button to view the
errors.
After the data is retrieved, a message is displayed indicating the number of retrieved points and
the number of errors. The Offline Historical Retrieval screen is exited and the retrieval file can be
loaded from the Load(Read) from File button on the Analoginavg screen.
Once accurate fuel analysis is available, this function provides a replay of data, and is also useful
to determine averages of performance over different time periods. Retrieved data files can be
edited to replace the fuel analysis, or run as is to obtain an overall average.
Note: EDS Data Retrieval interface is available for version 6.0 PCalcs release and later.
SP_0030 45
5.1 Starting Run/Debug mode
5.1.4 Fbdorder
The Fbdorder Algorithm Design Screen provides useful project-runtime information. This
information is available in configuration mode for the last execution, and is also available in
run/debug mode for the current execution. You must execute a project at least one time after
upgrading to 3.1 to view this information.
Note: To access the run-time information during the actual run-time, it is necessary to press the
Select button located on the button bar on the right side of the frame on the GPA Main Window
(the very top button) and get into config mode. This button toggles display information from
run/debug mode to config mode for each and every project within a Workspace.
46 SP_0030
5.1 Starting Run/Debug mode
SP_0030 47
5.1 Starting Run/Debug mode
5.1.5 Pntvalidate
The following figures show the (Run Mode) and Debug dialog boxes for the Pntvalidate
algorithm.
48 SP_0030
S E C T I O N 6
IN THIS SECTION
SP_0030 49
6.1 Configuration tab
50 SP_0030
6.1 Configuration tab
Note: The Analoginavg algorithm also contains an Analog Input Averaging section.
FIELD DESCRIPTION
Configuration Tab Name Name of the Algorithm. It is important to give each algorithm a
unique name.
Scan Period This is the time period that is used to gather information. A default
scan period of 10 seconds is used. Once every 10 seconds, the
values are read and recorded. Scan Period timing can be
changed.
Change Button (Analoginavg The scan time or period (typically 10 Sec.) in a project may be
Algorithm only) modified using the Analoginavg Algorithm's Configuration Tab. The
new scan period is applied to all algorithms in the entire project.
Refer to the figure following this table.
Average Type Fixed: Updates once every Average Period (for example, once
every 120 seconds).
Running: Updates every scan period (for example, once after the
first 120 seconds, then again after 130 seconds using data from
period 20 to 130, etc.)
% of Samples with Good Quality If 80% (for example) or higher of the samples result in an average
Quality of "Good", the samples will be marked as "Good".
% of Samples with Bad Quality If 20% (for example) or more of the samples result in an average
Quality of "Bad", the samples will be marked as "Bad".
SP_0030 51
6.1 Configuration tab
52 SP_0030
6.1 Configuration tab
The Analoginavg screen provides an option to retrieve historical data. The following window
appears when Offline in Run Mode of the Analoginavg window. In the lower right corner of this
window the Get Historical Data button is selected to display the Offline Historical Retrieval
window, providing data retrieval options, refer to Historical Data Retrieval (see page 43).
SP_0030 53
6.2 Inputs tab
The Inputs tab shows how the inputs are configured (by using the Tags tab), however, inputs
cannot be changed from this screen.
54 SP_0030
6.3 Outputs tab
The Outputs tab shows how the outputs are configured (by using the Tags tab), however, outputs
cannot be changed from this screen.
SP_0030 55
6.4 Constants tab
The Constants tab allows the constants to be modified. The constants and their values can also
be saved or loaded from a file. The Constants tab fields are described below.
OPTION DESCRIPTION
Clear Storage Info... Deletes the file which contains all the constant values
and removes all internal GPA references to the
constant's storage information. Available for all
algorithms which have a set of constants defined.
Filename Used to save a file in a specific location.
56 SP_0030
6.5 Tags tab
Several algorithms need extra individual setup information to help set up the proper format and
have a separate tab in the algorithms Properties box. The Design Info tab allows you to fill in
data needed for a specific algorithm. Most algorithms do not contain design information.
SP_0030 57
6.6 Design Info tab
In the Create/Configuration Tags section, selecting Create/Configure Tags for... displays the
following dialog box.
58 SP_0030
6.6 Design Info tab
6.6.2 Tags tab create configure tags (project name) Define/Modify set
In the Create/Configure Tags display, when you select Define/Modify Set allows you to set tags
for the algorithm block and also displays the following dialog box.
SP_0030 59
6.6 Design Info tab
The Analoginavg, Analogout, Digitalin, and Digitalout algorithms Output (or Input) section is set up
automatically by the program once the opposite section is set up. For all other algorithms see
Auto-Configure.
Once the algorithm has been set up, make sure to click all of the OK buttons on the way out of
the setup process. The first one saves the tag set to disk. The second one creates the tag in the
project. And the third saves the configuration (with-in the project) to disk.
Note: An ( * ) in the "In Use" column indicates that a particular input or output MUST BE
configured.
On the Define Tag Set screen, the points marked with an ( * ) must be configured, the other
points can be configured if needed. All un-configured points will be initialized to zero. Not all
points have to be configured.
Auto - Configure -Not applicable for the Analoginavg, Analogout, Digitalin, and Digitalout
algorithms. All other algorithms will try and fill in information for tags whose names match exactly
for inputs, or will create exact tag names for outputs.
OPTION DESCRIPTION
Configure this Input Select a tag to be configured, then click the checkbox.
Update List Must be clicked once all tag information is filled in.
Hwy Item Length varies with Data Agent (up to16 chars). Project
specific information.
Create Tag A generic name will be assigned once the units are
chosen. Modify the assigned name to give the tag a
"unique" name.
Engineering Units Choose from a drop-down menu. Tag Names are listed
in Tag Names, Units and Values (see page 101).
Sort Units Alphabetically When checked, units in the pull-down are sorted
alphabetically. If unchecked, units are displayed in logical
groups of the same types of units.
Initial Value Must contain a valid start value, (up to 30 characters).
Project specific information.
For use with Setvalidate Only Checkbox
Tag Description Displays a description of the tag.
Unit
Network
OK Use this button after the setup is complete on each
algorithm. The OK button saves the tag set to disk.
Save Saves tag set to disk.
Save as Reduces work by allowing the tag set configuration to be
saved under different names for use with other
algorithms that are the same or similar.
Rename Renames the tag set.
60 SP_0030
6.6 Design Info tab
OPTION DESCRIPTION
SP_0030 61
6.6 Design Info tab
Create/Update Tags in Entire... - Allows points to be updated for the entire project.
Update All Tag Set.... - Saves having to edit all tag descriptions when an output tag description
has been modified.
The selections in the Mappings group allow the tags to be displayed along with where they are
used. This is a useful tool for debugging the project as tags that are used but have not been
created are identified at the top of the list by asterisks.
The selections in the Mappings group allow the tags to be displayed along with where they are
used. This is a very useful tool in debugging the project as tags that are used but have not been
created are identified at the top of the list by asterisks.
62 SP_0030
6.6 Design Info tab
The following window illustrates the Project-Wide Tag Cross-reference dialog boxes.
SP_0030 63
6.6 Design Info tab
The "Project wide" files Generated using Tag Info section allows a project wide
cross-reference file to be created and updated. The last choice allows an import file to be created
from the cross-reference files. Edit the import file to place the correct Network ID, Unit ID, Drop
ID, Collect Enabled, etc.
64 SP_0030
6.6 Design Info tab
Allows you to build a new project cross-reference file using a previous Projects cross-reference
file.
SP_0030 65
6.6 Design Info tab
66 SP_0030
6.6 Design Info tab
SP_0030 67
6.6 Design Info tab
68 SP_0030
6.6 Design Info tab
This screen is used to change the shape and color of the algorithm box.
SP_0030 69
6.6 Design Info tab
70 SP_0030
6.6 Design Info tab
SP_0030 71
6.6 Design Info tab
72 SP_0030
6.6 Design Info tab
SP_0030 73
6.6 Design Info tab
74 SP_0030
6.6 Design Info tab
SP_0030 75
6.6 Design Info tab
76 SP_0030
6.6 Design Info tab
SP_0030 77
6.6 Design Info tab
78 SP_0030
6.6 Design Info tab
SP_0030 79
6.6 Design Info tab
80 SP_0030
6.6 Design Info tab
SP_0030 81
6.6 Design Info tab
82 SP_0030
6.6 Design Info tab
SP_0030 83
6.6 Design Info tab
Note: The Design Info for the Fbdorder algorithm on the Input document needs to be set after
all documents have been built. This screen also provides useful project-runtime configuration
information in the LAST execution and in run-time mode for the current execution.
84 SP_0030
6.6 Design Info tab
SP_0030 85
6.6 Design Info tab
86 SP_0030
6.6 Design Info tab
SP_0030 87
6.6 Design Info tab
88 SP_0030
6.6 Design Info tab
SP_0030 89
6.6 Design Info tab
90 SP_0030
6.6 Design Info tab
SP_0030 91
6.6 Design Info tab
92 SP_0030
6.6 Design Info tab
SP_0030 93
6.6 Design Info tab
94 SP_0030
6.6 Design Info tab
SP_0030 95
6.6 Design Info tab
96 SP_0030
6.6 Design Info tab
SP_0030 97
6.6 Design Info tab
98 SP_0030
6.6 Design Info tab
SP_0030 99
6.6 Design Info tab
Note: The Design Info for the Fbdorder algorithm on the Input document needs to be set after
all documents have been built.
The Fbdorder algorithm screen also provides useful project-runtime information in the
configuration mode for the LAST execution, and in run-time mode for the current execution. A
project must be executed at least once after upgrading to Revision 3.1 (or later) in order to see
this information.
After setting the properties of each algorithm, go back to Adding Algorithms (see page 29), and
add the next algorithm.
100 SP_0030
S E C T I O N 7
IN THIS SECTION
The GPA tag name beginning letter corresponds to the tag's units. The following table
summarizes the beginning letters along with the units given to each of these categories. The first
unit listed indicates the default units associated with a point. If the units for a point are different
than the default, these units can be selected from the pull-down unit list.
The program will not allow the same tag to be used as an input and output in the same algorithm.
a Area FT2 M2
IN2 CM2
c Specific Heat BTU/LB DEG F KCAL/KG DEG C
KJ/KG DEG C
C Clean Factor NONE NONE
MONEY/MCAL
SP_0030 101
7.1 Tag names
H Pump Head FT M
IN CM
i Current AMPS AMPS
P Power MW MW
KW KW
W W
HP HP
J/SEC
q Rate_Heat_Transf MBTU/HR KCAL/HR
MCAL/HR
KJ/HR
102 SP_0030
7.1 Tag names
SP_0030 103
7.1 Tag names
Every tag's value is converted upon input into the equipment algorithms. A tags value is converted
within a unit type to the default units.
All points starting with a "w" will be converted to KLB/HR before the code is executed. All output
values are also converted from the default units to the specified units. Therefore, if power is to be
output in HP, the power value inside the code will be in MW and converted to be output in HP.
For example:
If a p type point or pressure point is input in INHGV, then, no conversion needs to be done to this
point. The value in INHGV is automatically converted to PSIG.
For example:
Converting from a "wv" flow to a "w" flow, a conversion needs to take place to convert from GPM
to KLB/HR. This particular conversion is performed in the algorithm MASSFLOWLIQUID.
104 SP_0030
S E C T I O N 8
IN THIS SECTION
The following table lists the algorithms in order of their type. Refer to Steamtable Algorithms (see
page 659) for additional information on Steamtable algorithms.
Algorithm Types
Airhtrs Airhtrs This algorithm calculates air heater performance for up to six air
heaters as well as calculating the modified outlet temperature. If the
(Air Heater)
air heaters are tri-sector, the total air inlet and outlet flows are
calculated.
Blr Blrio This algorithm calculates the boiler input/output efficiency and
efficiency deviation from design.
(Boiler)
Boiler The boiler calculates the efficiency by the heat loss method.
Corblrloss This algorithm calculates the corrected boiler efficiency and the
design efficiency and deviation.
Econmz This algorithm calculates economizer efficiency and deviation from
design.
Superhtr This algorithm calculates superheater efficiency and deviation from
design.
Compr Compr This module calculates adiabatic, polytropic, and isothermal
efficiencies.
(Compressor)
Condsr Acndsrcorr This algorithm calculates the condenser pressure for an air cooled
condenser corrected to guaranteed conditions.
(Condenser)
Aircondsr This algorithm calculates the condenser duty, log mean temperature
difference, and the heat transmission coefficient for air cooled
condensers.
SP_0030 105
8.1 Algorithms (Calculation Blocks) List
Cndavgtemp This algorithm calculates the condenser average inlet and outlet
temp as well as the average circulating water temperature.
Cnddesign This algorithm reads in the condenser design data and assigns the
values to outputs as well as calculating the inner diameter for the
different bundle types.
Condsr Condsr This algorithm determines the method for out-of-service
compartments. After checking for out-of-service compartments, the
(Condenser) specific heat, specific volume and specific gravity of circulating water
are calculated.
Next, the condenser duty, the condenser circulating water flow, the
actual and design heat transfer, the cleanliness factor, expected
back pressure with clean tubes and the back-pressure deviation are
calculated.
Cooltwrpwr This algorithm calculates individual cell power, design water flow,
the ratio of design water flow to actual flow, total fan power, and ratio
of design power to actual power.
Coolcurv This algorithm calculates predicted outlet flow, adjusted test flow and
percent capability.
Cturb Basectg This algorithm calculates evaporator/chiller efficiency if one is
present, corrected load, (Combustion ratio to guaranteed or ISO
load, heat input in fuel, total heat input into combustion Turbine)
turbine, thermal efficiency, heat rate, corrected heat rate ratio to
guarantee design or ISO heat rate deviation, corrected turbine
efficiency, heat consumption, exhaust gas heat and exhaust gas
flow.
Combturb This algorithm calculates evaporated/chiller efficiency if one is
present, corrected load, ratio to guaranteed or ISO load, heat input
in fuel, total heat input into combustion turbine, thermal efficiency,
heat rate, corrected heat rate, ratio to guaranteed design or ISO
heat rate, heat rate deviation, corrected turbine efficiency, heat
consumption, exhaust gas heat, estimated air flow to air ratio,
exhaust gas enthalpies at 32 degrees F, exhaust temp and
compressor inlet temp, exhaust gas flow and compressor air flow.
Gastrbintemp This algorithm uses an estimated gas turbine temperature as well as
a calculated gas turbine inlet enthalpy to calculate the actual gas
inlet temperature.
GE_combcyc This algorithm computes the uncorrected plant gross power output,
gross terminal efficiency and gross heat rate in combined cycle
106 SP_0030
8.1 Algorithms (Calculation Blocks) List
Note, gain and bias can be points, constants or both points and
constants.
SP_0030 107
8.1 Algorithms (Calculation Blocks) List
Crossprod This module calculates the cross product based on X and Y inputs
as follows:
Z = C0+C1X + C2X2 + C3Y + C4Y2 + C5XY + C6X2Y + C7XY2 +
C8X2Y2
Where:
C0 - C8 are coefficients
Fan Densityair This routine calculates the density of air at the fan discharge
conditions as well as the density correction factor.
Densitycor This algorithm computes a density corrected to current temperature
and pressure conditions as well as a density correction factor.
Densitygas This algorithm calculates the density of gas at the fan discharge as
well as a density correction factor.
Fan This algorithm computes the efficiencies of the fan and its design
efficiency.
Fandesigh This algorithm reads the fan design information and outputs the
design information.
Fanvelocity This algorithm computes the velocity pressure of the fan using
volumetric flow, density and area.
SPECHTAIR This algorithm calculates the specific heat ratio for air which is
needed in the FAN algorithm to calculate compressibility factor.
SPECHTGAS This algorithm calculates the specific heat ratio for gas which is
needed in the FAN algorithm to calculate the compressibility factor.
Fedhtr Deaerator This is a direct contact type heat exchanger. The steps calculate the
condensate inlet flow, outlet flow, inlet enthalpy and outlet enthalpy.
Extraction steam flow and enthalpy are also calculated.
Drnclr This algorithm calculates drain cooler approach and deviation.
Drnpmp This algorithm calculates heat and materials balance around a shell
and tube type heat exchanger with drain pumped forward.
Extraction, drain, inlet and outlet flows are calculated for the
feedheater. The turbine extraction flow and enthalpy are also
calculated.
Hpfedhtr This algorithm calculates a heat and materials balance around a
shell and tube type heat exchanger. The extraction and drain flows
are calculated. The turbine extraction flow and enthalpy are also
calculated.
Lpfedhtr This algorithm calculates a heat and materials balance around a
low-pressure shell and tube type heat exchanger. The extraction and
drain flows are calculated for the feedheater. The turbine extraction
flow and enthalpy are also calculated.
Ttd This algorithm calculates the thermal temperature difference and
deviation.
Fuels This algorithm combines all the fuels used into one fuel analysis.
Fuels
Gastrbintemp Gastrbintemp This algorithm uses an estimated gas turbine temperature as well as
a calculated gas turbine inlet enthalpy to calculate the actual gas
turbine inlet enthalpy.
108 SP_0030
8.1 Algorithms (Calculation Blocks) List
Hetrte This algorithm calculates gross and net turbine cycle heat rate.
Adjusted turbine cycle heat rates with and without process steam
Heatrate are also calculated.
Hrmspasme This algorithm calculates the fractional heat rate correction factor for
throttle steam pressure being off design as specified by the ASME
PTC 6.1 1984 curve Throttle Pressure Corrections Factors for Single
Reheat Units.
Hrmstasme This algorithm calculates the fractional heat rate correction factor for
throttle steam temperature being off design as specified by the
ASME PTC 6.1, 1984 curve Throttle Temperature Correction
Factors for Single Reheat - Subcritical Pressure.
Hrrpdasme This algorithm calculates the fractional heat rate correction factor for
reheat pressure drop being off design as specified by the ASME
PTC 6.1 1984 curve Reheater Pressure Drop Correction Factors for
Single Reheat Units.
Hrrstasme This algorithm calculates the fractional heat rate correction factor for
reheat steam temperature being off design as specified by the
ASME PTC 6.1 1984 curve Reheat Temperature Correction Factors
for Single Reheat Units.
HRSG Bldwn This algorithm calculates the blowdown flow and enthalpy.
SP_0030 109
8.1 Algorithms (Calculation Blocks) List
Wmncor This algorithm calculates the main steam flow deviation between
reference main steam flow and corrected main steam flow.
Math Absval This algorithm outputs the absolute value of a given input.
Expon This algorithm calculates the exponential value of the input. The
result can be gained and biased by both constants and points.
Gpalog This algorithm calculates the log of a number.
Note that the gain and bias values can be points, constants or both
points and constants.
Multdiv This algorithm multiplies four numbers and divides by four numbers.
Multiply4 This algorithm multiplies 4 numbers together.
Multpwr This algorithm will add eight pairs of numbers multiplied together.
Each number is first raised optionally to a power, gained and biased.
The total result of multiplied pairs can be gained and/or biased. The
total result will also be divided by the sum of the odd inputs.
Nlog This algorithm calculates the natural log of input.
110 SP_0030
8.1 Algorithms (Calculation Blocks) List
Qavg10 This algorithm calculates the average of 10 values. Only the points
with good quality will count in the average.
Qavg4 This algorithm calculates the average of 4 values. Only the good
quality points will be counted in the averaged value.
Sin Sine algorithm.
Math (cont.) Squareroot This algorithm calculates the square root of a given input.
Sub10 This algorithm subtracts the sum of 10 values from the input value.
Misc Asmeflowcomp This algorithm calculates ASME on-line compensated flow based on
temperature, pressure, differential pressure, flow medium, flow
element, element material, pressure tap type, element inner
diameter, and beta ratio.
Avalgen This algorithm takes the value of a number, multiplies by the gain
and adds the bias.
Co2econ This algorithm converts wet O2 at econ outlet to dry O2 at econ
outlet.
Dvalgen This algorithm calculates a digital output based on a digital flag
anded with a digital constant.
Emptyproject This algorithm does nothing, but it is required for synchronization of
multiple projects per Workspace.
Enthal This algorithm calculates the gas enthalpy given the fuel analysis,
gas temperature, weight of ambient and injection moisture, and
reference enthalpy.
Flowcalccomp This algorithm calculates on-line compensated flow.
Frloss This algorithm calculates pipe section friction loss for fairly smooth
pipe.
Heartbeat This algorithm outputs the value of the constant followed by the
value of the constant multiplied by -1, then continue this sequence of
values. This algorithm toggles the constant value to be used in
controller logic to show that the GPA is running.
Massflowliquid This algorithm calculates mass flow from volumetric flow.
Mixer This algorithm calculates enthalpy, flow and heat for 10 combined
flows.
Moistair The moist air function calculates the ambient humidity given two of
the following (tambnt, twetblb, wv' relhum). Moist air calculates the
other two input values not input to the routine.
Select10 This algorithm selects an analog input based on the selected analog
input value.
Setdig This algorithm sets a digital to 1 if an analog value is greater than
the limit. Otherwise, the digital is set to zero.
Setdig2 This algorithm sets one of the three digital flags. If the specified
analog value is less than the limit, the first flag is set. If the analog
value is equal to the limit, the second flag is set. If the analog value
is greater than the limit, the third flag is set.
SP_0030 111
8.1 Algorithms (Calculation Blocks) List
Specheatair This algorithm calculates the specific heat of air at a given air
temperature. The coefficients used are obtained from regressing the
curve in Figure 3 of ASME PTC-4.1.
Specheatgas This algorithm calculates the specific heat of flue gas at a given
temperature. The coefficients are obtained from regressing the curve
in Figure 7 of AMSE PTC-4.1.
Steadystate This algorithm checks for periods of steady state and logs the steady
state periods to the event logger. If the system stays in state beyond
the maximum number of cycles, an event message is logged and
the steady state counter is reset
Volflowgas This algorithm converts a mass gas flow to a volumetric flow.
Output Analogout This algorithm outputs analog data agent points from local input
values.
Digitalout This algorithm outputs digital data agent pts. from local digital
values.
Pump Bfpturb This algorithm calculates boiler feedpump turbine performance.
Pump This algorithm computes the actual efficiency, design efficiency and
efficiency deviation for a pump.
Pump1Spd This algorithm calculates pump performance for a pump which runs
at constant speed.
Pump2Stg This algorithm calculates pump performance for a pump which has
an extraction or discharge between two stages of the pump.
Steamtable See the Steamtable Algorithm Section, Section 10.
Sturb Alstomexpan This algorithm computes used energy end point, expansion line end
point, low pressure turbine last stage extraction flow and enthalpy,
and last stage heater extraction flow and enthalpy for Alstom steam
turbo generators.
Expelep This algorithm computes expected expansion line end point design
curve not provided.
Gencorr This function computes corrected steam turbine generator output
bases on correction curves provided by turbine manufacturer.
Gennet This algorithm calculates the generator mva, the generator power
factor, the auxiliary power, the ratio of auxiliary power to gross
power, the total shaft power and generator efficiency.
Ipturbdeseff This function calculates design (or expected) intermediate pressure
turbine efficiency using the method outlined in Chapter 4, section
iii.a.1, in K.C. Cotton's Evaluating and Improving Steam Turbine
Performance. The function calculates the expected efficiency from
the inlet bowl conditions to the turbine exhaust. The calculated
expected efficiency is then corrected to compute the expected
efficiency from the turbine inlet conditions to the measured
crossover conditions.
Lpturb This algorithm calculates the lp turbine outlet flow, the lp turbine
outlet enthalpy by conducting a thermal and energy balance around
the whole turbine, the lp isentropic enthalpy and the lp turbine
efficiency.
112 SP_0030
8.1 Algorithms (Calculation Blocks) List
Overall_trb This algorithm calculates overall turbine efficiency from the hp stage
to the lp stage using the enthalpy drop method.
Reheat_trb This routine calculates the reheat turbine efficiency, design
efficiency and deviation. The design efficiency is obtained by
calculating the expected used energy end point.
Turbgen This function computes heat generated and percent load produced
by each turbine section.
Turbin This algorithm calculates the turbine inlet enthalpy, the turbine outlet
flow, the turbine outlet enthalpy, the isentropic enthalpy and the
turbine efficiency.
Wexpan This algorithm computes used energy end point, expansion line end
point, low pressure turbine last stage extraction flow and enthalpy,
and last stage heater extraction flow and enthalpy for Westinghouse
steam turbo generators.
Unithr Unhraitdev This algorithm calculates the unit heat rate deviation for air heater air
inlet temperature deviation & cost of deviation.
Unhrasmecsc This algorithm calculates the ASME heat rate correction for five
degrees Fahrenheit of subcooling at the percent of valves wide open
throttle flow.
Unhrasmeffw This algorithm calculates the ASME heat rate correction for five
degrees Fahrenheit final feedwater temperature deviation at the
percent of valves wide-open throttle flow.
Unhrasmeipdev1 This algorithm calculates the ASME IP turbine loss factor number 1
as a function of ip exhaust pressure.
Unhrasmeipdev2 This algorithm calculates the ASME IP turbine loss factor number 2
as a function of ip exhaust pressure.
Unithr (cont.) Unhrasmemkp This algorithm calculates the ASME heat rate correction for
one-percent makeup flow at the percent of valves wide open throttle
flow.
Unhrasmersf This algorithm calculates the ASME heat rate correction for
one-percent reheat spray flow at the percent of valves wide-open
throttle flow.
Unhrasmessf This algorithm calculates the ASME heat rate correction for
one-percent superheat spray flow at the percent of valves wide open
throttle flow.
Unhrauxdev This algorithm calculates the unit heat rate deviation for auxiliary
power deviation and the cost of the deviation.
Unhrauxstm This algorithm calculates the unit heat rate deviation for auxiliary
steam and the cost of the deviation.
Unhrbfpt This algorithm calculates the unit heat rate deviation for the total
boiler feed pump turbine auxiliary steam heat rate and the cost of
the deviations.
Unhrcbp This algorithm calculates unit heat rate deviation for main steam
temperature and the cost of the deviation in $/hr.
Unhrcontot This algorithm compute the total unit heat rate deviations and cost of
the deviation in $/hr for the controllable parameters.
Unhrcsc This algorithm calculates unit heat rate deviation for condenser
SP_0030 113
8.1 Algorithms (Calculation Blocks) List
114 SP_0030
S E C T I O N 9
Algorithm properties
IN THIS SECTION
SP_0030 115
8.1 Algorithms (Calculation Blocks) List
116 SP_0030
8.1 Algorithms (Calculation Blocks) List
SP_0030 117
9.1 Absval
9.1 Absval
ABSVAL
Analog Inputs
kvalue input to abs val algorithm REQUIRED Input value for absolute
value function
kptgain abs val gain value [Optional]
kptbias abs val bias value [Optional]
Digital Inputs
Analog Outputs
Digital Outputs
Constants
kcgain = 1
kcgain = 0
118 SP_0030
9.1 Absval
Absval calculates the absolute value of the input kvalue. The result can be gained and biased by
the kcgain and the kcbias points.
Absval Overview:
kabsval_res = fabs(kvalue)
kgain = kptgain + kcgain
kbias = kptbias + kcbias
kabsval_res = (kabsval_res * kgain) + kbias
SP_0030 119
9.2 ACNDSRCORR
9.2 ACNDSRCORR
This module calculates the condenser pressure for an air cooled condenser corrected to
guaranteed conditions.
ACNDSRCORR
Analog Inputs
120 SP_0030
9.2 ACNDSRCORR
ACNDSRCORR
Digital Outputs
Constants
DEG_CtoKEV 273.15
KMSUBK 0.45
KEXPFANPWR1 0.66666667
KEXPFANCORR1 -0.3745
KEXPFANCORR2 -0.206
KEXPFANCORR3 -1.0
KCONSTA 23.308417
KCONSTB 3888.11
KCONSTC 229.95
SP_0030 121
9.2 ACNDSRCORR
Calculate the correction for exhaust pressure and inlet air temp
122 SP_0030
9.2 ACNDSRCORR
SP_0030 123
9.3 Add4
9.3 Add4
ADD4
Analog Inputs
Analog Outputs
kadd4_res add4 result value REQUIRED Result of the four inputs added
together.
Digital Outputs
Constants
kcgain = 1
kcbias = 0
The Add4 algorithm calculates the result of adding input kvalue1-kvalue4. The result can also be
gained and biased by the kcgain and the kcbias points.
Add4 Outputs:
124 SP_0030
9.4 Add10
9.4 Add10
ADD10
Analog Inputs
SP_0030 125
9.4 Add10
This algorithm calculates the result of adding inputs kvalue1- kvalue10. The result can also be
gained and biased by the kcgain and the kcbias points.
Add10 Outputs:
126 SP_0030
9.5 Addsub
9.5 Addsub
The Addsub algorithm adds four numbers together and subtracts four numbers.
ADDSUB
Analog Inputs
Analog Outputs
Digital Outputs
Constants
kcgain = 1
kcbias = 0
The Addsub algorithm calculates the result of adding inputs kaddval4 subtracting the total of
subval1-ksubvalue4. The result can also be gained and biased by the kcgain and the kcbias
points.
Addsub Outputs
SP_0030 127
9.5 Addsub
128 SP_0030
9.6 AIRCONDSR
9.6 AIRCONDSR
The AIRCONDSR algorithm calculates the condenser duty, log mean temperature difference, and
the heat transmission coefficient for air cooled condensers.
AIRCONDSR
Analog Inputs
Analog Outputs
Digital Outputs
Constants
TCNDEXHSTPCNT 0.9375
SP_0030 129
9.6 AIRCONDSR
Compute the condenser saturation temperature as a saturated liquid steam table function of the
absolute condenser pressure.
tcndvac =tslp(pabscndprs)
Calculate the condenser saturation inlet temperature as a percentage of the exhaust saturation
temperature -- approximately 94 percent of the exhaust saturation temperature value
Calculate the terminal temperature difference by subtracting the air outlet temperature from the
condenser saturation temperature.
Calculate the initial temperature difference by subtracting the air inlet temperature from the
saturation temperature.
Calculate the subcooling by subtracting the condensate temperature from the condenser
saturation temperature.
hcnsat = hslp(pabscndprs)
Calculate actual heat transfer from the condenser duty,area and log mean temperature difference.
130 SP_0030
9.7 Airhtrs
9.7 Airhtrs
The Airhtrs algorithm calculates air heater performance for up to six air heaters as well as
calculating the modified outlet temperature. If the air heaters are tri-sector, the total air inlet and
outlet flows are calculated. The air heater leakage(s) are calculated if measurements are
available. Otherwise, the leakage(s) are entered from a point as an approximation or as an
estimate from the design screen.
AIRHTRS
SP_0030 131
9.7 Airhtrs
AIRHTRS
132 SP_0030
9.7 Airhtrs
AIRHTRS
SP_0030 133
9.7 Airhtrs
AIRHTRS
134 SP_0030
9.7 Airhtrs
AIRHTRS
SP_0030 135
9.7 Airhtrs
AIRHTRS
zdocalc REQUIRED
136 SP_0030
9.7 Airhtrs
AIRHTRS
SP_0030 137
9.7 Airhtrs
AIRHTRS
138 SP_0030
9.7 Airhtrs
AIRHTRS
SP_0030 139
9.7 Airhtrs
AIRHTRS
140 SP_0030
9.7 Airhtrs
AIRHTRS
SP_0030 141
9.7 Airhtrs
AIRHTRS
142 SP_0030
9.7 Airhtrs
AIRHTRS
Air heaters transfer heat from the exiting flue gas to the incoming combustion air. This process
increases boiler efficiency. Changes in air heater performance influences boiler efficiency as
reflected in changes to flue gas exit temperature. Flue gas exit temperature increases as air
heater gas side efficiency decreases.
This algorithm calculates the air heater gas side efficiency. It is capable of handling a maximum of
six air heaters. The temperature differences between the gas inlet and gas outlet temperatures
are calculated. If an air heater gas temperature difference is greater than its minimum value, the
heater is considered to be in service.
If airhtrs are trisector heaters, then the air heater air inlet and air outlet temperatures are
calculated. Total airflow equals the primary airflow plus the secondary airflow. The air inlet and air
outlet temperatures are calculated as weighted averages.
The leakage for each air heater is calculated if the oxygen measurement is available before and
after the air heater. Otherwise the leakages must be supplied as a point or entered on the design
screen. The air heater leakage is expressed as a percentage of the gas flow entering the air
heater.
The flue gas exit temperature must be corrected for because air heater leakage cools the gas
leaving the air heater. If left uncorrected, the lower gas temperature results in erroneously high,
calculated boiler efficiency.
Air inlet and air outlet temperatures are calculated as follows for tri-sector air heaters:
Gas side efficiency is the ratio of the gas temperature drop to the temperature head. The
no-leakage exit gas temperature is used in the calculation.
Where:
SP_0030 143
9.7 Airhtrs
Rahlkg = Air heater leakage percentage of gas flow entering air heater
cahair = specific heat of air
thtr_calc_airin = temperature of air entering air heater
The X-Ratio is defined as the ratio of the gas temperature drop to the air heater temperature rise.
else
Fahxratio4 = 0.0;
Fahxratiodev4 = Fahxratio4 - (Fahxratiodes4 * kinsvcah4);
Where:
144 SP_0030
9.8 Alstomexpan
9.8 Alstomexpan
The Alstomexpan function computes used energy end point, expansion line end point, low
pressure turbine last stage extraction flow and enthalpy, and last stage heater extraction flow and
enthalpy for Alstsom steam turbo-generators in an iterative procedure using the GER2007C
expansion line equations. Assume the expansion line is straight.
ALSTOMEXPAN
Analog Inputs
SP_0030 145
9.8 Alstomexpan
ALSTOMEXPAN
146 SP_0030
9.8 Alstomexpan
ALSTOMEXPAN
SP_0030 147
9.8 Alstomexpan
ALSTOMEXPAN
Constants
hdelta 25.0
WVSEG0 110.0
WVSEG1 160.0
WVSEG2 260.0
WVSEG3 360.0
WVSEG4 520.0
WVSEG5 520.0
lpturbends 4.0
exloss1 [4] 57.958544, -1.3774511, 0.012635167, -4.0471311e-05
exloss2 [4] 17.419598, -0.25917085, 0.0013693467, 0.0
exloss3 [4] -18.55, 0.1630571, 0.00013392857, 0.0
exloss4 [4] -169.65873, 1.5955026, -0.0041911683, 4.0509259e-06
exloss5 [4] -90.905844, 0.73675144, -0.0012391775, 7.8914141e-07
exloss6 [4] -90.905844, 0.73675144, -0.0012391775, 7.8914141e-07
148 SP_0030
9.8 Alstomexpan
The Lp turbine last stage extraction to low pressure heater is normally in the wet steam region.
This function is an expansion line swing method to solve for the lp heater (and last stage)
extraction flow and enthalpy, the used energy end point (hueep) and expansion line end point
(helep).
If the last stage extraction is superheated, the extraction enthalpy is calculated directly as a
superheated steam function of extraction steam temperature and pressure at the heater shell. If
the heater is not in-service, the extraction steam flow and enthalpy are set to zero, and the hueep
and helep are solved for directly.
Set expansion line curvature constant (khzero) to 1500 to designate a straight line
khzero = 1500.0;
Calculate average condenser back pressure (pacnprs). This is low pressure turbine exhaust
pressure.
Calculate dry specific volume at exhaust pressure of each low pressure turbine
vdrylp = vsvp(pacnabslp);
vdryhp = vsvp(pacnabshp);
Calculate steam flow to lp turbine last stage by subtracting lp turbine extractions from crossover
flow (witrex).
Calculate heat acquired by steam (qsttot) by calculating a steam heat balance around the turbine
Calculate heat in turbine extractions, excluding lp turbine last stage, by summing the product of
flow and enthalpy for each turbine stage extraction.
Calculate heat flow to glands - the total heat supplied to the steam seal regulator & gland steam
condenser minus lp gland supply.
SP_0030 149
9.8 Alstomexpan
if (zlpheater > 0)
Heater in-service, extraction steam superheated if extraction temp greater than saturation temp.
Otherwise, the steam is wet. Calculate degrees superheat (tshtlphtr) as the difference between
the measured heater extraction steam temp (textrlphtr) and the heater saturation temp (tsatlphtr)
and test for superheated steam.
Superheated steam. calculate enthalpy directly as function of temp and absolute pressure.
else
hextrlphtr = hsvp(pabsextrlphtr);
hwtstm = 10000.0;
If flash tank present (flag zflashdrain set true) upstream heater drain goes to flash tank, and lp
heater inlet drain flow argument is set to zero. If a flash tank is not present, the inlet drain flow
argument is set to the upstream drain flow (wdrnoutup). The flash steam flow argument is zeroed
if a flash tank is not present.
if (zflashdrain > 0)
wflashin = wflashsteam;
else
wdrainin = wdrnoutup;
If the lp heater is in service, both the heater extraction enthalpy (hextrlphtr) and estimated
enthapy (hnew) are recalculated during the iterative procedure. Iterate until the absolute
difference between hfhelphtr and hnew is <= 0.1 btu/lb, or the number of iterations is exceeded.
Zero overall iteration counter.
kcntlphtr = 0.0;
while ((fabs(hextrlphtr - hwtstm) > 0.1) && (kcntlphtr <= 30))
if (zlpheater > 0)
Heater in service, calculate lp heater and lp turbine last stage extraction flow and enthalpy.
Update current estimate of lp heater extraction enthalpy.
hwtstm = hextrlphtr;
150 SP_0030
9.8 Alstomexpan
Low pressure heater drain pump present and in service if flag zlpdrainpump set.
if (zlpdrainpump > 0)
Drain pump present and in service. Low pressure heater drain pumped forward into condensate
before upstream heater. Calculate extraction steam flow at heater shell (wextrlphtr) by performing
a heat balance. Calculate drain flow (wdrnoutlphtr). No flash tank if drain pumped forward.
Calculate flow leaving heater (wfhoutltlphtr) by subtracting drain flow pumped forward
(wdrnoutlplphtr) from condensate flow (wcndea). Set heater inlet flow to outlet flow.
else
Calculate extraction flow at heater shell from heat balance, and calculate drain flow.
Set condensate flows into and out of heater to condensate flow to deaerator.
wfhoutlphtr = wcndea;
wfhinlphtr = wcndea;
Set conditions at turbine (wturblaststg, hturblaststg) to flow and enthalpy at heater shell. There is
no leakage to extraction line.
wturblaststg = wextrlphtr;
hturblaststg = hextrlphtr;
Calculate low pressure turbine exhaust flow (wltrex) by subtracting calculated lp turbine last stage
extraction flow (wturblaststg) from steam flow to last stage (wstmlaststg).
SP_0030 151
9.8 Alstomexpan
Calculate used energy end point (low pressure turbine exhaust enthalpy) by conducting a thermal
and electrical energy balance around the whole turbine to establish the net heat flow to the
condenser and the dividing by the net steam flow to the condenser which is the low pressure
turbine exhaust flow.
Total heat in turbine stage extractions (qext) by summing the heat in previous extractions
(sumext) to the heat in the number 7 extraction.
Calculate net heat in low pressure turbine exhaust (qexhst) by subtracting heat in turbine stage
extractions (qext), heat flow to glands (qleaks) and generation energy (qgen) from net heat
acquired (qsttot).
Calculate low pressure turbine exhaust enthalpy (hltrex) by dividing net heat in exhaust (qexhst)
by exhaust steam flow (wltrex). Set used energy end point (ueep) to exhaust enthalpy (hltrex).
This is average used energy end point of both low turbines.
The exhaust loss and expansion line end point are calculated by an iterative procedure because
the moisture at the expansion line end point has to be known to calculate exhaust loss. Once the
expansion line end point has converged, an expansion is projected from the expansion line point
to the stauration line. The lp turbine last stage extraction enthalpy is initially assumed to be
saturated, and is calculated using an expansion line swing method.
Calculate initial expansion line end point estimate (helepes) by subtracting constant enthalpy drop
(hdelta = 25 btu/lb) from used energy end point (hueep).
Calculate expansion line end point (helepe) by iterative procedure until elep and estimated elep
(helepes) within 0.1 btu/lb. do not exceed 30 ierations.
helepe = 10000.0;
kcount = 0;
while ((fabs(helepe - helepes) > 0.1) && (kcount <= 30.0))
Increment number iterations. reset estimated elep (helepe) to new calculated value (helepes).
152 SP_0030
9.8 Alstomexpan
Calculate quality of the steam (qltrex) at estimated expansion line end point (helepe) and average
turbine exhaust pressure (pacnabs).
Calculate low pressure exhaust hood specific volume of exhaust steam (vcnprslp) by.
Calculate lp hood exhaust loss per end. Assume total exhaust loss equally divided between lp
and hp hoods. There are lpturbends / 2 per hood.
Calculate lp hood exhaust loss (hexlsslp) as function of lp hood exhaust vol flow per end
(wvolexhstlp) based on Westinghouse exhaust loss curve.
else
else
else
else
else
SP_0030 153
9.8 Alstomexpan
Calculate high pressure exhaust hood specific volume of exhaust steam (vcnprshp) by multiplying
dry specific volume (vdryhp) by the moisture factor.
Calculate hp hood exhaust loss per end. Assume total exhaust loss equally divided between lp
and hp hoods. There are lpturbends / 2 per hood.
Calculate hp hood exhaust loss (hexlsshp) as function of hp hood exhaust vol flow per end
(wvolexhsthp) based on Westinghouse exhaust loss curve.
else
else
else
else
else
154 SP_0030
9.8 Alstomexpan
Estimate new expansion line endpoint (helepes) as function of used energy end point (ueep),
exhaust loss (hexlss) and percent moisture at expansion line end point using General Electric
equation defined in K.C. Cotton's "Evaluating and Improving Steam Turbine Performance".
helepes = hueep - 0.87 * hexlss * (1.0 - 0.01 * Rmstrex) * (1.0 - 0.0065 * Rmstrex);
Set expansion line end point (helep) to final calculated estimate (helepes), set error flag (errflg) if
no convergence. This is average expansion line end point for both low pressure turbines.
helep = helepes;
if ((kcount > 30.0) || (textrlphtr > tsatlphtr) || (zlpheater == 0))
if (kcount > 30.0)
zerrflag = 1;
break;
Calculate entropy, enthalpy coordinates on the expansion line in the wet region at the last stage
extraction pres (pabsturblaststg) using expansion line equation in GER2007C. The lp heater, last
stage extraction, low pressure turbine exhaust flow, used energy end point and expansion line
end point calculations are repeated using the new lp heater extraction enthalpy until the estimated
and calculated extraction enthalpies agree within 0.1 btu/lb.
Calculate the entropy (selep) at the calculate expansion line end point (helep) and turbine exhaust
pressure (pacnabs).
Calculate the GER2007C rzero term. First calculate required exponent (krzexpn).khzero is
expansion line curvature constant.
For first pass assume initial estimate (hnew) of last stage extraction enthalpy is saturated steam
function of extraction pressure (pabsturblaststg).
hnew = hsvp(pabsturblaststg);
hest = hnew;
Calculate entropy (sest) at estimated extraction enthalpy (hest) and last stage extraction pressure
(pabsturblaststg). Test for error condition if subccooled enthalpy return. In this case, set error flag
and exit the function.
zerrflag = 1;
break;
SP_0030 155
9.8 Alstomexpan
else
sest = stemp;
Calculate new last stage extraction enthalpy (hnew) by adding the product of the expansion line
curvature (hzero) times the difference between the expansion line entropy (sxline) and estimated
last stage extraction entropy (sest) to the current estimated extraction enthalpy (hest).
Convergence. Calculate overall iterative loop result - heater 7 extraction enthalpy (hextrlp) and
number 7 extraction enthalpy (hturb7).
hextrlphtr = hnew;
hturblaststg = hnew;
zerrflag = 1;
For parallel heaters, calculate a,b parameters. Assume the total last stage extraction flow is
equally divided between the two heaters.
if (zlpparallel > 0)
156 SP_0030
9.9 Analoginavg
9.9 Analoginavg
The Analoginavg algorithm inputs from the selected input source and outputs averaged local
values.
ANALOGINAVG
Analog Inputs
Analog Outputs
Constants
The configured inputs are averaged according to the settings set on the design screen.
Analoginavg Outputs
The analog outputs ainput1_avg, ainput2_avg, etc are assigned the average value of ainput1,
ainput2, etc.
SP_0030 157
9.10 Analogout
9.10 Analogout
The Analogout algorithm outputs to configured output source from local input values.
ANALOGOUT
Analog Inputs
Analog Outputs
Constants
The Analogout algorithm outputs the configured inputs to the selected output.
Analogout Outputs
The local tags (ainput1, ainput2, etc.) are configured to the analog inputs and sent to the selected
output source for the configured tags (aoutput1, aoutput2, etc.).
158 SP_0030
9.11 And6
9.11 And6
AND6
Analog Inputs
Digital Inputs
Digital Outputs
Constants
And6 Outputs
zand6_result = zdvalue1 & zdvalue2 & zdvalue3 & zdvalue4 & zdvalue5 & zdvalue6;
SP_0030 159
9.12 Anlgcmp2poly
9.12 Anlgcmp2pol y
The Anlgcmp2poly algorithm calculates the y-value of a polynomial based on an x input and can
be split into two polynomials by an Analog value.
ANLGCMP2POLY
Analog Outputs
Digital Outputs
Constants
160 SP_0030
9.12 Anlgcmp2poly
Anlgcmp2poly calculates the y-value of a polynomial based on an x input and can be split into two
polynomials by the comparing the total of analog inputs kptload + kcload the total of analog inputs
kptlimit + kclimit. The result can also be gained and biased.
Anlgcmp2poly Outputs
else
SP_0030 161
9.13 Anlgcmppoly
9.13 Anlgcmppol y
The Anlgcmppoly algorithm calculates the y-value of a polynomial based on the x input between
two values.
ANLGCMPPOLY
Analog Inputs
Analog Outputs
Digital Outputs
Constants
The Anlgcmppoly algorithm calculates the y-value of a polynomial based on the x input (kptload +
kcload) between the total of the lower limit (kptlolimit + kclolimit) and the upper limit (kptuplimit +
kcuplimit). If the x input does not fall within this range, the result (kyvalue) is set to zero.
Anlgcmppoly Outputs
162 SP_0030
9.13 Anlgcmppoly
else
kyvalue = 0
SP_0030 163
9.14 Asmeflowcomp
The Asmeflowcomp algorithm performs a routine that compensates flow according to ASME
standards. This module calculates ASME on-line compensated flow based on temperature,
pressure, differential pressure, flow medium, flow element, element material, pressure tap type,
element inner diameter and beta ratio.
ASMEFLOWCOMP
Analog Inputs
Analog Outputs
164 SP_0030
9.14 Asmeflowcomp
ASMEFLOWCOMP
Constants
Asmeflowcomp takes the analog input (kvalue) and multiplies by the gain (kptgain + kcgain) and
adds the bias (kptbias + kcbias).
Asmeflowcomp Outputs
Check for negative and zero pressures and temperatures. If negative, set the flow to zero with
bad quality. Also, check for inputs out of range.
Next, the design screen information is read in and the following calculations are performed.
SP_0030 165
9.14 Asmeflowcomp
For steam, the following calculations are done according to the ASME flow compensation.
kviscosity = vcsstp(tempcomp,pabscomp)
kpres_ratio = (pabscomp - pabsdeltap) / pabscomp
kdelta_ratio = pabsdeltap / pabscomp
volcomp = vsstp(tempcomp,pabscomp)
denscomp = 1.0 / volcomp
Calculate the compensation factor for the element type. For nozzles,
For orifices,
BEGIN LOOP
For nozzles,
ktap1 = 1.0
if (kreynolds < 1.0E06) ktap1 = 0.5
if (kreynolds > 1.0E06) ktap1 = 0.2
ktap_corr = (0.9975 - 0.00653 * pow((1.0E06 / kreynolds),ktap1)) * 1.0 / sqrt(1.0 - kbeta4)
166 SP_0030
9.14 Asmeflowcomp
ktap1_c1 = 0.0
else
ktap1_c2 = 0.0
else
ktap1_c3 = 0.0
else
SP_0030 167
9.14 Asmeflowcomp
END LOOP
Convert the calculated flow to the default units, KLB/HR. Note that the units will still be
converted to the user selected units.
168 SP_0030
9.15 Arctan
9.15 Arctan
ARCTAN
Analog Inputs
Analog Outputs
Digital Outputs
Constants
kcgain = 1
kcbias = 0
Arctan calculates the arc tangent of the input value (kvalue). The result can also be gained and
biased.
Arctan Outputs
karctan_res = atan(kvalue)
kgain = kptgain + kcgain
kbias = kptbias + kcbias
karctan_res = (karctan_res * kgain) + kbias
SP_0030 169
9.16 Avalgen
9.16 Avalgen
The Avalgen algorithm takes the value of a number, multiplies by the gain and adds the bias.
AVALGEN
Analog Inputs
Analog Outputs
Digital Outputs
Constants
kcgain = 1
kcbias = 0
Avalgen takes the analog input (kvalue) and multiplies by the gain (kptgain + kcgain) and adds the
bias (kptbias + kcbias).
Avalgen Outputs
kavalgen_res = kvalue;
kgain = kptgain + kcgain;
kbias = kptbias + kcbias;
kavalgen_res = (kavalgen_res * kgain) + kbias
170 SP_0030
9.17 Avg4
9.17 Avg4
AVG4
Analog Inputs
zdocalc REQUIRED
Analog Outputs
Digital Outputs
Constants
kcgain = 1
kcbias = 0
The Avg4 algorithm averages the configured analog inputs (kvalue1-kvalue4) and multiplies by
the gain (kptgain + kcgain) and adds the bias (kptbias + kcbias).
Avg4 Outputs
If at least 1 point is configured, the average is calculated where kpts = number of points
configured.
SP_0030 171
9.18 Avg10
9.18 Avg10
AVG10
Analog Inputs
Analog Outputs
Digital Outputs
Constants
kcgain = 1
kcbias = 0
172 SP_0030
9.18 Avg10
Avg10 averages the configured analog inputs (kvalue1-kvalue10) and multiplies by the gain
(kptgain + kcgain) and adds the bias (kptbias + kcbias).
Avg10 Outputs
If at least 1 point is configured, the average is calculated where kpts = number of points
configured.
SP_0030 173
9.19 Basectg
9.19 Basectg
BASE CTG
Analog Inputs
FPcorcmpinlt comp inlet temp pwr corr fact [Optional] Required if compressor
inlet temperature power corr factor
is used.
FPcorcmpinlp comp inlet press pwr corr fact [Optional] Required if combustion
turbine inlet pressure loss power
corr factor is used.
FPcorexhpr exaust press power corr fact [Optional] Required if combustion
turbine exhaust pressure loss
power corr factor is used.
174 SP_0030
9.19 Basectg
BASE CTG
SP_0030 175
9.19 Basectg
BASE CTG
Digital Inputs
Analog Outputs
176 SP_0030
9.19 Basectg
BASE CTG
wctexh combust turb exhaust gas flow [Optional] Used in hrsg algorithm.
hctdes comb turb des exhaust gas enth [Optional] Used in hrsg algorithm.
hctcompin xhst gas enth @comp inlet temp [Optional] Used in hrsg algorithm as
hctref input.
hctexhout exhst gas enth @exhst gas temp [Optional]
kcompadb ideal gas const for comp in temp [Optional]
SP_0030 177
9.19 Basectg
BASE CTG
Constants
PDELTACOMP,20.0 Delta between the inlet and outlet (If the pressure difference is less
compressor pressures than this delta, compressor
calculations will not be done.)
If a chiller is present,
if (InServiceLogic == DIGITAL)
if (zchiller_on)
zdochiller = 1;
else
tchiller_thresh = TempRiseThresholdVal
tchiller_drop = fabs(tchilleroutlt - tchillerinlt);
zdochiller = 1;
if (zdochiller)
else
eevapact = 0.0;
eevapdev = 0.0;
Calculate the ideal gas constant which is computed as a polynomial function of compressor inlet
temperature.
178 SP_0030
9.19 Basectg
Correct ctg output to ISO or guarantee by dividing measured output by the product of the
correction factors used. The possible correction factors are inlet temperature, inlet pressure loss,
exhaust pressure loss, injection loss, atmospheric pressure and relative humidity.
Calculate total heat in the fuel by adding the sensible heat (qsensheat) to the heat input at
standard base conditions - the product of mass flow (wtotfuel) and the net heat at standard base
conditions.
if (CTHeatingValue() == HV_LOWER)
qfuelin = (wtotfuel * hlhvfuel) / 1000;
else
Calculate total heat input to the combustion turbine (qctintot) as the sum of heat input in the fuel
and the heat input in the steam injection (power augmentation) if steam injection present.
Calculate injection steam enthalpy (hinj), injection steam enthalpy at reference temperature & the
heat in the injection steam (qinj)
Calculate heat in injection. per ASME PTC 4.4 the heat in the injection is calculated by multiplying
the injection flow (winj) by the enthalpy difference between the injection enthalpy (hinj) and the
enthalpy of the injection (hinjref) at the reference temperature.
SP_0030 179
9.19 Basectg
else
pabsinj = 0.0;
hinj = hlst(tinj);
qinj = (winj * hinj) / RHTCNV;
else
Injection not present, set absolute pressure, injection enthalpy and injection enthalpy at reference
temperature and heat in injection to zero.
pabsinj = 0.0;
hinj = 0.0;
qinj = 0.0;
Calculate total heat to combustion turbine (qctintot) as the sum of heat input in the fuel (qfuelin)
and heat in steam injection (qstminj)
Calculate operating thermal efficiency as the ratio of the heat output in power (qctpwrout) to the
heat input (qctintot)
Calculate combustion turbine heat rate as ratio of heat input (qctintot) to measured power
(Pcombturb)
Correct ctg heat rate to ISO or guarantee by dividing measured output by the product of the
correction factors used. The possible correction factors are inlet temperature, inlet pressure loss,
exhaust pressure loss, injection loss, atmospheric pressure and relative humidity.
Calculate deviation between corrected heat rate (rhrctcorr) and design ct heat rate (rhrctdes)
180 SP_0030
9.19 Basectg
Calculate heat output in exhaust gases per ASME PTC 4.4 by subtracting heat output in power
(qctpwrout) and miscellaneous heat losses (estimated to be a percentage of the total heat in fuel)
from the total heat input (qctintot)
Check the point for miscellaneous losses first and if configured, use this value. If not configured,
use the value from the design screen.
if (kpcnthtloss configured)
kmischeatloss = kpcnthtloss;
else
kmischeatloss = CTMiscHeatLossPct();
qctexh = qctintot - qctpwrout - (kmischeatloss/100.0 * qfuelin);
Calculate estimated fuel to air ratio. divide gas flow by estimated air flow (wctestair).
SP_0030 181
9.20 Bfpturb
9.20 Bfpturb
The Bfpturb algorithm is the boiler feed pump turbine algorithm. This algorithm is used to
calculate performance of the feed pump turbine that can be supplied by:
high pressure steam only.
low pressure (or extraction) steam only.
mixed high pressure and low pressure steam.
Mixed supply steam and isentropic enthalpies are computed. Boiler feed pump turbine exhaust
steam enthalpy is computed by a heat balance comparing the heat in the steam to the work done
on the water by the boiler feed pump, that is, the water horsepower. Turbine efficiency is
computed and compared to design efficiency.
BFPTURB
Analog Inputs
182 SP_0030
9.20 Bfpturb
BFPTURB
Analog Outputs
Constants
SP_0030 183
9.20 Bfpturb
Boiler feed pumps are important pieces of auxiliary equipment whose condition plays a major role
in the heat rate and maximum capacity of a generating unit. Calculating efficiency requires
accurate measurement of suction pressure and temperature, discharge pressure and
temperature, and pump flow.
Calculate mixed high pressure, extraction steam supply enthalpy based on individual enthalpies
and relative weight of high pressure and extraction steam supplies
Where:
Calculate boiler feed pump turbine exhaust steam flow (wbfptexh) by adding steam seal supply
(wsealsply) to mixed steam supply (wbfptstm) and subtracting the seal (wseallkge)
Where:
Where:
Estimate total pump complex efficiency by dividing isentropic enthalpy rise by actual enthalpy rise
Calculate total pump complex input power by dividing pump complex output power (Phpbfpmp) by
pump complex efficiency
184 SP_0030
9.20 Bfpturb
Add the total pump input power difference computed from Deleval design data (Pbfptotdlt) to the
pump complex input power to calculate total power delivered to the pump by the turbine (driver
input power). This is the power generated by the turbine.
Calculate heat in boiler feed pump turbine exhaust (qbfptexh) by adding heat in steam seal supply
(qseallkge) to the heat in the steam (qbfptstm) and subtracting the heat in seal leakage
(qseallkge) and the heat generated by the turbine (qbfptgen = Pbfptgen converted to mbtu/h)
Calculate exhaust steam enthalpy (hbfptexh) by dividing net heat in turbine exhaust (qbfptstm) by
exhaust steam flow (wbfptexh)
Calculate mixed high pressure, extraction steam isentropic enthalpy based on individual
enthalpies and relative weight of high pressure and extraction steam supplies
Calculate boiler feedpump turbine efficiency and deviation by the enthalpy drop approach - divide
actual enthalpy drop by isentropic drop
SP_0030 185
9.21 Bldwn
9.21 Bldw n
The Bldwn algorithm calculates the blowdown flow and the blowdown enthalpy.
BLDWN
Analog Inputs
Analog Outputs
Constants
The blowdown inlet flow is adjusted for any flow going or being extracted from it, then its enthalpy
is calculated.
186 SP_0030
9.22 Blrio
9.22 Blrio
The Blrio algorithm calculates the boiler input/output efficiency and efficiency deviation from
design.
BLRIO
Analog Inputs
SP_0030 187
9.22 Blrio
BLRIO
Digital Inputs
188 SP_0030
9.22 Blrio
BLRIO
Constants
If the analog inputs for the second reheat section are not configured, the six outputs will be set to
zero and no additional heat will be added to qblrout.
The heat input to the boiler is the amount of heat supplied by fuel which is combusted. This is
the product of the fuel flow and the heating value.
Compute the total heat output from the boiler in mbtu/hr (qblrout).
The total heat output is defined as the heat absorbed by the working fluid. There are five
sources of working fluid which flow through the boiler:
wbldwn = 0.0;
SP_0030 189
9.22 Blrio
Next, calculate the superheat spray flow enthalpy if superheat spray flow is configured.
wdssht = 0.0;
Next, calculate the reheat spray flow enthalpy if the reheat spray flow is configured.
wdsrht = 0.0;
// If points unconfigured, set the absolute pressure, enthalpies and heats to zero.
pabsrhout2 = 0.0;
pabsrhin2 = 0.0;
hrhout2 = 0.0;
hrhin2 = 0.0;
qcrhte2 = 0.0;
qdsrht2 = 0.0;
else
190 SP_0030
9.22 Blrio
Compute actual boiler efficiency (eblreffio) as the ratio of the total heat output to heat input.
SP_0030 191
9.23 Boiler
9.23 Boiler
The boiler algorithm calculates the efficiency by the heat loss method.
BOILER
cahair2-6 avg spec ahtr 2-6 air [Optional] Use if there are 2-6 air heaters.
cahgas1 spec heat ahtr 1 out gas REQUIRED Output from airhtrs.
cahgas2-6 spec heat ahtr 2-6 out gas [Optional] Use if there are 2-6 air heaters.
Output from airhtrs.
Rahlkg2-6 ahtr 2-6 leakage [Optional] Use if there are 2-6 air heaters.
Output from airhtrs.
thtr_calc_airin2-6 Ahtr 2-6 air in temp [Optional] Use if limestone is present, and
there are 2-6 airhtrs.
thtrfairin1 air fan 1 air in temp REQUIRED
thtrfairin2-6 air fan 2-6 air in temp [Optional] Use if there are 2-6 air heaters.
thtrairout2 ahtr 2 air out temp [Optional] Use if there are two air heaters.
192 SP_0030
9.23 Boiler
BOILER
wfuel total coal (inc coke) flow REQUIRED Output from fuels.
pdrum drum pressure [Optional] Use if there is blowdown flow.
Wairth stoich wt air for compl comb REQUIRED Output from modahtemp
algorithm.
cahtairin1 spec heat ahtr 1 air in temp [Optional] Required if limestone is being
used. Output from airhtrs.
cahtairin2-6 spec heat ahtr 2-6 air in temp [Optional] Required if limestone is being
used and 2-6 air heaters. Output from
airhtrs.
Wdgful total fl gas fuel inc wt xair REQUIRED Output from airhtrs algorithm.
SP_0030 193
9.23 Boiler
BOILER
194 SP_0030
9.23 Boiler
BOILER
SP_0030 195
9.23 Boiler
BOILER
Calculate the heat generated by the boiler in mbtu/hr (qboilr) comprising the heat which goes to
the turbine (qtrbin) and that which is lost due to blowdown (qbldwn).
First, compute the blowdown enthalpy leaving the boiler drum in btu/lb (hbldwn) as a saturated
liquid steam table function of the absolute boiler drum pressure in psia (pdrumabs) if there is
blowdown flow (wbldwn)
The following are read from the design screen information: wblrmax - maximum boiler
continuous rating, kwtrcl - number of water cooled furnace walls and kaircl - number of air cooled
furnace walls. All these are included in the initialization section
wblrmax = MaxContBoilerRating(1);
kaircl = NumFurnaceWalls(AIR_COOLED);
kwtrcl = NumFurnaceWalls(H2O_COOLED);
else
hbldwn = 0.0
196 SP_0030
9.23 Boiler
Compute the following heat losses in percent to evaluate the boiler efficiency by the Heat Loss
Method as per ASME PTC 4.1.
Compute the heat loss due to dry gas in percent (hlsdrygas) as follows:
Calculate the enthalpy of vapor in btu/lb (hfgexh) at modified gas outlet temperature
(tahmodoutlet) and equivalent partial pressure of 1.0 psia as a superheated steam table function.
pbtemp = 1.0;
hsstp(&hfgexh, &thtrmodout, &pbtemp, &ITRNGE);
Compute the enthalpy of liquid in btu/lb (hfgho) at air heater air inlet temperature (tahain) as a
saturated liquid steam table function.
SP_0030 197
9.23 Boiler
Compute heat loss in moisture formed from hydrogen in percent (hlsmoisth2) and btu/lb.
Calculate the partial pressure of saturated vapor in psia (pabshtrain) at air heater air inlet
temperature (tahairinavg) as a saturated liquid steam table function.
Compute enthalpy of saturated vapor in btu/lb (hrvap) at partial pressure of vapor (pahainlet) as a
saturated vapor steam table function.
If limestone is not used, calculate the heat loss due to unburned combustibles only.
else
qlsgnsucalcin = 0.0;
Rlscalcin = 0.0;
hlscalcin = 0.0;
hlf = 0.0;
Rgnsulf = 0.0;
hlsunburn = Runbcarb * HCARB * .01;
Rlsunburn = 100.0 * hlsunburn / heatvalue;
Set the unmeasured heat losses (Rlsunmeas) to the operator entered constant in percent
(Rlsoperunm) and calculate the unmeasured heat loss in btu/lb (hlssun).
198 SP_0030
9.23 Boiler
Rlsunmeas = Rlsoperunm;
If the radiation loss is configured, use this value. Otherwise, calculate boiler radiation losses
based on the ABMA Reduction Loss.
Chart, Figure 8 of PTC 4.1 (hlsrad) in btu/lb and percent (Rlsrad) as follows.
qstcon = qboilr;
qlogqstcon = log10(qstcon);
else
qlogwratio = 0.0;
ktemp = 1.15614 - 0.9412342 * qlogqstcon + 0.1501196 * pow(qlogqstcon,2) - 0.007166278
* pow(qlogqstcon,3);
kradtemp = ktemp + 0.9422 * qlogwratio - (0.03409 * kwtrcl + 0.0273 * kaircl);
Rlsrad = 100.0 * pow(10.0, (kradtemp - 2));
hlsrad = (Rlsrad * heatvalue) / 100.0;
Compute total fuel related losses and gains in percent and btu/lb.
Calculate efficiency deviation from actual (eblreffdev). Design boiler efficiency is input and
calculated by some sort of approximation.
Compute the actual excess air percent (Rexair) as the ratio of actual weight of excess air (Wairex)
to the theoretical weight of excess air necessary for complete combustion (Wairth).
Compute the air heater air inlet temperature deviation from actual
(thtraindev).
thtraindev = thtrairinavg - thtradesin;
Calculate the corrected exit gas temperature with leakage based on design air inlet temperature
(tahgocairin).
SP_0030 199
9.23 Boiler
else
thtrgocairin = 0.0;
Calculate the corrected exit gas temperature with leakage based on design gas inlet temperature
(tahgocgasin).
else
thtrgocgasin = 0.0;
Calculate the total corrected exit gas temperature as specified in ASME PTC 4.3, Section 7.12.
Calculate the weighted averages of specific heat of air, specific heat of gas and air heater
leakage.
Correct the modified air heater exit gas temperature (corrected for no leakage) is corrected for the
deviation from the design entering air temperature by the procedure defined in ASME PTC 4.3
Paragraph 7.08.
else
{
thtrmoc = 0.0;
}
200 SP_0030
9.24 BOILERASME4
9.24 BOILERASME4
The BoilerASME4 algorithm calculates the efficiency by the heat loss method according to ASME
specifications.
BOILERASME4
SP_0030 201
9.24 BOILERASME4
BOILERASME4
202 SP_0030
9.24 BOILERASME4
BOILERASME4
SP_0030 203
9.24 BOILERASME4
BOILERASME4
204 SP_0030
9.24 BOILERASME4
BOILERASME4
Calculate the heat generated by the boiler in mbtu/hr (qboilr) comprising the heat which goes to
the turbine (qtrbin) and that which is lost due to blowdown (qbldwn).
First, compute the blowdown enthalpy leaving the boiler drum in btu/lb (hbldwn) as a saturated
liquid steam table function of the absolute boiler drum pressure in psia (pdrumabs) if there is
blowdown flow (wbldwn). `wbldwn' is an operator entered constant.
The following are read from the design screen information and all are included in the initialization
section:
wblrmax = MaxContBoilerRating(1);
kaircl = NumFurnaceWalls(AIR_COOLED);
kwtrcl = NumFurnaceWalls(H2O_COOLED);
SP_0030 205
9.24 BOILERASME4
else
hbldwn = 0.0;
Compute the following heat losses in percent to evaluate the boiler efficiency by the Energy
Balance Method as per ASME PTC 4
Compute the heat loss due to dry gas in percent (hlsdrygas) as follows:
Calculate the enthalpy of vapor in btu/lb (hfgexh) at modified gas outlet temperature
(tahmodoutlet) and equivalent partial pressure of 1.0 psia as a superheated steam table function.
pbtemp = 1.0;
hsstp(&hfgexh, &thtrmodout, &pbtemp, &ITRNGE);
206 SP_0030
9.24 BOILERASME4
Compute the enthalpy of liquid in btu/lb (hfgho) at air heater air inlet temperature (tahain) as a
saturated liquid steam table function.
Compute heat loss in moisture formed from hydrogen in percent (hlsmoisth2) and btu/lb.
Calculate the partial pressure of saturated vapor in psia (pabshtrain) at air heater air inlet
temperature (tahairinavg) as a saturated liquid steam table function.
Compute enthalpy of saturated vapor in btu/lb (hrvap) at partial pressure of vapor (pahainlet) as a
saturated vapor steam table function.
SP_0030 207
9.24 BOILERASME4
else
Rgnsulf = 0.0;
hgnsulf = 0.0;
qlscalcin = 0.0;
hcaco3 = 0.0;
hlimestone = 0.0;
qgnshtsorb = 0.0;
Set the unmeasured heat losses (Rlsunmeas) to the operator entered constant in percent
(Rlsoperunm) and calculate the unmeasured heat loss in btu/lb (hlssun).
If the radiation loss is configured, use this value. Otherwise, calculate boiler radiation losses
based on the ABMA Reduction Loss Chart, Figure 8 of PTC 4.1 (hlsrad) in btu/lb and percent
(Rlsrad) as follows.
qlogqstcon = log10(qboilr);
else
qlogwratio = 0.0;
ktemp = 1.15614 - 0.9412342 * qlogqstcon + 0.1501196 * pow(qlogqstcon,2) - 0.007166278 *
pow(qlogqstcon,3);
kradtemp = ktemp + 0.9422 * qlogwratio - (0.03409 * kwtrcl + 0.0273 * kaircl);
Rlsrad = 100.0 * pow(10.0, (kradtemp - 2));
hlsrad = (Rlsrad * heatvalue) / 100.0;
Compute the actual excess air percent (Rexair) as the ratio of actual weight of excess air (Wairex)
to the theoretical weight of excess air necessary for complete combustion (Wairth).
208 SP_0030
9.24 BOILERASME4
Compute total fuel related losses and gains in percent and btu/lb.
Calculate efficiency deviation from actual (eblreffdev). Design boiler efficiency is input and
calculated by some sort of approximation.
Compute the air heater air inlet temperature deviation from actual
(thtraindev).
thtraindev = thtrairinavg - thtradesin;
Calculate the corrected exit gas temperature with leakage based on design air inlet temperature
(tahgocairin).
else
thtrgocairin = 0.0;
Calculate the corrected exit gas temperature with leakage based on design gas inlet temperature
(tahgocgasin).
else
thtrgocgasin = 0.0;
SP_0030 209
9.24 BOILERASME4
Calculate the weighted averages of specific heat of air, specific heat of gas and air heater
leakage.
Correct the modified air heater exit gas temperature (corrected for no leakage) is corrected for the
deviation from the design entering air temperature by the procedure defined in ASME PTC 4.3
Paragraph 7.08.
else
thtrmoc = 0.0;
210 SP_0030
9.25 Capab
9.25 Capab
CAP AB
Analog Inputs
kcharexp cooling twr char Exponent REQUIRED Output from cooltwrdes algorithm.
Fcoolflow ratio des water flow/act flow REQUIRED Output from cooltwrpwr algorithm.
kcharconst cooling twr char constant REQUIRED Output from cooltwrdes algorithm.
tcthotin cooling twr hot wtr in temp REQUIRED
kslope slope of air enth line REQUIRED Output from cooltwr algorithm.
hsatairin enth of saturated inlet air REQUIRED Output from cooltwr algorithm.
hairdes des air enth REQUIRED Output from cooltwr algorithm.
Hcoolelv cooling twr Elevation REQUIRED Output from cooltwrdes algorithm.
Digital Inputs
Analog Outputs
SP_0030 211
9.25 Capab
CAP AB
Constants
Where:
212 SP_0030
9.26 Chkload
9.26 Chkload
The Chkload algorithm checks the load. If the load is above the critical load level, the run flag for
the GPA algorithms is set.
CHKLOAD
Analog Inputs
Analog Outputs
wwideopen valves wide open throttle flow [Optional] Used for unit heat rate control algorithm
unhrpcthr.
Rcload percent load [Optional] Used in ASME heat rate corr for main
steam temp
Digital Outputs
zdocalc dig pcalc local run flag REQUIRED Used in all calculations.
The Chkload algorithm checks the load and if the load is above the critical load level, the run flag
(zdocalc) for the gpa algorithm is set. This algorithm will always set the digital flag ztrue to a 1 to
allow the algorithms to be run if not using the load as the basis for running.
Chkload Outputs
SP_0030 213
9.26 Chkload
Load level is less than the critical load, set the performance calculation flag to false.
zdocalc = 0
zrunperfcalc = 0
else
Load level is above critical load level, set the performance calculation flag to true.
zdocalc = 1
zrunperfcalc = 1
Lastly, set the flag ztrue to 1 to allow a flag to be turned on to run the algorithms when the load is
not the specified criteria for running all algorithms.
ztrue = 1
214 SP_0030
9.27 Cndavgtemp
9.27 Cndavgtemp
The Cndavgtemp algorithm calculates the condenser average inlet and outlet temp as well as the
average circulating water temperature.
CNDAVGTEMP
Analog Inputs
tcwout2 circ water comp 2 out temp [Optional] Use if there are 2 compartments.
tcmpthresh comp temp threshold Output from [Optional] Use if in svc status for cmpts
cnddesign. determined by threshold.
Digital Inputs
zin_service_flag condenser in service flag [Optional] Use if Digital flags determine in svc
status. Output from cnddesign algorithm.
zcmpt1_flag cnd cmpt 1 flag [Optional] Use if Digitals determine in svc status
for compartments.
zcmpt2_flag cnd cmpt 2 flag [Optional] Use if Digitals determine in svc status
and there are 2 compartments.
Analog Outputs
Digital Outputs
SP_0030 215
9.27 Cndavgtemp
Average overall circulating water inlet (tcwin) and water outlet (tcwout) temperatures.
Where:
216 SP_0030
9.28 Cnddesign
9.28 Cnddesign
The Cnddesign algorithm reads in the condenser design data and assigns the values to outputs
as well as calculating the inner diameter for the different bundle types.
CNDDESIGN
Analog Inputs
Digital Inputs
Analog Outputs
Digital Outputs
SP_0030 217
9.28 Cnddesign
CNDDESIGN
218 SP_0030
9.28 Cnddesign
CNDDESIGN
SP_0030 219
9.28 Cnddesign
CNDDESIGN
220 SP_0030
9.28 Cnddesign
CNDDESIGN
This algorithm sets the outputs for the condenser algorithms from the information provided on the
design screen.
zin_service_flag = 1.
SP_0030 221
9.28 Cnddesign
If circulating water flow is measured, then the flag zcircwater_flag = 1. Otherwise, the circulating
water flow is not measured and the flag zcircwater_flag = 0. If circulating water flow is not
measured the following flags are set according to the check boxes on the screen. If the box is
checked, the flag will be set to a 1.
COMPONENT FLAG
The length, outer diameter, bwg, and material correction factors are output for the water and air
tubes as follows:
VARIABLE DESCRIPTION
222 SP_0030
9.28 Cnddesign
Finally, the four pressure flags are set to a 1 if the units are selected on the design screen as
follows:
UNITS VARIABLE
Mercury absolutezhga
Mercury gauge zhgv
PSIA or KPAA zabs
PSIG or KPAG zgauge
SP_0030 223
9.29 Co2econ
9.29 Co2econ
The Co2econ algorithm converts wet o2 at econ outlet to dry econ outlet.
CO2ECON
Analog Inputs
Analog Outputs
224 SP_0030
9.29 Co2econ
CO2ECON
Constants
SP_0030 225
9.29 Co2econ
Calculate moles of O2
kb25 = kb19;
kb26 = kd11;
kb27 = kd7;
kb28 = kd10;
226 SP_0030
9.29 Co2econ
Calculate sum of moles in CO2, H2O fuel, H2O combust, and SO2
Calculate excess O2
Rco2econ = Rc38;
SP_0030 227
9.30 Combturb
9.30 Combturb
The Combturb or the combustion turbine algorithm calculates corrected power and heat rates as
well as thermal efficiency, corrected thermal efficiency, and heat consumption.
COMBTURB
Analog Inputs
FPcorcmpinlt comp inlet temp pwr corr fact [Optional] Required if compressor inlet
temperature power corr factor is used.
FPcorcmpinlp comp inlet press pwr corr fact [Optional] Required if combustion turbine
inlet pressure loss power corr factor is used.
FPcorrelhum rel humidity pwr corr fact [Optional] Required if relative humidity
power correction factor is used.
228 SP_0030
9.30 Combturb
COMBTURB
SP_0030 229
9.30 Combturb
COMBTURB
hlhvfuel lower heating value of fuel [Optional] The lower or higher heating value
is required.
hhhvfuel higher heating value of fuel [Optional] The lower or higher heating value
is required.
winj injection flow [Optional] Use if injection flow is present.
pinj injection pressure [Optional] Use if there is fuel injection.
Frcorcmpinlp comp inlet pres htrt corr fact [Optional] Required if combustion turbine
inlet pressure loss heat rate corr factor is
used
Frcorexhpr exhaust press htrte corr fact [Optional] Required if comb turbineExhaust
pressure loss heat rate corr factor is used.
Frcorinjused inj heat rate correction fact [Optional] Required if injection loss heat rate
correction factor is used.
Frcoratmospr atmos press ht rate corr fact [Optional] Required if atmospheric pressure
rate correction factor is used.
Frcorrelhum rel humid heat rate corr fact [Optional] Required if relative humidity rate
correction factor is used.
Frcormisc misc heat rate corr factor [Optional] Required if miscellaneous heat
rate correction factor is used.
rhrctdes heat rate combust turb design [Optional]
230 SP_0030
9.30 Combturb
COMBTURB
Digital Inputs
zchiller_on chiller in service digital flg [Optional] Needed if using digital logic to
check chiller in-service.
Analog Outputs
SP_0030 231
9.30 Combturb
COMBTURB
Constants
PDELTACOMP,20.0 This constant is the delta between If the pressure difference is less than this
inlet and outlet compressor delta, compressor calculations will not be
pressures. done.
232 SP_0030
9.30 Combturb
Calculate evaporator/chiller efficiency if one exists and the evaporator cooler is turned on.
eevapact = 0.0;
eevapdev = 0.0;
Calculate the ideal gas constant which is computed as a polynomial function of compressor inlet
temperature.
SP_0030 233
9.30 Combturb
Correct ctg output to ISO or guarantee by dividing measured output by the product of the
correction factors used. The possible correction factors are inlet temperature, inlet pressure loss,
exhaust pressure loss, injection loss, atmospheric pressure and relative humidity.
Calculate percent base load as the ratio of corrected output to design load
Per ASME PTC 22, 1997 calculate adjustment in heat input to account for additional energy if the
measured gas temperature and pressure are not at the standard conditions, 60 deg.f and 14.696
psia. The additional energy is defined as sensible heat.
Calculate the sensible heat for natural gas at constant pressure by multiplying the mass flow rate
of the natural gas by the difference between the specific enthalpy of the fuel gas at the operating
conditions and the specific enthalpy of the fuel gas at the standard base condition of 60 deg f and
14.696 psia. For oil, see below.
Set up fuel array containing component mole fractions for gas enthalpy function
Calculate enthalpy of gas mixture at temperature (tnga) and pressure (pgas) using function
gas_enthalpy. mlrmass is the molecular weight of the mixture
hgasmix =
gas_enthalpy(Fngch4,Fngc2h6,Fngc3h8,Fngnbt,Fngisbt,Fngnpt,Fngispt,Fnghex,Fngco2,Fng
h2,Fngn2,Fngh2o,Fnghep,Fngco,Fngh2s,Fngo2,Mlrmass,gpaunits.
ConvertTemp(tngas,TO_DEGF),pabsngas,&kerrorcode);
Calculate enthalpy of mixture at standard temp (TSTP = 60 deg) and pressure (PSTP = 14.696
psia).
hstpngas = gas_enthalpy(Fngch4,Fngc2h6,Fngc3h8,Fngnbt,Fngisbt,Fngnpt,Fngispt,Fnghex,
Fngco2,Fngh2,Fngn2,Fngh2o,Fnghep,Fngco,Fngh2s,Fngo2,Mlrmass,TSTP,PSTP,&kerrorco
de);qngas_sensheat = (wmass_ngas * (hgasmix - hstpngas)) / RHTCNV;
pabsngas = 0.0;
hgasmix = 0.0;
hstpngas = 0.0;
qngas_sensheat = 0.0;
If oil is used, calculate the API degree of the oil (from page 506 in Elements of
Thermodynamics), the specific enthalpy of oil as a function of API and temperature (from Gould's
equation on page 1250 in The Science of Petroleum) and the sensible heat.
234 SP_0030
9.30 Combturb
kapi = 0.0;
hspecgrav = 0.0;
qoil_sensheat = 0.0;
Calculate total heat in the fuel by adding the sensible heat (qsensheat) to the heat input at
standard base conditions - the product of mass flow (wtotfuel) and the net heat at standard base
conditions.
else
Calculate total heat input to the combustion turbine (qctintot) as the sum of heat input in the fuel
and the heat input in the steam injection (power augmentation) if steam injection present.
calculate injection steam enthalpy (hinj), injection steam enthalpy at reference temperature & the
heat in the injection steam (qinj)
if (Injection is used)
Calculate heat in injection. per ASME PTC 4.4 the heat in the injection is calculated by multiplying
the injection flow (winj) by the enthalpy difference between the injection enthalpy (hinj) and the
enthalpy of the injection (hinjref) at the reference temperature. We are calculating the enthalpy of
saturated steam at the reference temperature.
if (Steam Injection)
else
pabsinj = 0.0;
hslt(&hinj, &tinj, &ITRNGE);
SP_0030 235
9.30 Combturb
pabsinjref = 0.0;
hslt(&hinjref,&tcompin,&ITRNGE);
qinj = winj * (hinj - hinjref) / RHTCNV;
else
Injection not present, set absolute pressure, injection enthalpy and injection enthalpy at reference
temperature and heat in injection to zero.
pabsinj = 0.0 ;
hinj = 0.0 ;
pabsinjref = 0.0 ;
hinjref = 0.0 ;
qinj = 0.0 ;
Calculate total heat to combustion turbine (qctintot) as the sum of heat input in the fuel (qfuelin)
and heat in steam injection (qstminj)
Calculate operating thermal efficiency as the ratio of the heat output in power (qctpwrout) to the
heat input (qctintot)
Calculate combustion turbine heat rate as ratio of heat input (qctintot) to measured power
(Pcombturb)
Correct ctg heat rate to ISO or guarantee by dividing measured output by the product of the
correction factors used. The possible correction factors are inlet temperature, inlet pressure loss,
exhaust pressure loss, injection loss, atmospheric pressure and relative humidity.
Calculate deviation between corrected heat rate (rhrctcorr) and design ct heat rate (rhrctdes)
236 SP_0030
9.30 Combturb
Calculate heat output in exhaust gases per ASME PTC 4.4 by subtracting heat output in power
(qctpwrout) and miscellaneous heat losses (estimated to be a percentage of the total heat in fuel)
from the total heat input (qctintot)
Check the point for miscellaneous losses first and if configured, use this value.
if (Not Configured)
else
kmischeatloss = kpcnthtloss;
qctexh = qctintot - qctpwrout - (kmischeatloss/100.0 * qfuelin);
Calculate estimated fuel to air ratio. Divide gas flow by estimated air flow (wctestair).
temp1 = 32.0;
temp2 = 0.0;
enthal(&hestgasref, UNITCODE, temp1, Ffueltoairest, temp2, Wvapcmpin, Wvap, Rcarb,
Rco2, Rhydr, Rco, Rnitr, Roxy, Rsulf, Rso2, Rncmbt, temp2, HCONV);
Calculate exhaust gas flow per ASME PTC 4.4 by dividing heat in the exhaust (qctexh) by the
difference between the estimated exhaust gas enthalpy at the ctg exhaust gas temp (hestgasout)
and the estimated exhaust gas enthalpy at the compressor inlet temperature (hestgasin).
Calculate compressor air flow (wair) by subtracting fuel flow (wfueltot) from the calculated exhaust
gas flow (wctexh)
Ffueltoairact = wtotfuel/wair;
SP_0030 237
9.30 Combturb
temp1 = 32.0;
temp2 = 0.0;
enthal(&hctdes, UNITCODE, temp1, Ffueltoairact, temp2, Wvapcmpin, Wvap, Rcarb, Rco2,
Rhydr, Rco, Rnitr, Roxy, Rsulf, Rso2, Rncmbt, temp2, HCONV);
238 SP_0030
9.31 Compair
9.31 Compair
The Compair algorithm calculates the compressor air flow based on design air flow, ambient
conditions, compressor inlet temperature, and design compressor inlet temperature.
COMPAIR
Analog Inputs
SP_0030 239
9.31 Compair
COMPAIR
Constants
RELHMD 60.0
KPATMOSISO 14.7
KO2AIR 0.2315
KN2AIR 0.7685
TREF 59
KSHOMATE_O2 11.2095
KSHOMATE_N2 12.8087
KSHOMATE_H2O 26.8097
Find air composition at ISO conditions and actual compressor inlet conditions
gaspropt_v(&viso,ko2air_iso,kn2air_iso,kh20air_iso,KPATMOSISO,tdescompin,
KPATMOSISO,TREF,KSHOMATE_O2,KSHOMATE_N2,KSHOMATE_H2O)
240 SP_0030
9.31 Compair
gaspropt_v(&vmbnt,ko2air_in,kn2air_in,kh2oair_in,patmos,tmbnt KPATMOSISO,TREF,
KSHOMATE_O2,KSHOMATE_N2,KSHOMATE_H2O,)
Calculate actual air flow based on estimated air flow and volume ratio of iso to ambient conditions
if (!zcoolersvc)
{
twetbulb = 0
Wvap_wb = 0
ko2air_out = ko2air_in
kn2air_out = kn2air_in
kh2oair_out = kh2oair_in
vcompin_wb = 0
evap_eff = 0
wairflow = wairflowcalc
}
else
Chiller in service. Calculate specific humidity and volume at comp inlet conditions
gaspropt_v(&vcompin_wb,ko2air_out,kn2air_out,kh2oair_out,pabscompin,tcompin,
KPATMOSISO,TREF,KSHOMATE_O2,KSHOMATE_N2,KSHOMATE_H2O)
Fvoln2air = (kn2air_out/28.01)/((ko2air_out/31.999)+(kn2air_out/28.01)+(kh2oair_out/18.02))
Fvolh2oair = (kh2oair_out/18.02)/((ko2air_out/31.999)+(kn2air_out/28.01)+(kh2oair_out/18.02))
SP_0030 241
9.32 CompWash
9.32 CompWash
The Compressor Wash module calculates the optimal time to perform a compressor wash based
on economic factors. The Compressor Wash module requires an additional license to become
active. This module will be loaded with the PCALCS software if a compressor wash license exists.
The PCALCS software works with the GPA software. Refer to the GPADCS User Guide for
licensing information.
Note: For Analog Inputs with the klast_month should be entered in the format MM, the
klast_day in the format DD, and the year in the format YYYY.
COMP WAS H
Analog Inputs
242 SP_0030
9.32 CompWash
COMP WAS H
SP_0030 243
9.32 CompWash
COMP WAS H
244 SP_0030
9.32 CompWash
COMP WAS H
Constants
KCONSTR 8.3143
KCRITERIA 0.1
KMAXLOOP 50
KCPN2[5] 26.092, 8.218801,-1.976141,0.159274,0.044434
KCPO2[5] 29.659, 6.137261,-1.186521,0.09578,-0.219663
KCPH2O[5] 30.092,6.832514,6.793435,-2.53448,0.082139
KPATMOSISO 14.696
TREF 59
KSHOMATE_O2 11.2095
KSHOMATE_N2 12.8087
KSHOMATE_H2O 26.8097
SP_0030 245
9.32 CompWash
The Compressor Wash algorithm determines the optimal time to wash the compressor. The
Compressor Wash algorithm determines the optimal time to wash the compressor based on
economic factors. Compressor Wash determines the loss in generation associated with fouling,
determines the forward cost in decreased efficiency due to fouling, and weighs those costs
against the cost of cleaning.
This algorithm quantifies current operating loss associated with fouling and generates the
projected recoverable revenues, the cost to clean, and the difference over a user-selectable time
period.
Benefits are:
Quantifies current generating losses due to fouling.
Performs a cost-benefit projection to determine the optimum time to clean.
Provides indication of effectiveness of cleaning to optimize cleaning technique.
Allows fleet energy managers to better prioritize cleaning.
Permits energy trader to better estimate the theoretical generating capacity of the fleet.
Compressor Wash Operation
When the compressor has been washed, your must enter the Year, Month, and Day the wash
was performed since the algorithm uses the previous year’s load profile to predict when the next
wash should take place. The load profile is updated automatically from historical data.
1. Date of compressor wash – when the compressor has been washed, you must enter the day,
month, and year the wash was performed.
Note: This algorithm is only valid if the compressor is washed at least once per year.
2. Compressor Inlet Air Flow – if this signal is not measured then an estimated air flow is used.
3. Barometric Pressure.
4. Compressor Inlet Temperature.
5. Relative Humidity.
6. Compressor Outlet Temperature.
7. Compressor Inlet Pressure.
8. Compressor Outlet Pressure.
9. Value of Cleaning Agents – you must enter the cost of the cleaning agents.
10. Cost of Cleaning Agent Disposal – you must enter the cost of disposing of the cleaning
agents once the wash is completed.
11. Direct Labor Costs – you must enter the cost for the people performing the wash.
12. Time at Reduced Load – you must enter the time it takes to do the wash.
13. Reduced Load During Wash – you must enter the percent load the machine is at during the
wash. If it is an offline wash, this value will be zero.
246 SP_0030
9.32 CompWash
14. Replacement Power Cost Multiplier – this is an operator entered value. If replacement power
during a wash outage is required to fulfill a purchase agreement contract then this value is
multiplied times the agreement sale price of power to calculate the approximate replacement
power fee. If this does not apply, this will have a value of 1.0.
15. Fuel Cost – You must enter the cost of fuel.
16. Lower Heating Value of Fuel – the operator enters the lower heating value of fuel.
17. Recoverable Efficiency After Cleaning – this is an operator entered value. It is the percent of
original/clean compressor efficiency which can be restored with maintenance.
18. Design Compressor Inlet Temperature – this value is only entered once. It is the compressor
inlet temperature found on the design curves of the CTG. Typically 15 Deg C or 59 Deg F.
1. Compressor Inlet Temp vs Compressor Polytropic Efficiency. Once the compressor has been
cleaned, the efficiency of the compressor is stored along with the compressor inlet
temperature. Six samples of efficiencies after cleaning at different compressor inlet
temperatures is constantly updated in history and is used by the compressor wash every time
it executes.
2. A yearly load profile is used by the compressor wash module. For each month of the year the
module uses:
Percent time that the machine was running in the month.
Average compressor inlet temp.
Average MW load.
Average sale price of power.
Initially, this data is manually entered with default values, then, once the module starts, this data
is updated automatically. When the month changes, the previous monthly values are updated
based on actual historical data. This profile is read by the module every time it runs.
The following data is entered through a design screen one time when the algorithm is configured
inside the GPA:
1. Design Load vs Heat Rate curve. This is obtained from the manufacturer data.
2. Maximum Power Correction Factor vs Compressor Inlet Temperature – this is obtained from
the turbine manufacturer.
3. Heat Rate Correction Factor vs Compressor Inlet Temperature – this is obtained from the
turbine manufacturer.
4. CTG base load at ISO conditions.
Outputs
The following values are calculated every time the compressor wash algorithm executes:
1. Date to clean.
2. Current shaft thermal work.
3. Current shaft electrical work.
4. Current compressor polytropic efficiency.
5. The cost-benefit from the last cleaning for each month of the year. The month that has the
first positive cost is when the compressor should be washed.
SP_0030 247
9.32 CompWash
Note: The best achievable values are based on current air flow and ambient conditions and best
compressor efficiency. It shows what the shaft work and exhaust temperature would be at
current conditions if the compressor efficiency was at its best achievable value.
Error Flag
The following error condition is checked and a digital flag is set TRUE if the error was detected.
zwashdate – this flag is set true if an invalid compressor wash date is entered or if the wash date
is more than one year from the last wash date.
Get current time and date and return difference in days between the two times
current_time(&kdaysum,&kcur_year,&kcur_day,&kcur_month,klast_year,
klast_day,klast_month)
zwashdate = 1
epolybest = funcgen(tcompin,tcompinarc1,…,tcompinarc6,ecompeffarc1,…,ecompeffarc6)
248 SP_0030
9.32 CompWash
tnew = tcompin + 10
else
tnew = tcompin – 10
temp = 298/1000.0
temp2 = tcompin/1000
if (temp2 >0.298)
tmult_in = temp2
else
tmult_in = temp
zqualsearch = 1
SP_0030 249
9.32 CompWash
else
zqualsearch = 0
tcompoutbest = tnew
vol_o2 = (Fvolo2air / Fvoltot) * (KPATMOSISO/pabscompout) * KSHOMATE_O2 *
(tcompoutbest/32.0)
vol_n2 = (Fvoln2air / Fvoltot) *(KPATMOSISO/pabscompout)*KSHOMATE_N2*
(tcompoutbest/32.0)
vol_h2o = (Fvolh2oair/Fvoltot)*(KPATMOSISO/pabscompout)*KSHOMATE_H2O*
(tcompoutbest/32.0)
vcompout = vol_o2 + vol_n2 + vol_h2o
Calculate reversible work (Btu/Lb) for steady flow system (see Obert & Young eqn. 11-7a) - i.e.,
ignoring delta-Kinetic Energy
Calculate real gas enthalpy rise (Btu/Lb) across compressor and best achievable shaft work
else
250 SP_0030
9.32 CompWash
Calculate reversible work (Btu/Lb) for steady flow system (see Obert & Young eqn. 11-7a) - i.e.,
ignoring delta-Kinetic Energy
Calculate real gas enthalpy rise (Btu/Lb) across compressor and current shaft work
else
SP_0030 251
9.32 CompWash
Rpmult_act = funcgen(tmbnt,tcorcompin1,…,tcorcompin6,Fpwrcor1,…,Fpwrcor6)
if (Rpmult_act > 0)
else
Plosscor = Ploss
rhrdes_base = funcgen(Pctgbase,Pdesload1,…,Pdesload6,rctgref1,…,rctgref6)
Fcapfact[1] = FcapfactJan
Fcapfact[2] = FcapfactFeb
Fcapfact[3] = FcapfactMar
Fcapfact[4] = FcapfactApr
Fcapfact[5] = FcapfactMay
Fcapfact[6] = FcapfactJun
Fcapfact[7] = FcapfactJul
Fcapfact[8] = FcapfactAug
Fcapfact[9] = FcapfactSep
Fcapfact[10] = FcapfactOct
Fcapfact[11] = FcapfactNov
Fcapfact[12] = FcapfactDec
Paveload[1] = PaveloadJan
Paveload[2] = PaveloadFeb
Paveload[3] = PaveloadMar
Paveload[4] = PaveloadApr
Paveload[5] = PaveloadMay
Paveload[6] = PaveloadJun
Paveload[7] = PaveloadJul
Paveload[8] = PaveloadAug
Paveload[9] = PaveloadSep
Paveload[10] = PaveloadOct
252 SP_0030
9.32 CompWash
Paveload[11] = PaveloadNov
Paveload[12] = PaveloadDec
DPpwrcost[1] = DPpwrcostJan
DPpwrcost[2] = DPpwrcostFeb
DPpwrcost[3] = DPpwrcostMar
DPpwrcost[4] = DPpwrcostApr
DPpwrcost[5] = DPpwrcostMay
DPpwrcost[6] = DPpwrcostJun
DPpwrcost[7] = DPpwrcostJul
DPpwrcost[8] = DPpwrcostAug
DPpwrcost[9] = DPpwrcostSep
DPpwrcost[10] = DPpwrcostOct
DPpwrcost[11] = DPpwrcostNov
DPpwrcost[12] = DPpwrcostDec
tcompin[1] = tcompinJan
tcompin[2] = tcompinFeb
tcompin[3] = tcompinMar
tcompin[4] = tcompinApr
tcompin[5] = tcompinMay
tcompin[6] = tcompinJun
tcompin[7] = tcompinJul
tcompin[8] = tcompinAug
tcompin[9] = tcompinSep
tcompin[10] = tcompinOct
tcompin[11] = tcompinNov
tcompin[12] = tcompinDec
ksave_month = kstart_month
ksave_year = klast_year
if (kcur_year == klast_year)
else
SP_0030 253
9.32 CompWash
kmonth_seq[i] = klast_month
if (i == 1)
else
knum_days_month[int(klast_month)] = knum_days
kdaytot = kdaytot + knum_days_month[int(klast_month)]
index = int(klast_month)
kmonthly_data[1][i] = Fcapfact[index]
kmonthly_data[2][i] = Paveload[index]
kmonthly_data[3][i] = DPpwrcost[index]
kmonthly_data[4][i] = tcompin[index]
kmonthly_data[5][i] = knum_days_month[index]
if (i < int(kstart_month))
else
kmonthly_data[6][i] = Plosscor
klast_month = klast_month + 1.0
klast_month = 1.0
klast_year = klast_year + 1.0
DDcost_tot = 0.0
DDben_tot = 0.0
for (i = 1; i<13; i++)
Calculate heat rate and power correction factors based on average monthly compressor inlet
temp
tcomp_avg = kmonthly_data[4][i]
Fhrmult=funcgen(tcomp_avg,tcorcompin1,tcorcompin2,tcorcompin3,tcorcompin4,tcorcompin5
,tcorcompin6,Fhrcor1,Fhrcor2,Fhrcor3,Fhrcor4,Fhrcor5,Fhrcor6,6)
Fpwrmult=funcgen(tcomp_avg,tcorcompin1,tcorcompin2,tcorcompin3,tcorcompin4,tcorcompi
n5,tcorcompin6,Fpwrcor1,Fpwrcor2,Fpwrcor3,Fpwrcor4,Fpwrcor5,Fpwrcor6,6);
Ploss_mo = kmonthly_data[6][i] * Fpwrmult
rrtdes_mo = rhrdes_base * Fhrmult
254 SP_0030
9.32 CompWash
kclean_index = 1
for (i = 1 ; i < 13; i++)
{
kclean_index = int(kmonth_seq[i])
break
}
double DDsolution[13]
for (i = 1 ; i < 13; i++)
{
DDsolution[int(kmonth_seq[i])] = DDsolcost[i];
}
DDsolcost1 = DDsolution[1];
DDsolcost2 = DDsolution[2];
DDsolcost3 = DDsolution[3];
DDsolcost4 = DDsolution[4];
DDsolcost5 = DDsolution[5];
DDsolcost6 = DDsolution[6];
DDsolcost7 = DDsolution[7];
DDsolcost8 = DDsolution[8];
DDsolcost9 = DDsolution[9];
DDsolcost10 = DDsolution[10];
DDsolcost11 = DDsolution[11];
DDsolcost12 = DDsolution[12];
kclean_month = double(kclean_index);
SP_0030 255
9.32 CompWash
kclean_year = ksave_year + 1
else
kclean_year = ksave_year
kclean_day = klast_day;
256 SP_0030
9.33 Compr
9.33 Compr
This module calculates adiabatic, polytropic, and isothermal efficiencies. If flow is not measured, it
is estimated from power and the stagnation outputs will be set to zero. If power is not measured, it
is estimated from the measured flow and the stagnation.
COMPR
Analog Inputs
SP_0030 257
9.33 Compr
COMPR
258 SP_0030
9.33 Compr
COMPR
SP_0030 259
9.33 Compr
COMPR
Digital Outputs
< NONE >
Constants
KFTLBtoBTU,778.0
KRCONST,10.73159
KVELCONST,400.0
KRECOVERY,0.65
KTEMP_STP,59.0
KPRES_STP,0.0
DEGCtoDEGK,273.15
KCPRATIOCONST,0.185103
260 SP_0030
9.33 Compr
Calculate mass gas flow from vol gas flow as well as volumetric inlet and outlet flows
if (IsFlowMeas())
wmassflow = wgasvolflow * densnorm * MIN_TO_HOUR / KLBtoLB;
wgasinflow = wgasvolflow * (densnorm / densinlet);
wgasoutflow = wgasvolflow * (densnorm / densoutlet);
Calculate inlet and outlet velocities as the volumetric flows divided by areas
If velocity is above KVELCONST ft/sec, calculate velocity pressure. Otherwise, set to zero.
Calculate stagnation pressure as the inlet and outlet pressures plus the inlet and outlet velocity
pressures.
If the velocity is above KVELCONST ft/sec, calculate the inlet velocity temperature. Otherwise,
set to zero.
Calculate stagnation temperatures as the inlet and outlet temperatures plus 1 - R times the inlet
and outlet velocity temperatures. R is the recovery factor, where R = .65 for plain sheathed
thermocouples and will vary for other thermocouples.
else
wmassflow = 0.0;
SP_0030 261
9.33 Compr
wgasinflow = 0.0;
wgasoutflow = 0.0;
Vgasin = 0.0;
Vgasout = 0.0;
pinvel = 0.0;
poutvel = 0.0;
tinvel = 0.0;
toutvel =0.0;
Calculate the pressure ratio as the stagnation outlet pressure divided by the stagnation inlet
pressure
Calculate the temperature ratio as the stagnation outlet temperature divided by the stagnation
inlet temperature
Calculate the temperature rise as the stagnation outlet temperature minus the stagnation inlet
temperature
262 SP_0030
9.33 Compr
emecheff = CompressorMeas(MECH_EFF);
SP_0030 263
9.33 Compr
If total power is measured, calculated gas power as total power times mechanical efficiency.
Otherwise, calculate gas horsepower from measured mass flow.
if (IsPwrMeas())
Pgaspwr = Ptotalpwr_meas * (emecheff/100);
Ptotalpwr = Ptotalpwr_meas;
else
Pgaspwr = ((wmassflow * KLBtoLB * (1/MIN_TO_HOUR) * Hpolyhead) /
(epolyeff/HCONV)) * FTLB_MINtoHP * HPtoMW;
If flow is not measured, (power must be measured in this case), calculate flow from measured
power and calculate inlet and outlet gas flows as well as inlet and outlet velocities
if (! IsFlowMeas())
wmassflow = ((Pgaspwr / (HPtoMW *FTLB_MINtoHP)) / Hpolyhead) * (1/KLBtoLB) *
MIN_TO_HOUR * (epolyeff/HCONV);
Calculate inlet and outlet velocities as the volumetric flows divided by areas
264 SP_0030
9.33 Compr
nrefspeed = CompressorMeas(REF_SPEED);
kspeedratio = nrefspeed / nactspeed;
Calculate corrected reference flow, correctred reference head, corrected reference Power.
SP_0030 265
9.33 Compr
266 SP_0030
9.33 Compr
SP_0030 267
9.34 Condsr
9.34 Condsr
The Condsr algorithm determines the method for out-of-service compartments. After checking for
out-of-service compartments, the specific heat, specific volume and specific gravity of circulating
water are calculated.
Next, the condenser duty, the condenser circulating water flow, the actual and design heat
transfer, the cleanliness factor, expected back pressure with clean tubes and the back pressure
deviation are calculated.
Calculations are done in accordance with ASME Power Test Code PTC 12.2 (1983) and Heat
Exchange Institute Standards for Steam Surface Condensers, Ninth edition.
CONDSR
Analog Inputs
268 SP_0030
9.34 Condsr
CONDSR
SP_0030 269
9.34 Condsr
CONDSR
270 SP_0030
9.34 Condsr
CONDSR
SP_0030 271
9.34 Condsr
CONDSR
272 SP_0030
9.34 Condsr
CONDSR
SP_0030 273
9.34 Condsr
CONDSR
Steam surface condensers are an important component in every steam turbogenerator unit
operating in the electric utility industry. They have three main purposes:
1. To maximize the electric power conversion of the energy of the steam supplied to the turbine
throttle.
2. To recover vapor exhausted from the low-pressure stage of the turbine in the form of
condensate. This can then be recycled directly to the boiler.
3. To recover the heat in the condensate and so reduce the amount of heat required of the boiler
to raise the steam to the desired throttle temperature and pressure conditions.
Start Calculations
The CNDDESIGN and CNDAVGTEMP algorithms must be called before invoking this algorithm.
Calculate specific gravity of circulating water (Scwspecgrav) by dividing the actual density of the
circulating water by the density of water at 60.0 Deg f. DWATER is 62.3 lb/ft3. Scwspecgrav =
1.0 / (vcwin * DWATER)
Where:
Calculate the condenser terminal temperature difference (tcndttd) as the difference between the
condenser saturation temperature (tcndvac) and the circulating water outlet temperature (tcwout).
Calculate the initial temperature difference by subtracting the inlet temperature from the saturation
temperature.
274 SP_0030
9.34 Condsr
Calculate the subcooling by subtracting the hotwell temperature from the saturation temperature.
If circulating water flow is measured then condenser duty (qcndty) is calculated as follows:
Where:
If circulating water flow is not measured, condenser duty is computed by doing a heat balance
around the condenser. The heat balance is comprised of the following elements:
Calculate total circulating water flow in klb/hr (wcwflw) from condenser duty.
Compute average circulating water tube velocity in ft/sec (Vcwvel).The following definitions are
used in the equation below:
Calculated by 3.14 * id2 / 4, where id = outer diameter (taken from design screen) - thickness
(calculated from material typ and BWG)
SP_0030 275
9.34 Condsr
Where:
Where:
Calculate actual heat transfer in btu/ft2 hr deg f (Ucndactht) from the definition in the ASME 12.2
condenser performance manual.
276 SP_0030
9.34 Condsr
Calculate the cleanliness factor (Ccndcln) as the ratio of actual to clean thermal transmittance.
Calculate expected saturation temperature (tcndcln) from the log mean temperature difference
based on clean tubes.
Expected back pressure (pabscndcln) is calculated as steam table function of the expected
saturation temperature (tcndcln)
SP_0030 277
9.35 Coolcurv
9.35 Coolcurv
The Coolcurv algorithm computes predicted outlet flow, adjusted test flow and percent capability.
COOLCURV
Analog Inputs
Analog Outputs
278 SP_0030
9.35 Coolcurv
COOLCURV
Constants
If the total power is not configured, put the design power in for the total power.
Compute approach
SP_0030 279
9.35 Coolcurv
Calculate slope of air/enthaply line (l/g ratio) per procedure defined in 1990 CTI code for induced
draft cooling towers.
Estimate design air enthalpy from design wet bulb temperature and elevation
hairdes = satenth(twetbulbindes,Hcoolelv);
Calculate design air density and volume at design wet bulb temperature
hsatairin = satenth(gpaunits.ConvertTemp(twetbulb,TO_DEGF),Hcoolelv);
kiters = 0.0;
klg = kdeslg;
Fibonacci search
tcwhot = tcthotin;
tcwcold = tctcoldout;
thigh = tcwhot + 10.0;
tlow = gpaunits.ConvertTemp(twetbulb,TO_DEGF);
talnth = thigh - tlow;
ttest = thigh;
tsq = 1.618033989;
herror = 1000.0;
kloop = 1 ;
kloop = kloop + 1 ;
kdist = talnth/pow(tsq,(kloop-1)) ;
280 SP_0030
9.35 Coolcurv
else
ttest = tlow;
ttest = thigh;
hsatest = satenth(ttest,Hcoolelv);
/****************************************************
****************************************************/
kiterflag = 0.0;
kiters = kloop;
kiterflag = 1.0;
SP_0030 281
9.35 Coolcurv
else
wvpredflow = wvflowlow;
282 SP_0030
9.36 Cooltwr
9.36 Cooltw r
The Cooltwr algorithm computes the estimated cooling tower outlet temperature.
COOLTWR
Analog Inputs
twetbulbindes wet bulb des in temp REQUIRED Output from cooltwrdes algorithm
Pcttotal cooling twr total actual power REQUIRED Output from cooltwrpwr algorithm
Hcoolelv cooling twr Elevation REQUIRED Output from cooltwrdes algorithm
Digital Inputs
zcooltwron [Optional]
Analog Outputs
SP_0030 283
9.36 Cooltwr
COOLTWR
Constants
284 SP_0030
9.36 Cooltwr
The purpose of the cooling tower is to cool the water that enters the condenser. The water is
cooled by a combination of heat and mass transfer. Water entering the tower is sprayed or
splashed over fill, which breaks up the water and exposes a large surface area of the water to the
air.
Typically, air flows upward through the tower opposite of the water flow direction, either due to
convection or to cooling tower fans. Some of the water is evaporated into the air, with the
necessary latent heat being transferred from the remaining water. This process lowers the
remaining water temperature.
SP_0030 285
9.37 Cooltwrdes
COOLTWRDES
Analog Inputs
Digital Inputs
Analog Outputs
Constants
286 SP_0030
9.37 Cooltwrdes
The design hot and cold water temperatures are assigned to tctindes and tctoutdes.
The flag zdocool is set to a 1 if the digital flag is selected for in-service status. If the minimum HP
in-service status is selected, zdocool is set to zero and Pfanmin is assigned the minimum
in-service HP.
SP_0030 287
9.38 Cooltwrpwr
The Cooltwrpwr algorithm calculates individual cell power, design water flow, the ratio of design
water flow to actual flow, total fan power and ratio of design power to actual power.
COOLTWRPWR
Analog Inputs
Ictvolt1 - through cell 1 voltage - through [Optional] Use if power measurement is not
available.
Ictvolt20 cell 20 voltage
ictamp1 - through cell 1 current - through [Optional] Use if power measurement is not
available.
ictamp20 cell 20 current
Fctpf1 - through cell 1 power factor - through [Optional] Use if power measurement is not
available.
Fctpf20 cell 20 power factor
Fmtreff cooling tower motor efficiency [Optional] Use if power measurement is not
available.
Pctfan1 - through fan 1 power - through [Optional] Use if power measurement is
available.
Pctfan20 fan 20 power
Pfanmin minimum power per cell [Optional] Use if power measurement is
available. Output from cooltwrdes algorithm.
wvdesflow des cooling twr volum flow REQUIRED Output from cooltwrdes algorithm.
Pfandes cooling tower design power REQUIRED Output from cooltwrdes algorithm.
Digital Inputs
Fcoolflow ratio des water flow/act flow [Optional] Used in cooltwr algorithm as input
288 SP_0030
9.38 Cooltwrpwr
COOLTWRPWR
zinsvccell1 - [Optional]
through
zinsvccell20
Constants
The design water flow is calculated based on the number of fans that are running as follows:
wvcooldeswtr = wvdesflow
Where:
Fan horsepower
The total power being consumed is the sum of the power consumed by the fans
Frctpower = Pctdes/Pcttotal
SP_0030 289
9.39 Corblrloss
9.39 Corblrloss
The Corblrloss algorithm calculates the corrected boiler efficiency and the design efficiency and
deviation.
CORBLRLOSS
Analog Inputs
thtrmoc corr non lkg exit gas temp REQUIRED Output from boiler algorithm.
Analog Outputs
hfgexc vap enth cor non-lkg exit temp [Optional] Used for exit gas temp and O2
controllable loss algorithm.
290 SP_0030
9.39 Corblrloss
CORBLRLOSS
hfghoc enth des ahtr air inlet temp [Optional] Used for exit gas temp controllable
losses algorithm.
hflmsc corr ht loss moist in fuel [Optional]
Rflmsc pcnt cor ht loss moist in fuel [Optional] Used for exit gas temp controllable
losses algorithm.
Rcmbhc pcnt corr ht loss moist fr h2 [Optional] Used for exit gas temp controllable
losses algorithm.
hrvapc sat vap enth sat vapor pres [Optional] Used in O2 controllable losses
algorithm.
Rwvaic pcnt cor ht loss moist air sup [Optional] Used in exit gas temp and O2
controllable losses algorithms.
Digital Outputs
< NONE >
Constants
CGAS[0] = 0.237058
CGAS[1] = 1.65875e-05
CGAS[2] = 4.18508e-08
CGAS[3] = -2.20475e-11
CAIR[3], 0.23897,6.7857e-06,1.9643e-08
HREFWATER, 45.0
SP_0030 291
9.39 Corblrloss
Recompute boiler efficiency using the corrected non-leakage exit gas temperature (tahmoc) and
the design air heater air inlet temperature (tahadesin). The following heat losses are
recalculated.
Compute the specific heat of flue gas exiting the boiler in btu/lb deg.f (cpflgc).
Calculate the corrected heat loss due to dry gas in percent (hdglsc) as follows:
Compute the enthalpy of vapor in btu/lb (hfgexc) at corrected non-leakage exit gas temperature
and equivalent partial pressure of 1.0 psia as a superheated steam table function.
ptemp = 1.0;
hsstp(&hfgexc, &thtrmoc, &ptemp, &ITRNGE);
Calculate the enthalpy of liquid in btu/lb (hfghoc) at design air heater air inlet temperature
(tahadesin) as a saturated liquid steam table function.
Compute the corrected heat loss due to moisture in fuel in percent (hflmsc).
Calculate the corrected heat loss in moisture formed from hydrogen in percent (hcmbhc).
Compute the partial pressure of saturated vapor in psia (pahaic) as a saturated vapor steam table
function of the design air heater air inlet temperature (tahdin).
Calculate the saturated vapor enthalpy in btu/lb (hrvapc) as a saturated vapor steam table
function of the partial pressure of vapor (pahaic).
292 SP_0030
9.39 Corblrloss
Compute the corrected heat loss in moisture in air supplied in percent (hwvaic).
Calculate total corrected fuel related losses in btu/lb (hsmlsc) and percent (Rhsmlsc).
Calculate the corrected boiler efficiency deviation (eblreffcdev) as the difference between the
corrected boiler efficiency and the design efficiency.
SP_0030 293
9.40 CorblrlASME4
The CorblrlASME4 algorithm calculates the corrected boiler efficiency and deviation according to
ASME specifications.
C O R B L R L AS M E 4
Analog Inputs
thtrmoc corr non lkg exit gas temp REQUIRED Output from boiler algorithm.
Analog Outputs
294 SP_0030
9.40 CorblrlASME4
C O R B L R L AS M E 4
Constants
CAIR[3] ,0.23897,6.7857e-06,1.9643e-08
CGAS[4] 0.237058,1.65875e-05,4.18508e-08,
-2.20475e-11
Recompute boiler efficiency using the corrected non-leakage exit gas temperature (tahmoc) and
the design air heater air inlet temperature (tahadesin). The following heat losses are recalculated:
SP_0030 295
9.40 CorblrlASME4
Compute the specific heat of flue gas exiting the boiler in btu/lb deg.f.
Calculate the corrected heat loss due to dry gas in percent (hdglsc) as follows:
Compute the enthalpy of vapor in btu/lb (hfgexc) at corrected non-leakage exit gas temperature
and equivalent partial pressure of 1.0 psia as a superheated steam table function.
ptemp = 1.0;
hsstp(&hfgexc, &thtrmoc, &ptemp, &ITRNGE);
Calculate the enthalpy of liquid in btu/lb (hfghoc) at design air heater air inlet temperature
(tahadesin) as a saturated liquid steam table function.
Compute the corrected heat loss due to moisture in fuel in percent (hflmsc).
Calculate the corrected heat loss in moisture formed from hydrogen in percent (hcmbhc).
Calculate the saturated vapor enthalpy in btu/lb (hrvapc) as a saturated vapor steam table
function of the partial pressure of vapor (pahaic).
Compute the corrected heat loss in moisture in air supplied in percent (hwvaic).
296 SP_0030
9.40 CorblrlASME4
Calculate the corrected boiler efficiency deviation (eblreffcdev) as the difference between the
corrected boiler efficiency and the design efficiency.
SP_0030 297
9.41 Cosin
9.41 Cosin
COSIN
Analog Inputs
Analog Outputs
Digital Outputs
Constants
kcgain = 1 kcbias = 0
The output of this calculation (kcosin_res) is the cosine of the input (kvalue) multiplied by the gain
(kgain) and the addition of the bias (kbias).
kcosin_res = cos(kvalue);
kgain = kptgain + kcgain;
kbias = kptbias + kcbias;
kcosin_res = (kcosin_res * kgain) + kbias;
298 SP_0030
9.42 Crossprod
9.42 Crossprod
The Crossprod algorithm calculates the cross product based on x and y inputs.
The result can be modified by multiplying by a gain and/or adding a bias. Note that the gain and
bias numbers can be points, constants or both points and constants.
CROSSPROD
Analog Inputs
Analog Outputs
Digital Outputs
Constants
kcgain=1
kcbias=0
(kcross[2]*pow(kxvalue,2)) +
(kcross[3]*kyvalue) +
(kcross[4]*pow(kyvalue,2)) +
(kcross[5]*kxvalue*kyvalue) +
(kcross[6]*pow(kxvalue,2)*kyvalue) +
(kcross[7]*kxvalue*pow(kyvalue,2)) +
(kcross[8]*pow(kxvalue,2)*pow(kyvalue,2));
SP_0030 299
9.42 Crossprod
300 SP_0030
9.43 Deaerator
9.43 Deaerator
Deaerator is a direct contact type heat exchanger. The following steps calculate the condensate
inlet flow, outlet flow, inlet enthalpy and outlet enthalpy. The extraction steam flow and enthalpy
are also calculated.
DE AE RATOR
Analog Inputs
pdrop pres drop fr turb to deaerator [Optional] Must enter pressure drop if
turbExt pressure measured and dea
extraction pressure not measured.
SP_0030 301
9.43 Deaerator
DE AE RATOR
Analog Outputs
Constants
302 SP_0030
9.43 Deaerator
The deaerator is a direct contact type heat exchanger that is used to remove the air from the
boiler feedwater.
Where:
Where:
Where:
Where:
SP_0030 303
9.43 Deaerator
Where:
wdeain = wdeaoutlt+wdevap-wdrnintot-wdeaext-wdealkg
Where:
304 SP_0030
9.44 Densityair
9.44 Densityair
Densityair calculates air density at current temperature and pressure conditions as well as a
density correction factor.
DENSITYAIR
Analog Inputs
Analog Outputs
Constants
SP_0030 305
9.44 Densityair
DENSITYAIR
Molecular weight of Moist Air from Equation 5.3-4 of ASME PTC 11.
306 SP_0030
9.45 Densitycor
9.45 Densitycor
The Densitycor algorithm computes a density corrected to current temperature and pressure
conditions as well as a density correction factor.
DENSITYCOR
Analog Inputs
Analog Outputs
Constants
SP_0030 307
9.45 Densitycor
Where:
308 SP_0030
9.46 Densitygas
9.46 Densitygas
The Densitygas algorithm calculates the density of gas at the fan discharge as well as a density
correction factor.
DENSITYGAS
Analog Inputs
Analog Outputs
SP_0030 309
9.46 Densitygas
DENSITYGAS
Constants
Density Correction Factor - ratio of the density corrected to reference conditions to the design
density
310 SP_0030
9.47 Diganlgcmppoly
9.47 Diganlgcmppol y
The Diganlgcmppoly algorithm calculates the y-value of a polynomial based on the x input in a
specified range and a digital flag.
DIGANLGCMPPOLY
Analog Inputs
Digital Outputs
Constants
Diganlgcmppoly calculates a polynomial if a digital flag is set and within the specified value
region. Otherwise, the value is set to zero.
SP_0030 311
9.47 Diganlgcmppoly
else
kyvalue = 0.0;
312 SP_0030
9.48 Diganlgcmp2poly
9.48 Diganlgcmp2pol y
The Diganlgcmp2poly algorithm calculates one of two y-value polynomials based on an x input
value, Digital input and is split by a specified Analog value.
DIGANLGCMP2POLY
Analog Inputs
Digital Outputs
Constants
SP_0030 313
9.48 Diganlgcmp2poly
Diganlgcmp2poly calculates one polynomial if a digital is set and less than the specified analog
limit. Otherwise, a second polynomial will be calculated.
else
314 SP_0030
9.49 Digcmp2poly
9.49 Digcmp2pol y
The Digcmp2poly algorithm calculates one of two y-value polynomials based on an x input and a
digital flag.
DIGCMP2POLY
Analog Inputs
Digital Outputs
Constants
SP_0030 315
9.49 Digcmp2poly
Digcmp2poly calculates the first polynomial specified by the values found in the constants
kdpoly[0]-kdpoly[5] if the flag (zflag) is set to true. Otherwise, when the flag (zflag) is false, the
second polynomial specified by the constants kdoly2[0]-kdpoly2[5] is calculated.
if (zflag)
else
316 SP_0030
9.50 Digcmppoly
9.50 Digcmppol y
The Digcmppoly algorithm calculates the y-value of a polynomial based on an x input and digital
flag.
DIGCMPPOLY
Analog Inputs
Digital Outputs
Constants
kdigpoly[0] = 0
kdigpoly[1] = 1
kdigpoly[2] = 0
kdigpoly[3] = 0
kdigpoly[4] = 0
kdigpoly[5] = 0
kcgain = 1
kcbias = 0
This algorithm calculates the specified polynomial if the flag (zflag) is true. Otherwise, the result
is zero.
if (zflag)
SP_0030 317
9.50 Digcmppoly
+ kdigpoly[5] * pow(kxvalue,5);
kgain_tot = kptgain + kcgain;
kbias_tot = kptbias + kcbias;
kyvalue = (kyvalue * kgain_tot) + kbias_tot;
else
kyvalue = 0.0;
318 SP_0030
9.51 Digitalin
9.51 Digitalin
The Digitalin algorithm reads digital data agent inputs and outputs local digital values.
DIGITALIN
Analog Inputs
Digital Inputs
Digital Outputs
Digitalin Outputs
The digital outputs dinput_loc, dinput_loc, etc are assigned the value of dinput1, dinput2, etc.
SP_0030 319
9.52 Digitalout
9.52 Digitalout
The Digitalout algorithm outputs digital data agent points from local digital values.
DIGITALOUT
Analog Inputs
Digital Inputs
Digital Outputs
The Digitalout algorithm outputs the configured inputs to the selected output source.
Digitalout Outputs
The local tags (dinput1, dinput2, etc.) are configured to the digital inputs and sent to the selected
output source for the configured tags (doutput1, doutput2, etc.).
320 SP_0030
9.53 Divide4
9.53 Divide4
DIVIDE4
Analog Inputs
Analog Outputs
Digital Outputs
Constants
kcgain = 1
kcbias = 0
Divide4 calculates the result of the input value (kinval) divided by the product of the divide values
(kdval1-kdval4). The result is then gained and biased.
SP_0030 321
9.54 Drnclr
9.54 Drnclr
DRNCLR
Analog Inputs
Analog Outputs
Constants
Drnclr is used to calculate the drain cooler approach (DCA) for a feedwater heater. DCA is the
temperature difference between the condensate leaving the feedwater heater and the feedwater
entering the heater.
DCA Deviation - difference between the design DCA and the actual DCA
322 SP_0030
9.55 Drnpmp
9.55 Drnpmp
The Drnpmp algorithm calculates the heat and materials balance around a shell and tube type
heat exchanger with the drain pumped forward. The extraction, drain, inlet and outlet flows are
calculated for the feedheater. The turbine extraction flow and enthalpy are also calculated.
DRNPMP
Analog Inputs
SP_0030 323
9.55 Drnpmp
DRNPMP
Constants
< NONE >
324 SP_0030
9.55 Drnpmp
Where:
wturb = ((wcndup-wlkg-wdrnin_tot+waux)*(hfhoutlt-hfhinlt) -
wlkg*(hlkg - hdrnoutlt) - wdrnin_tot*(hdrnin_tot - hdrnoutlt) + waux*(hturb - hdrnoutlt)) /
((hturb - hdrnoutlt) + (hfhoutlt-hfhinlt))
Where:
SP_0030 325
9.55 Drnpmp
If heater is in service and drain pump is out of service, set the flow diverted to the heater as the
drain inlet flow and enthalpy plus the drain outlet flow and enthalpy from this heater.
if (!zdrnpump)
else
hhtrdvrt = 0.0;
whtrdvrt = 0.0;
wcnddvrt = 0.0;
hcnddvrt = 0.0;
326 SP_0030
9.56 Dvalgen
9.56 Dvalgen
The Dvalgen algorithm ANDs the value of a digital constant and point, and outputs the result to a
digital output point and calculates the digital flag value with the constant (kzconst).
DVALGEN
Analog Inputs
Digital Inputs
Digital Outputs
Constants
zconst=1
Dvalgen ANDs together the digital flag value with the constant (kzconst).
SP_0030 327
9.57 Econmz
9.57 Econmz
The Econmz algorithm computes the efficiency of the economizer, and the deviation from design.
ECONMZ
Analog Inputs
Analog Outputs
Constants
328 SP_0030
9.57 Econmz
ECONMZ
Calculate the feedwater inlet and outlet enthalpies as a compressed liquid function of feedwater
temperature and pressure. First, convert the pressures to absolute.
SP_0030 329
9.58 Emptyproject
9.58 Emptyproject
The Emptyproject algorithm does nothing, but it is required for synchronization of multiple projects
per workspace.
EMPTYPROJECT
Analog Inputs
Digital Inputs
Analog Outputs
Digital Outputs
Constants
The Emptyproject algorithm has no inputs and no outputs. This algorithm is only required for
multiple projects per Workspace. No inputs or outputs are configured for this algorithm and this
algorithm is just placed on a sheet.
330 SP_0030
9.59 Enthal
9.59 Enthal
The Enthal algorithm calculates the gas enthalpy given the fuel analysis, gas temperature,
reference enthalpy, and weight of ambient and injection moisture.
ENTHAL
Analog Inputs
Analog Outputs
SP_0030 331
9.59 Enthal
ENTHAL
332 SP_0030
9.59 Enthal
ENTHAL
Constants
Calculate absolute enthalpy at temperature tgt and subtract the base enthalpy at 32 deg.f to
determine the actual enthalpy at temperature tgt. To calculate the enthalpy of the exhaust gas at
32 deg. f, the base enthalpy is set to zero, set weight of dry air to base value.
kdryair = 1.0;
Wgasturbfuel = (kdryair + Wambnt) * Ffueltoair;
Wsupfuel = (kdryair + Wambnt + Winjmoist + Wgasturbfuel) * Fsupfuel;
kexhprod = kdryair + Wambnt + Wgasturbfuel + Wsupfuel + Winjmoist;
Wdryair = kdryair / kexhprod;
Wmoist = (Wambnt + Winjmoist) / kexhprod;
Wfuel = (Wgasturbfuel + Wsupfuel) / kexhprod;
Wcarbon = Rcarb * Wfuel / 100.0;
Whydr = Rhydr * Wfuel / 100.0;
Wsulf = Rsulf * Wfuel / 100.0;
Woxy = Roxy * Wfuel / 100.0;
Wnitr = Rnitr * Wfuel / 100.0;
Wco2 = Rco2 * Wfuel / 100.0;
Wco = Rco * Wfuel / 100.0;
Wso2 = Rso2 * Wfuel / 100.0;
Wnoncomb = Woxy + Wnitr + Wco2 + Wco + Wso2;
kexhaust = Wdryair + Wmoist + Wcarbon + Whydr + Wsulf + Wnoncomb;
tabstempgas = gpaunits.ConvertTemp(tempgas,TO_DEGF) + DEGFtoDEGR;
Fabstempgas = tabstempgas / 100.0;
hair = -1.15203 + 2.47795e-01*tabstempgas - 2.33568e-05*pow(tabstempgas,2) +
2.38185e-08*pow(tabstempgas,3) - 6.79369e-12*pow(tabstempgas,4) +
6.82532e-16*pow(tabstempgas,5);
hcarbon = 14.00137*Fabstempgas + 0.67027*pow(Fabstempgas,2) - 0.87505e-02*
pow(Fabstempgas,3) -8.57364*100.0/tabstempgas;
hmoist = 40.83193*Fabstempgas + 0.36710*pow(Fabstempgas,2) + 0.06160e-02*
pow(Fabstempgas,3) + 34.42356*100.0/tabstempgas;
SP_0030 333
9.59 Enthal
334 SP_0030
9.60 Expelep
9.60 Expelep
The Expelep algorithm computes expected expansion line end point if design curve not provided.
Procedure specified in Spenser, Cotton, Cannon paper "A Method for Predicting the Performance
of Steam Turbine Generators, 16,500 KW and Larger" (GER2007C).
EXPELEP
Analog Inputs
SP_0030 335
9.60 Expelep
EXPELEP
336 SP_0030
9.60 Expelep
EXPELEP
A35 0.37881801e-07
A40 -0.50719109e-09
A41 0.26393497e-09
A42 0.38021911e-10
A43 -0.10149993e-09
A44 0.47757232e-10
A45 -0.70989561e-11
Correct base reheat turbine efficiency for 3600 RPM condensing turbine (errteff_base = 1.93%)
for volumetric flow (wipblv). Percent volumetric flow correction (rrtevolc) calculated by dividing
1270000.0 by reheat turbine volumetric flow (wipblv) and multiplying by the number of parallel
flow sections at the beginning of expansion (NRHFLOWS)
Calculate volume flow corrected efficiency (errteff_volc) by subtracting the percent volume flow
correction (rrtevolc) from base efficiency at 1.5 inhga
Calculate correction for reheat turbine inlet pressure (pabshrhip) and bowl temperature (tipbwl) as
bivariate function of common log of the pressure, and the corresponding bowl enthalpy (hipbwl).
Calculate common log of bowl pressure (pabsipbwl)
kxarg = log10(pabsipbwl);
Set enthalpy argument (harg) to bowl enthalpy if bowl entropy (sipbwl) <= 2.0041 btu/lbR.
Otherwise, enthalpy argument set to minimum of calculated function and bowl enthalpy.
ht = 0.0;
harg = hipbwl;
else
harg = hipbwl;
else
harg = ht;
SP_0030 337
9.60 Expelep
Calculate correction for initial conditions using bivariate function defined in GER2007C. calculate
individual row corrections and sum for total correction for inlet conditions.
If bowl enthalpy outside range is (1150 btu/lb, 1750 btu/lb), set % correction for inlet conditions to
zero.
Row 0 correction
Rcorrin0 = A00 + A01 * kxarg + A02 * pow(kxarg, 2.0) + A03 * pow(kxarg, 3.0) +A04 *
pow(kxarg, 4.0) + A05 * pow(kxarg, 5.0);
Row 1 correction
Rcorrin1 = harg * (A10 + A11 * kxarg + A12 * pow(kxarg, 2.0) +A13 * pow(kxarg, 3.0) +
A14 * pow(kxarg, 4.0) +A15 * pow(kxarg, 5.0));
Row 2 correction
Rcorrin2 = pow(harg,2.0) * (A20 + A21 * kxarg + A22 * pow(kxarg, 2.0) +A23 *
pow(kxarg, 3.0) + A24 * pow(kxarg, 4.0) +A25 * pow(kxarg, 5.0));
Row 3 correction
Rcorrin3 = pow(harg, 3.0) * (A30 + A31 * kxarg + A32 * pow(kxarg, 2.0) +A33 *
pow(kxarg, 3.0) + A34 * pow(kxarg, 4.0) +A35 * pow(kxarg, 5.0));
Row 4 correction
Rcorrin4 = pow(harg, 4.0) * (A40 + A41 * kxarg + A42 * pow(kxarg, 2.0) +A4*pow(kxarg,
3.0) + A44 * pow(kxarg, 4.0) +A45 * pow(kxarg, 5.0));
else
Bowl enthalpy out of range, set correction for initial conditions to zero
Rcorrin0 = 0.0;
Rcorrin1 = 0.0;
Rcorrin2 = 0.0;
Rcorrin3 = 0.0;
Rcorrin4 = 0.0;
Calculate total correction for initial conditions by summing individual row corrections
Calculate corrected reheat turbine efficiency at 1.5 inhga by adding percent correction for initial
conditions (rrteintp) to the volume flow corrected efficiency (rrteff_volc)
Calculate reheat turbine available energy defined as the isentropic enthalpy drop at constant
entropy from inlet bowl conditions to 1.5 inhga.
338 SP_0030
9.60 Expelep
Calculate theoretical expansion line end point at 1.5 inhga by multiplying corrected reheat turbine
efficiency (errteff_corr) by reheat turbine available energy (hrhavl),and subtracting the result from
the reheat turbine bowl enthalpy.
Calculate quality of steam at theoretical expansion line end point (helept) and pressure (pelept)
Calculate percent moisture at theoretical expansion line end point and 1.5 inhga
Correct theoretical expansion line end point to the average exhaust pressure (pacnprs) by
calculating corrections separately to lp hood exhaust pressure (pacnprslp) and hp hood
(pacnprshp), and averaging them.
Note: pacnprslp and pacnprshp need to be converted back to inhga from psi so these equations
work.
Calculate correction to expansion line end point for lp hood pressure per equation defined in
GER2007C
Calculate correction to expansion line end point for hp hood pressure per equation defined in
GER2007C
Calculate expected expansion line end point at actual exhaust pressure by adding average
correction (hdltelep) to theoretical expansion line end point
SP_0030 339
9.61 Expon
9.61 Expon
The Expon algorithm calculates the exponential value of the input. The result can be gained and
biased by both constants and points.
EXPON
Analog Inputs
Analog Outputs
Digital Outputs
Constants
kcgain = 1 kcbias = 0
Expon calculates the exponential of the input (kvalue) and then this value can be gained and/or
biased.
kexpon_res = exp(kvalue);
kgain = kptgain + kcgain;
kbias = kptbias + kcbias;
kexpon_res = (kexpon_res * kgain) + kbias;
340 SP_0030
9.62 Fan
9.62 Fan
The Fan algorithm computes the efficiencies of the fan, its design efficiency and the deviation
from actual efficiency. If the analog input kcpratio is not configured, the compressibility factor will
not be calculated and set to 1.
FAN
Analog Inputs
SP_0030 341
9.62 Fan
FAN
Analog Outputs
Constants
If the analog input kcpratio is not configured, the compressibility factor will not be calculated and
set to 1.
if (zmtreffavail)
efandesmtr = efanmdes;
else
efandesmtr = (Pfanmtr / WtoMW) / (Ifanvltmtr * ifanampmtr * kfanpfmtr * ROOT3) * 100.0;
342 SP_0030
9.62 Fan
Compute the fan driver input power. Determine if it is measured. If it is measured, use that
measurement. If it is not measured, use the volts, amps, and power factor to perform the
calculation.
Calculate the fan input power by multiplying the nameplate motor efficiency by the driver input
power.
If the specific heat ratio is not configured, set the z, x, and compressibilty ouputs to zero.
Compute the fan total efficiency as the ratio of the fan output power to fan input power.
Compute the design fan efficiency as the fan output power divided by the fan expected power.
SP_0030 343
9.62 Fan
Compute the fan total efficiency deviation as the difference between actual and design
efficiencies.
Compute the static pressure by subtacting the discharge velocity pressure from the total pressure
deviation.
Compute the fan static efficiency as the total efficiency times the static pressure divided by the
total pressure deviation
344 SP_0030
9.63 Fandesign
9.63 Fandesign
The Fandesign algorithm reads the fan design information and outputs the design information.
FANDES IGN
Analog Inputs
Digital Inputs
Analog Outputs
Constants
The fan design algorithm outputs the information from the design screen as noted above in the
chart.
SP_0030 345
9.64 Fanvelocity
9.64 Fanvelocity
The Fanvelocity algorithm computes the velocity pressure of the fan using the volumetric flow,
density and area.
FANV E LOCITY
Analog Inputs
Analog Outputs
Constants
346 SP_0030
9.65 Fbdorder
9.65 Fbdorder
The Fbdorder algorithm orders the functional block diagrams as well as displaying all the
algorithms and execution time.
FBDORDER
Analog Inputs
Digital Inputs
Analog Outputs
Digital Outputs
Constants
In design mode, the Design Screen allows you to order the function block diagrams.
In run mode, the Design Screen displays the execution of all the functional block diagrams along
with a time for each.
SP_0030 347
9.66 Flowcalccomp
FLOWCALCCOMP
Analog Inputs
348 SP_0030
9.66 Flowcalccomp
FLOWCALCCOMP
Constants
KFLOW_COEF kcgain = 1
=16.46788
VSPEC_REF = kcbias = 0
3.4020
Flowcalccomp calculates on-line compensated flow based on actual and reference conditions.
The following shows the code overview.
if (zsatliq)
else
if (zsuperheated)
else
Next, the compensated flow calculation will be performed according to which point is configured.
else
SP_0030 349
9.67 Frloss
9.67 Frloss
The Frloss algorithm computes pipe section friction loss for fairly smooth pipe.
FRLOSS
Analog Inputs
Digital Inputs
Analog Outputs
Constants
Frloss computes pipe section friction loss for fairly smooth pipe
kpipediam = FrictionLossPipeDia();
kpipelength = FrictionLossPipeLen();
350 SP_0030
9.67 Frloss
SP_0030 351
9.68 Fuels
9.68 Fuels
The Fuels algorithm combines all the fuels used into one fuel analysis.
FUELS
Analog Inputs
352 SP_0030
9.68 Fuels
FUELS
SP_0030 353
9.68 Fuels
FUELS
354 SP_0030
9.68 Fuels
FUELS
SP_0030 355
9.68 Fuels
FUELS
Analog Outputs
356 SP_0030
9.68 Fuels
FUELS
SP_0030 357
9.68 Fuels
FUELS
358 SP_0030
9.68 Fuels
FUELS
SP_0030 359
9.68 Fuels
FUELS
360 SP_0030
9.68 Fuels
FUELS
C1 = C6 = -9.0344688e-14 C11 =
-1.0214165e+04 1.2890360e-05
C2 = C7 = 4.1635019e+00 C12 =
-4.8932428e+00 -2.4780681e-09
C3 = C8 = -1.0440397e+04 C13 = 6.5459673
-5.3765794e-03
C4 = 1.9202377e-07 C9 = -1.1294650e+01 CHEATVALUE =
94.73
SP_0030 361
9.68 Fuels
FUELS
The Fuels algorithm is used to combine all fuels used into one analysis. This algorithm handles
the following fuels:
Coal 1
Coal 2
Coal 3
Coal 4
Coke
Oil 1
Oil 2
Oil 3
Natural Gas
Blast Furnace Gas
Coke Oven Gas
This algorithm converts the natural gas, blast furnace gas, and coke oven gas analysis measured
on a mole percentage basis to a mass pound per pound basis. Since the gas analysis received
from the chromatograph is on a dry basis, it must first be converted to a wet basis per the
procedure outlined in ASME PTC 22,"Performance Test Code on Gas Turbines," 1997.
The molecular weight (mixture molar mass), net heating value, compressibility factor and ideal
gas density at base conditions of 60 deg.f and 14.696 psia are computed.
Finally, the real gas density is computed and used to convert the corrected wet gas mole fractions
to a pound per pound of fuel basis for carbon, hydrogen, oxygen, sulfur, nitrogen, moisture, and
carbon dioxide.
The analysis is converted to a wet basis per ASTM D 3588, 1991 ("Calculating Heat Value,
Compressibility Factor and Relative Density of Specific Fuels") as follows:
Where:
362 SP_0030
9.68 Fuels
Per ASME, the fraction of water in the flue gas is defined as the ratio of the fuel gas dew point
pressure to standard pressure (14.696). Fuel gas dew point pressure (pfgdew) is calculated as a
function of measured fuel gas dew point temperature (tfgdew) based on equations defined in
1993 ASHRAE Handbook of Fundamentals.
In general, for each fuel the relative weight to the total is calculated as follows:
Where:
The percentage amount of each element (hydrogen, oxygen, carbon etc) in the fuel mixture is
calculated by summing the percentage amount of that element present in each fuel of the mixture.
For example, to calculate the amount of hydrogen in a fuel mixture consisting of two type of coal
would be calculated as follows:
Rhydr_Coal1 = Rcoal1_H2*relwt_coal1
Rhydr_Coal2 = Rcoal2_H2*relwt_coal2
Rhydr = Rcoal1_H2 + Rcoal2_H2
Where:
SP_0030 363
9.69 Funcgen
9.69 Funcgen
The Funcgen algorithm calculates the independent value based on one variable or the
independent value based on two dependent variables. The independent value is calculated using
linear interpolation. The result can be modified by multiplying by a gain and/or adding a bias. Note
that the gain and bias can be points, constants or both points and constants.
FUNCGEN
Analog Inputs
zrange_check set rng flg unc qual inval rng [Optional] set flag 1
and output qual set
uncertain for range
errors
Analog Outputs
Digital Outputs
Constants
kcgain = 1
kcbias = 0
kcxdeadband = 0
kczdeadband = 0
364 SP_0030
9.69 Funcgen
Funcgen calculates an independent variable (kyvalue) based on one or two dependent variables
(kxvalue, kzvalue).
The design screen specifies how many variables will be used as well as filling in the data for each
variable.
The algorithm reads in the data from the design screen and solves the output value (kyvalue) by
linear interpretation. This output value can be gained and biased by constants and/or points.
The analog inputs (kxdeadband and kzdeadband) and constants (kcxdeadband and
kczdeadband) are used to provide a deadband for the x and z ranges.
The analog and constant deadbands are added together and subtracted for the lower x and z
values and added to the upper x and z values.
Messages are logged as an event type if the x value or z value goes below the lowest value
minus the deadbands or if the x value or z value goes above the highest value plus the
deadband values.
If the digital flag zrang_check comes in to the algorithm as a zero or is not configured, the output
quality will always be good. If the flag zrange_check is configured and has a value of 1, the
output quality will be uncertain if the x or z value falls outside of the deadband range.
if (kynum == 1)
kytemp = kyarray[0];
else
if (curve == BIVARIATE)
if (curve == UNIVARIATE)
if the actual value is smaller than the lower boundary, set the result to the lower boundary and
mark the quality bad.
kytemp = kyarray[0]
zbad_yvalue = 1;
Report event error
SP_0030 365
9.69 Funcgen
else
if the actual value is larger than the upper boundary, set the result to the upper boundary and
mark the quality bad.
kytemp = kyarray[kxnum-1]
zbad_yvalue = 1;
Report event error
else
If the x input value equals the xarray value, set the lower x index equal to this position. Otherwise
the lower x region will be one below this value.
if (kxvalue == kxarray[i])
lowx = i;
upx = i+1;
else
lowx = i-1;
upx = i;
kres1 = kyarray[lowx];
Check to see if at the last x value. If so, set the result equal to kres1.
if (kxvalue != kxarray[kxnum-1])
kres2 = kyarray[upx];
kytemp = kres1+(kres2-kres1)*(kxvalue-kxarray[lowx])/
(kxarray[upx]-kxarray[lowx]);
else
kytemp = kres1;
Two dependent variables
366 SP_0030
9.69 Funcgen
else
If the actual value is smaller than the lower boundary, set the value to the lower boundary and
mark the quality bad. Also log an event message.
else
If the actual value is larger than the upper boundary, set the value to the upper boundary and
mark the quality bad. Also log an event message
else
if (kzvalue == kzarray[i])
lowz = i;
upz = i+1;
else
lowz = i-1;
upz = i;
SP_0030 367
9.69 Funcgen
if (kxvalue == kxarray[j])
lowx = j;
upx = j+1;
else
lowx = j-1;
upx = j;
kres1 = kyarray[(lowz * kxnum) + lowx];
if (kxvalue != kxarray[kxnum-1])
else
kzcurve1 = kres1;
Calculate the z upper value. If at the highest z, set the upper z value equal to the lower z
value.
if (kzvalue != kzarray[kznum-1])
Check if at the upper x value. If at the upper x value, set the upper z curve equal to the lower x
value. If not, interpolate.
if (kxvalue != kxarray[kxnum-1])
else
kzcurve2 = kres3;
kytemp = kzcurve1 + (kzcurve2-kzcurve1)*(kzvalue-kzarray[lowz])/
(kzarray[upz]-kzarray[lowz]);
else
kytemp = kzcurve1;
kgain_tot = kptgain + kcgain;
kbias_tot = kptbias + kcbias;
kyvalue = (kytemp * kgain_tot) + kbias_tot;
368 SP_0030
9.69 Funcgen
If the range check flag is on and the value was out of range by the deadband value, set the quality
to UNCERTAIN.
if (zrange_check == 1)
SP_0030 369
9.70 GainBiasAdd
The GainBiasAdd algorithm: 20 analog input variables will first be gained and then biased. The
addition of the 20 gained and biased values is added together. The total is gained by the overall
gain value and biased by the overall bias value.
GAINBIASADD
Analog Inputs
370 SP_0030
9.70 GainBiasAdd
GAINBIASADD
SP_0030 371
9.70 GainBiasAdd
GAINBIASADD
Analog Outputs
372 SP_0030
9.70 GainBiasAdd
GAINBIASADD
kcval10_gain 1
kcval11_gain 1
kcval12_gain 1
kcval13_gain 1
kcval14_gain 1
kcval15_gain 1
kcval16_gain 1
kcval17_gain 1
kcval18_gain 1
kcval19_gain 1
kcval20_gain 1
kcval1_bias 0
kcval2_bias 0
kcval3_bias 0
kcval4_bias 0
kcval5_bias 0
kcval6_bias 0
kcval7_bias 0
kcval8_bias 0
kcval9_bias 0
kcval10_bias 0
kcval11bias 0
kcval12_bias 0
kcval13_bias 0
kcval14_bias 0
kcval15_bias 0
kcval16_bias 0
kcval17_bias 0
kcval18_bias 0
kcval19_bias 0
kcval20_bias 0
kresult_gain 1
kresult_bias 0
SP_0030 373
9.70 GainBiasAdd
The gainbiasadd module adds 20 gained and/or biased input values. The final total can be
gained and/or biased. Gain and bias all the inputs:
374 SP_0030
9.71 Gastrbintemp
9.71 Gastrbintemp
The Gastrbintemp algorithm calculates the actual gas turbine inlet enthalpy. This algorithm uses
an estimated gas turbine temperature as well as a calculated gas turbine inlet enthalpy to
calculate the actual gas turbine inlet enthalpy. This algorithm calls the enthal routine which solves
for the enthalpy at the estimated temperature and will iterate and re-calculate the enthalpy based
on a new temperature estimate until the calculated gas turbine inlet enthalpy is reached.
If the maximum number of loops is exceeded, the gas turbine inlet temperature will be set to 0
with BAD quality as well as the zerrflag being set. This may happen if the estimated gas turbine
inlet temperature is too far away from the actual gas turbine inlet temperature. If this happens, the
algorithm has constants which can be tuned depending on the project.
GAS TRBINTEMP
Analog Inputs
Analog Outputs
SP_0030 375
9.71 Gastrbintemp
GAS TRBINTEMP
Constants
RSTMQLOW 88.0
RSTMQHIGH 95.0
HLPTOTTEST 1010.93
ELPEXHTEST 89.24
ELPTOTTEST 90.68
RSTMQUALTEST 91.62
RMOISTRTEST 7.38
Calculate estimated fuel to air ratio. Divide gas flow by estimated airflow (wctestair).
376 SP_0030
9.71 Gastrbintemp
temp1 = 32.0;
temp2 = 0.0;
lhestgasref = function of temp1, Ffueltoairest, temp2, Wvapcmpin, Wvap, Rcarb, Rco2,
Rhydr, Rco, Rnitr, Roxy, Rsulf, Rso2, Rncmbt, temp2
zerrflag = 0;
zconvflag = 0;
kiter = 0;
Calculate estimated gas turbine inlet enthalpy at estimated gas inlet temperature
Compare estimated gas turbine inlet enthalpy (hestgasin) with calculated gas turbine inlet
enthalpy (hgasin)
zconvflag = 1;
tgasin = testgasin;
}
else
{
kiter = kiter + 1;
if (hgasin < hestgasin)
{
SP_0030 377
9.71 Gastrbintemp
}
}
}
Set error flag if max number of iterations exceeded and zero out gas turbine inlet temperature and
set to bad quality.
378 SP_0030
9.72 GE_combcyc
9.72 GE_combc yc
The GE_combcyc algorithm computes calculations using GE standards for the uncorrected plant
gross power output, gross thermal efficiency and gross heat rate in combined cycle operation.
The plant gross power output, thermal efficiency and heat rate are corrected for deviations from
guaranteed conditions based on GE correction curves.
GE_COMBCYC
Analog Inputs
SP_0030 379
9.72 GE_combcyc
GE_COMBCYC
Analog Outputs
Constants
FNUMCTG 2.0
PSTGRTD 196.18
PGTGRTD 172.3
rplanthr = PENCNV/(0.01*eplnteff);
380 SP_0030
9.72 GE_combcyc
Fplntpwbrp * Fplntpwhumd *
Fplpwwtrijng * Fplpwwtrijdo *
Fpltpwperfloss);
SP_0030 381
9.73 GE_combturb
9.73 GE_combturb
The GE_combturb module computes calculations using GE standards for the uncorrected gas
turbine gross thermal efficiency and gross heat rate in combined cycle operation.
The gas turbine heat rate is calculated as the inverse of thermal efficiency. The gas turbine gross
power output, thermal efficiency and heat rate are corrected for deviations from guaranteed
conditions based on General Electric correction curves.
The deviation between the calibrated run performance and the corrected performance is also
computed.
GE_COMBTURB
Analog Inputs
382 SP_0030
9.73 GE_combturb
GE_COMBTURB
Analog Outputs
WMINGAS 1.0
WMINOIL 1.0
SP_0030 383
9.73 GE_combturb
Determine which fuel is being fired - force fuel flow to zero if less than minimum
zon_oil = 0;
woil =0.0;
else
zon_oil = 1;
zon_gas = 0;
wlng = 0.0;
else
zon_gas = 1;
qgtpwr = (Pgtgpw*1000.0*3412.142)/1.0E+06;
if ( zon_gas )
else
egteffng = 0.0;
if( zon_oil )
else
egteffdo = 0.0;
if( zon_gas )
else
rgthrng = 0.0;
384 SP_0030
9.73 GE_combturb
if( zon_oil )
else
rgthrdo = 0.0;
Calculate the following for each fuel corrected gross power output gross power output deviation
corrected gross thermal efficiency gross thermal efficiency deviation corrected gross heat rate
gross heat rate deviation
if( zon_gas )
else
Pgtcorng = 0.0;
Rgtmwdevng = 0.0;
egtcorefng = 0.0;
Rgtefdevng = 0.0;
rgtcorhrng = 0.0;
Rgthrdevng = 0.0;
if( zon_oil )
else
Pgtcordo = 0.0;
Rgtmwdevdo = 0.0;
egtcorefdo = 0.0;
Rgtefdevdo = 0.0;
rgtcorhrdo = 0.0;
Rgthrdevdo = 0.0;
SP_0030 385
9.74 GE_Expan
9.74 GE_Expan
for General Electric reheat steam turbo-generators in an iterative procedure using the GER2007C
expansion line equations.
GE_EXPAN
Analog Inputs
386 SP_0030
9.74 GE_Expan
GE_EXPAN
Analog Outputs
SP_0030 387
9.74 GE_Expan
GE_EXPAN
388 SP_0030
9.74 GE_Expan
GE_EXPAN
Constance
VLIMIT,1400.0
HDELTA,20.0
SP_0030 389
9.74 GE_Expan
The GE_Expan function is an expansion line swing method to solve for the lp heater (and last
stage) extraction flow and enthalpy, the used energy end point (ueep) and expansion line end
point (elep). If the last stage extraction is superheated, the extraction enthalpy is calculated
directly as a superheated steam function of extraction steam temperature and pressure at the
heater shell. If the heater is not in-service, the extraction steam flow and enthalpy are set to
zero, and the ueep and elep are solved for directly.
The lp turbine last stage extraction is normally in the wet steam region. Solve for last stage (and
low press heater) extraction flow and enthalpy, used energy end point and expansion line end
point using expansion line equations defined in GER2007C.
zerrflag = 0;
Set expansion line curvature constant (khzero) to 650 for GE reheat turbine
khzero = 650.0;
Calculate dry specific volume at exhaust pressure of each low pressure turbine.
Calculate steam flow to lp turbine last stage by subtracting lp turbine extractions from crossover
flow (witrex).
Calculate heat acquired by steam (qsttot) by calculating a steam heat balance around the turbine.
Calculate heat in turbine extractions, excluding lp turbine last stage, by summing the heat in hp, ip
and lp (excluding last stage) extractions and in leakoffs to downstream turbine extraction stages
Calculate heat flow to glands - the total heat supplied to the steam seal regulator
qleaks = qssrlkg;
390 SP_0030
9.74 GE_Expan
if (zlpheater > 0)
Heater in-service, extraction steam superheated if extraction temp greater saturation temp.
Otherwise, the steam is wet
Superheated steam, calculate enthalpy directly as function of temp and absolute pressure
hsstp(&hextrlphtr, &textrlphtr, &pabsextrlphtr, &ITRNGE);
else
hwtstm = 10000.0;
If flash tank present (flag zflashdrain set true), upsteam heater drain goes to flash tank, and lp
heater inlet drain flow argument is set to zero. If a flash tank is not present, the inlet drain flow
argument is set to the upstream drain flow (wdrnoutup). The flash steam flow argument is
zeroed if a flash tank is not present.
if (zflashdrain > 0)
wflashin = wflashsteam;
else
wdrainin = wdrnoutup;
SP_0030 391
9.74 GE_Expan
If lp heater in service both the heater extraction enthalpy (hextrlphtr) and estimated enthapy
(hnew) are recalculated during the iterative procedure. Iterate until the absolute difference
between hfhelphtr and hnew is <= 0.1 btu/lb, or the number of iterations is exceeded. Zero overall
iteration counter.
kcntlphtr = 0.0;
if (zlpheater > 0)
Heater in service, calculate lp heater and lp turbine last stage extraction flow and enthalpy.
update current estimate of lp heater extraction enthalpy
hwtstm = hextrlphtr;
Low pressure heater drain pump present and in service if flag zlpdrainpump set
if (zlpdrainpump > 0)
Drain pump present and in service. low pressure heater drain pumped forward into condensate
before upstream heater. calculate extraction steam flow at heater shell (wextrlphtr) by performing
a heat balance. calculate drain flow (wdrnoutlphtr). no flash tank if drain pumped forward.
Calculate flow leaving heater (wfhoutltlphtr) by subtracting drain flow pumped forward
(wdrnoutlplphtr) from condensate flow (wcndea). Set heater inlet flow to outlet flow.
392 SP_0030
9.74 GE_Expan
else
Heater drain flows to condenser hotwell. Flow through heater is condensate flow to deaerator
(wcndea). Calculate extraction flow at heater shell from heat balance, and calculate drain flow
Set condensate flows into and out of heater to condensate flow to deaerator
wfhoutlphtr = wcndea;
wfhinlphtr = wcndea;
Last stage extraction mixes with steam seal regulator spill over to form total extraction to low
pressure heater extraction flow at mix pointis difference between total extraction and spillover.
Set conditions at turbine (wturblaststg, hturblaststg) to flow and enthalpy at the mix point
wturblaststg = wmixlaststg;
hturblaststg = hmixlaststg;
Calculate low pressure turbine exhaust flow (wltrex) by subtracting calculated lp turbine last stage
extraction flow (wturblaststg) from steam flow to last stage (wstmlaststg).
Calculate used energy end point (low pressure turbine exhaust enthalpy) by conducting a thermal
and electrical energy balance around the whole turbine to establish the net heat flow to the
condenser and the dividing by the net steam flow to the condenser which is the low pressure
turbine exhaust flow
Net heat acquired by both superheated and reheated steam supplied to turbine (qsttot)
Heat in turbine extractions (qext)
Heat flow to glands (qleaks)
Equivalent heat in gross electrical load including all losses (qgen)
SP_0030 393
9.74 GE_Expan
Total heat in turbine stage extractions (qext) by summing the heat in previous extractions
(sumext) to the heat in the number 7 extraction
Calculate net heat in low pressure turbine exhaust (qexhst) by subtracting heat in turbine stage
extractions (qext), heat flow to glands (qleaks) and generation energy (qgen) from net heat
acquired (qsttot)
Calculate low pressure turbine exhaust enthalpy (hltrex) by dividing net heat in exhaust (qexhst)
by exhaust steam flow (wltrex). Set used energy end point (ueep) to exhaust enthalpy (hltrex).
This is average used energy end point of both low turbines.
The exhaust loss and expansion line end point are calculated by an iterative procedure because
the moisture at the expansion line end point has to be known to calculate exhaust loss. Once the
expansion line end point has converged, an expansion is projected from the expansion line point
to the stauration line. The lp turbine last stage extraction enthalpy is initially assumed to be
saturated, and is calculated using an expansion line swing method.
Calculate initial expansion line end point estimate (helepes) by subtracting constant enthalpy drop
(hdelta = 20 btu/lb) from used energy end point (hueep)
Calculate expansion line end point (helepe) by iterative procedure until elep and estimated elep
(helepes) within 0.1 btu/lb. Do not exceed 30 ierations.
helepe = 10000.0;
kcount = 0;
Increment number iterations. reset estimated elep (helepe) to new calculated value (helepes)
Calculate quality of the steam (qltrex) at estimated expansion line end point (helepe) and average
turbine exhaust pressure (pacnabs)
394 SP_0030
9.74 GE_Expan
Calculate specific volume of exhaust steam (vcnprs) by multiplying dry specific volume (vdry) by
the moisture factor
hexloss = hexlssarg;
Calculate new expansion line endpoint (elepes) as function used energy end point (ueep),
exhaust loss (hexlss) and percent moisture (Rmstrex) per General Electric definition.
helepes = hueep - 0.87 * hexloss * (1.0 - 0.01 * Rmstrex) * (1.0 - 0.0065 * Rmstrex);
Set expansion line end point (helep) to final calculated estimate (helepes), set error flag (zerrflg) if
no convergence. this is average expansion line end point for both low pressure turbines
helep = helepes;
SP_0030 395
9.74 GE_Expan
Project expansion line from elep to saturation line. bypass if superheated steam or low pressure
heater out of service. in these cases the ueep and elep are already calculated
zerrflag = 1;
break;
Calculate entropy, enthalpy coordinates on the expansion line in the wet region at the last stage
extraction pres (pabsturblaststg) using expansion line equation in GER2007C. the lp heater, last
stage extraction, low pressure turbine exhaust flow, used energy end point and expansion line
end point calculations are repeated using the new lp heater extraction enthalpy until the estimated
and calculated extraction enthalpies agree within 0.1 btu/lb.
Calculate the entropy (selep) at the calculate expansion line end point (helep) and turbine exhaust
pressure (pacnabs)
Calculate the GER2007C rzero term. first calculate required exponent (krzexpn). khzero is
expansion line curvature constant
For first pass assume initial estimate (hnew) of last stage extraction enthalpy is saturated steam
function of extraction pressure (pabsturblaststg) hsvp(&hnew, &pabsturblaststg, &ITRNGE);
hest = 10000.0;
kcountexpline = 1.0;
Set current enthalpy estimate (hest) to new calculated value hnew and increment counter
hest = hnew;
kcountexpline = kcountexpline + 1.0;
396 SP_0030
9.74 GE_Expan
Calculate entropy (sest) at estimated extraction enthalpy (hest) and last stage extraction pressure
(pabsturblaststg). Test for error condition if subccooled enthalpy return. In this case, set error flag
and exit the function
zerrflag = 1;
break;
sest = stemp;
Calculate entropy coordinate on expansion line (sxline) at estimated enthalpy (hest) per
GER2007C. calculate required exponent (sxexpn).
Calculate new last stage extraction enthalpy (hnew) by adding the product of the expansion line
curvature (hzero) times the difference between the expansion line entropy (sxline) and estimated
last stage extraction entropy (sest) to the current estimated extraction enthalpy (hest).
zerrflag = 1;
break;
Convergence. set turbine last stage enthalpy to converged value hnew. Calculate enthalpy at low
pressure heater shell by a heat balance.
hturblaststg = hnew;
hextrlphtr = (wturblaststg * hturblaststg + wssrsplovr * hlktot) / wextrlphtr ;
SP_0030 397
9.74 GE_Expan
zerrflag = 1;
For parallel heaters calculate a,b parameters. Assuming the total last stage extraction flow is
equally divided between the two heaters.
if (zlpparallel > 0)
398 SP_0030
9.75 GE_hrsg
9.75 GE_hrsg
The GE_hrsg module calculates the input/output efficiency of the HRSG per GE specification.
GE_HRSG
Analog Inputs
SP_0030 399
9.75 GE_hrsg
GE_HRSG
Constants
400 SP_0030
9.75 GE_hrsg
Note: For this calculation the fuel flow must be Lb/Hr not KLb/Hr and the power must be Kw not
MW then convert to MBTU/HR
if( zon_gas )
else
if( zon_oil )
else
qhrsginputng = 0.0;
qhrsginputdo = 0.0;
else
eioeffng = 0.0;
SP_0030 401
9.75 GE_hrsg
else
eioeffdo = 0.0;
402 SP_0030
9.76 GE_stg
9.76 GE_stg
The GE_stg algorithm computes the steam turbine generator output correction factor for exhaust
pressure (condenser vacuum), steam turbine gross heat rate and steam turbine generator gross
thermal efficiency.
GE_STG
Analog Inputs
Constants
PSTGRTD 196.0
SP_0030 403
9.76 GE_stg
Note: qhrsgoutput is total heat out of all HRSGs that feed the STG
Note: qhrsgoutput is total heat out of all HRSGs that feed the STG
rstghr = 3412.142/(0.01*estgeff);
rstgcorhr = 3412.142/(0.01*estgcoreff);
Gross power output deviation in percent is the difference between the calibration run power
output adjusted for the number of gas turbines operating in combined cycle mode assuming equal
load sharing across the gas turbines and the corrected gross power output divided by the
calibration run power output.
nturb = 0.0;
if(zdoctg1)
nturb = nturb + 1.0;
if(zdoctg2)
nturb = nturb + 1.0;
nturb = nturb/2.0;
Rstgpwdev = 100.0 * ((Pstgpwperf * nturb - Pstgcorpw) /
(Pstgpwperf * nturb));
404 SP_0030
9.77 Gennet
9.77 Gennet
Generator efficiency
GENNET
Analog Inputs
Analog Outputs
SP_0030 405
9.77 Gennet
GENNET
Constants
Generator MVA
Power Factor
Net Generation
If neither net generation or auxiliary power is measured. Auxiliary power is calculated based on
a design screen percentage of the gross generation.
406 SP_0030
9.78 Gencorr
9.78 Gencorr
The Gencorr algorithm computes corrected steam turbine generator output bases on correction
curves provided by turbine manufacturer.
GENCORR
Analog Inputs
Flddmt thr stm temp out corr fact REQUIRED
Analog Outputs
Constants
SP_0030 407
9.78 Gencorr
Corrected generator output is calculated by dividing measured generator output by the product of
calculated group 2 correction factors.
Multiply generator output by difference between actual exhaust hood 1 pres output correction
factor (fldexhstp1) and expected exhaust hood 1 pres output correction factor (fldexhstpx1)
408 SP_0030
9.79 Gpalog
9.79 Gpalog
GPALOG
Analog Inputs
Analog Outputs
Digital Outputs
Constants
kcgain = 1
kcbias = 0
Gpalog takes the base 10 log of a number, multiplies by the gain and adds the bias.
klog_res = log10(kvalue)
kgain = kptgain + kcgain
kbias = kptbias + kcbias
klog_res = (klog_res * kgain) + kbias
SP_0030 409
9.80 Heartbeat
9.80 Heartbeat
The Heartbeat algorithm outputs the value of the constant followed by the value of the constant
multiplied by -1 and then continues this sequence of values. This algorithm toggles the constant
value to be used in controller logic to show that GPA is running.
HEARTBEAT
Analog Inputs
Analog Outputs
Digital Outputs
Constants
kheartbeat
Code:
If the heartbeat value exists, get the value and multiply by -1 and store the heartbeat value again
if (hearbeat exists)
else
The heartbeat value does not exist, set the value to the constant value
kheartbeat_val = kheartbeat;
410 SP_0030
9.81 Hetrte
9.81 Hetrte
The Hetrte algorithm calculates gross, net, and corrected turbine cycle heat rates.
HETRTE
Analog Inputs
Analog Inputs
SP_0030 411
9.81 Hetrte
HETRTE
Digital Inputs
zprochtnum [Optional]
Analog Outputs
412 SP_0030
9.81 Hetrte
HETRTE
Constants
Hetrte calculates gross and net turbine cycle heat rate. In addition, adjusted turbine cycle heat
rates with and without process steam are also calculated.
SP_0030 413
9.81 Hetrte
else
qprocnet = 0.0;
if (zprochtnum)
else
Net turbine cycle heat rate while using process steam. This is defined as the heat supplied to the
turbine divided by the net power output.
if (zprochtnum)
else
Gross turbine cycle heat rate is adjusted for the following correction factors:
main steam temp
main steam pressure
reheat steam temperature
reheat steam pressure
turbine exhaust pressure
rhrgaj = rhrtcg / (Fhrdmt * Fhrdmp * Fhrdrt * Fhrdpd * Fhrdcp * Fhrmisc)
414 SP_0030
9.81 Hetrte
Corrected Turbine Cycle Heat Rate Accounting for Process Steam (rhrgajwpr)
if (zprochtnum)
else
SP_0030 415
9.82 Hiselect6
9.82 Hiselect6
The Hiselect6 algorithm selects the highest value of six inputs The result can be modified by
multiplying by a gain and adding a bias Note that the gain and bias values can be points,
constants or both points and constants.
HISELECT6
Analog Inputs
Analog Outputs
Digital Outputs
Constants
kcgain = 1
kcbias = 0
Hiselect6 selects the highest value of up to six inputs. This result can be gained and/or biased
and is stored in the output khi6_result.
416 SP_0030
9.83 Hpfedhtr
9.83 Hpfedhtr
The Hpfedhtr algorithm calculates a heat and materials balance around a shell and tube type heat
exchanger. The extraction and drain flows are calculated. The turbine extraction flow and
enthalpy are also calculated.
HPFEDHTR
Analog Inputs
SP_0030 417
9.83 Hpfedhtr
HPFEDHTR
Analog Outputs
Constants
418 SP_0030
9.83 Hpfedhtr
Where:
SP_0030 419
9.84 Hpipsec
9.84 Hpipsec
The Hpipsec algorithm calculates the outlet flow for the HP or IP section of the HRSG as well as
the steam, economizer inlet and drum enthalpies.
HPIPSEC
Analog Inputs
Analog Outputs
Constants
420 SP_0030
9.84 Hpipsec
This algorithm is used to calculate the following items for either the HP or IP section of a HRSG:
HRSG Section (HP or IP) outlet flow
Superheater Outlet Steam Enthalpy
Economizer Inlet Feedwater Enthalpy
Section Drum Enthalpy
Section Outlet Flow
SP_0030 421
9.85 Hrmspasme
9.85 Hrmspasme
The Hrmspasme algorithm calculates the fractional heat rate correction factor for throttle steam
pressure being off design as specified by the ASME PTC 6 1, 1984 curve Throttle Pressure
Correction Factors for Single Reheat Units.
HRMSPASME
Analog Inputs
Analog Outputs
Constants
CONMSP[0] =
-0.268999485
CONMSP[1] =
-0.00088682
CONMSP[2] =
0.199601121
Hrmspasme is used to calculate the fractional heat rate correction factor for throttle steam
pressure being off design. This algorithm follows the procedures as specified by the ASME PTC 6
1, 1984 curve Throttle Pressure Correction Factors for Single Reheat Units.
Pressure Deviation in Percent Between Actual Throttle Steam Pressure and Reference Throttle
Steam Pressure.
422 SP_0030
9.85 Hrmspasme
SP_0030 423
9.86 Hrmstasme
9.86 Hrmstasme
The Hrmstasme algorithm calculates the fractional heat rate correction factor for throttle steam
pressure being off design as specified by the ASME PTC 6 1, 1984 curve reheat Temperature
Correction Factors for Single Reheat - Subcritical Pressure Parts.
HRMSTASME
Analog Inputs
Analog Outputs
Constants
CONMST[0] = -1.
1308642E-02
CONMST[1] = 1.
45305262E-21
CONMST[2] = -5.
0617284E-03
Hrmstasme is used to calculate the fractional heat rate correction factor for throttle steam
temperature being off design as specified by ASME PTC 6.1, 1984 curve, Throttle Temperature
Correction Factors for Single Reheat - Subcritical Pressure Parts.
424 SP_0030
9.86 Hrmstasme
SP_0030 425
9.87 Hrrpdasme
9.87 Hrrpdasme
The Hrrpdasme algorithm calculates the fractional heat rate correction factor for reheat pressure
drop being off design as specified by the ASME PTC 6 1, 1984 curve Reheater Pressure Drop
Correction Factors for Single Reheat Units.
HRRPDASME
Analog Inputs
Analog Outputs
Constants
CONRPD[0] = 0.0
CONRPD[1] = 1.
8E-01
Hrrpdasme is used to calculate the fractional heat rate correction factor for reheat pressure drop
being off design as specified by the ASME PTC 6.1, 1984 curve, Reheater Pressure Drop
Correction Factors for Single Reheat Units.
426 SP_0030
9.88 Hrrstasme
9.88 Hrrstasme
The Hrrstasme algorithm calculates the fractional heat rate correction factor for reheat steam
temperature being off design as specified by the ASME PTC 6 1, 1984 curve Reheat
Temperature Correction Factors for Single Reheat Units.
HRRS TASM E
Analog Inputs
Analog Outputs
Constants
CONRST[0] =
-1.1308642E-02
CONRST[1] =
1.45305262E-21
CONRST[2] =
-5.0617284E-03
Hrrstasme is used to calculate the fractional heat rate correction factor for reheat steam
temperature being off design as specified by the ASME PTC 6 1, 1984 curve Reheat
Temperature Correction Factors for Single Reheat Units.
Temperature Deviation
SP_0030 427
9.89 HRSG
9.89 HRSG
The HRSG algorithm calculates the outlet flow for the HP or IP sections of the HRSG as well as
the steam, economizer inlet and drum enthalpies.
HRSG
Analog Inputs
428 SP_0030
9.89 HRSG
HRSG
SP_0030 429
9.89 HRSG
HRSG
Rsf_hydr sup fuel hydrogen pcnt [Optional] Use if supp fuel is fired.
Rsf_oxy sup fuel oxygen pcnt [Optional] Use if supp fuel is fired.
Rsf_sulf sup fuel sulf pcnt [Optional] Use if supp fuel is fired.
Rsf_nitr sup fuel nitr pcnt [Optional] Use if supp fuel is fired.
Rsf_moist sup fuel moist [Optional] Use if supp fuel is fired.
Rsf_co2 sup fuel carbon dioxide pcnt [Optional] Use if supp fuel is fired.
Rsf_co sup fuel carbon monxide pcnt [Optional] Use if supp fuel is fired.
Rsf_so2 sup fuel carbon dioxide pcnt [Optional] Use if supp fuel is fired.
Rsf_ncmbt sup fuel non comb pcnt [Optional] Use if supp fuel is fired.
thrsgout hrsg outlet temp REQUIRED
Ffueltoairact act fuel to air ratio REQUIRED
Wvapin ambient spec humid REQUIRED
Wvap amb spec humid @ cmp inlet REQUIRED
430 SP_0030
9.89 HRSG
HRSG
Analog Outputs
SP_0030 431
9.89 HRSG
HRSG
Constants
432 SP_0030
9.89 HRSG
The HRSG is the Heat Recovery Steam Generator module. HRSG efficiency is defined as the
ratio of heat absorbed by the steam and water circuits to the heat added to the HRSG. The
primary sources of heat input to the HRSG are the sensible heat in the CTG exhaust and the heat
supplied from supplementary fuel (if used).
The heat out of the HRSG consists of energy added to the steam and water circuits within the
HRSG. To calculate this, all of the temperatures, pressures, and flows of each working fluid
stream as it enters and leaves the HRSG must be measured.
The ASME Thermal-Loss Method determines the major heat losses in the HRSG as a percentage
of total heat input. The losses are subtracted from 100% to determine efficiency.
The total heat leaving the HRSG is comprised of the heat in the steam at each stage extraction
and the heat in each stage blowdown flow. In addition there may be other miscellaneous steam
flows where heat is leaving the HRSG. In general the heat in each extraction is equal to the flow
times the difference between the enthalpy of the steam at the extraction and the enthalpy of the
feedwater.
Calculate the heat input by the various sections. If a section is not used, the heat calculated is
set to zero.
SP_0030 433
9.89 HRSG
qhrsgout = qhpstm + qipstm + qrhstm + qlpstm + qhpbdn + qipbdn + qlpbdn + qbfp + qmisc1
+ qmisc2 + qmisc3 + qmisc4
where:
(wsf_ngas + wsf_oilflow);
Input/Output Efficiency
The Input-output efficiency is calculated by dividing the total HRSG heat out by the total heat in.
434 SP_0030
9.89 HRSG
The heat loss efficiency is calculated by dividing the total heat losses by the total heat input to the
HRSG. This quotient is then subtracted from 1 and multiplied by 100 yielding the efficiency. The
calculations are summarized as follows:
SP_0030 435
9.90 Hwblrstm
9.90 Hw blrstm
The Hwblrstm algorithm calculates the boiler steam enthalpy and flow.
HWBLRSTM
Analog Inputs
Analog Outputs
Constants
436 SP_0030
9.90 Hwblrstm
HWBLRSTM
SP_0030 437
9.91 Hwmnstm
9.91 Hw mnstm
The Hwmnstm algorithm calculates the main steam enthalpy and flow.
HWMNSTM
Analog Inputs
Analog Outputs
Constants
438 SP_0030
9.92 Interpolate
9.92 Interpolate
The Interpolate algorithm interpolates the dependent value based on the independent value input
and up to 10 data sets of the dependent and independent values.
The dependent value is calculated using linear interpolation. The result can be modified by
multiplying by a gain and/or adding a bias.
Note that the gain and bias can be points, constants or both points and constants.
INTERPOLATE
Analog Inputs
kxvalue x input value [Optional]
kyvalue1 y value 1 [Optional]
kyvalue2 y value 2 [Optional]
kyvalue3 y value 3 [Optional]
kyvalue4 y value 4 [Optional]
Analog Outputs
kylovalue lo y value [Optional]
kyhivalue hi y value [Optional]
kxlovalue lo x value [Optional]
kyhivalue hi x value [Optional]
kyvalue y value [Optional]
Digital Outputs
< NONE >
Constants
kcgain 1
SP_0030 439
9.92 Interpolate
INTERPOLATE
kcbias 0
kxvalue1 0
kxvalue2 10
kxvalue3 20
kxvalue4 30
kxvalue5 40
kxvalue6 50
kxvalue7 60
kxvalue8 70
kxvalue9 80
kxvalue10 90
knumvalues 10
zbad_yvalue = 0;
kyarray[0] = kyvalue1;
kyarray[1] = kyvalue2;
kyarray[2] = kyvalue3;
kyarray[3] = kyvalue4;
kyarray[4] = kyvalue5;
kyarray[5] = kyvalue6;
kyarray[6] = kyvalue7;
kyarray[7] = kyvalue8;
kyarray[8] = kyvalue9;
kyarray[9] = kyvalue10;
kxarray[0] = kxvalue1;
kxarray[1] = kxvalue2;
kxarray[2] = kxvalue3;
kxarray[3] = kxvalue4;
kxarray[4] = kxvalue5;
440 SP_0030
9.92 Interpolate
kxarray[5] = kxvalue6;
kxarray[6] = kxvalue7;
kxarray[7] = kxvalue8;
kxarray[8] = kxvalue9;
kxarray[9] = kxvalue10;
numvalues = int(knumvalues);
if (numvalues == 1)
kytemp = kyarray[0];
else
If the actual value is smaller than the lower boundary, set the result to the lower boundary and
mark the quality bad.
kytemp = kyarray[0];
kres1 = kyarray[0];
kres2 = kyarray[0];
lowx = 0;
upx = 0;
zbad_yvalue = 1;
else
If the actual value is larger than the upper boundary, set the result to the upper boundary and
mark the quality bad.
kytemp = kyarray[numvalues-1];
kres1 = kyarray[numvalues-1];
kres2 = kyarray[numvalues-1];
lowx = numvalues-1;
upx = numvalues-1;
zbad_yvalue = 1;
else
SP_0030 441
9.92 Interpolate
If the x input value equals the xarray value, set the lower x index equal to this position. Otherwise
the lower x region will be one below this value.
if (kxvalue == kxarray[i])
lowx = i;
upx = i+1;
else
lowx = i-1;
upx = i;
kres1 = kyarray[lowx];
Check to see if at the last x value. If so, set the result equal to kres1.
if (kxvalue != kxarray[numvalues-1])
kres2 = kyarray[upx];
kytemp = kres1+(kres2-kres1)*(kxvalue-kxarray[lowx])/
(kxarray[upx]-kxarray[lowx]);
else
kytemp = kres1;
kylovalue = kres1;
kyhivalue = kres2;
kxlovalue = kxarray[lowx];
kxhivalue = kxarray[upx];
if (zbad_yvalue == 1)
kyvalue = QUAL_UNCERTAIN;
442 SP_0030
9.93 Invdig
9.93 Invdig
INVDIG
Analog Inputs
Digital Inputs
Digital Outputs
Constants
The Invdig algorithm inverts the digital input zflag and outputs the result in zinvflag.
if (zflag)
zinvflag = 0
else
zinvflag = 1
SP_0030 443
9.94 Ipturbdeseff
9.94 Ipturbdeseff
The Ipturbdeseff algorithm calculates the expected efficiency from the inlet bowl conditions to the
turbine exhaust. The calculated expected efficiency is then corrected to compute the expected
efficiency from the turbine inlet conditions to the measured crossover conditions.
Ipturbdeseff calculates design (or expected) intermediate pressure turbine efficiency using the
method outlined in Chapter 4, section iii.a.1, in K.C. Cotton's Evaluating and Improving Steam
Turbine Performance.
IPTURBDESEFF
Analog Inputs
Analog Outputs
444 SP_0030
9.94 Ipturbdeseff
IPTURBDESEFF
Digital Outputs
Constants
IP turbine bowl pressure is calculated by assuming a percent pressure drop across the IP turbine
inlet valve
The pressure at the IP turbine exhaust is calculated as function of crossover pressure and
percent pressure drop from turbine exhaust to crossover
The pressure ratio across the IP turbine stages is calculated as the ratio of bowl pressure to
exhaust pressure
The IP turbine bowl temperature (tipbwl) is calculated from the bowl pressure and enthalpy. The
volumetric bowl in cubic feet per hour is calculated by multiplying mass flow by the bowl specific
volume.
The internal IP turbine efficiency is calculated based on Figure 13 of, "IP Turbine and HP turbine
Turbine Single Stages Efficiency", GER2007C. This calculation is based on a procedure outlined
in Appendix IV of the paper, and K.C. Cotton's "Evaluating and Improving Steam Turbine
Performance".
Where:
Since the steam enthalpy at the IP turbine exhaust is equivalent to crossover enthalpy, the
expected IP turbine exhaust enthalpy is equivalent to the expected crossover enthalpy.
SP_0030 445
9.94 Ipturbdeseff
Where:
Where:
446 SP_0030
9.95 Loselect6
9.95 Loselect6
The Loselect6 algorithm selects the lowest value of six inputs The result can be modified by
multiplying by a gain and adding a bias Note that the gain and bias values can be points,
constants or both points and constants.
LOSELECT6
Analog Inputs
Analog Outputs
Digital Outputs
Constants
kcgain = 1
kcbias = 0
The Loselect6 algorithm selects the lowest value of kvalue1 - kvalue6. The output (klo6_result)
can also be gained and biased by constants and/or points.
SP_0030 447
9.96 Lpfedhtr
9.96 Lpfedhtr
The Lpfedhtr algorithm calculates a heat and materials balance around a low pressure shell and
tube type heat exchanger. The extraction and drain flows are calculated for the feedheater, the
turbine extraction flow and enthalpy are also calculated.
LPFEDHTR
Analog Inputs
pdrop press drop from turb to fedhtr [Optional] Use if only turbine extraction
pressure is available.
pincr press incr from fedhtr to turb [Optional] Use if only turbine extraction
pressure is available.
wssr stm seal regulator flow [Optional]
448 SP_0030
9.96 Lpfedhtr
LPFEDHTR
hpolyextr feedhtr Extr enthal approx [Optional] Use if only in the wet steam
region.
hpolyturb turbine Extr enthal approx [Optional] Use if only in the wet steam
region.
Digital Inputs
SP_0030 449
9.96 Lpfedhtr
LPFEDHTR
Constants
Where:
450 SP_0030
9.97 Lpsec
9.97 Lpsec
Lpsec calculates the LP section of the HRSG outlet flow, steam enthalpy, pre-heater enthalpy,
saturated liquid drum enthalpy and saturated steam drum enthalpy.
LPSEC
Analog Inputs
Analog Outputs
Constants
SP_0030 451
9.97 Lpsec
452 SP_0030
9.98 Lptrb
9.98 Lptrb
The Lptrb algorithm calculates the lp turbine outlet flow, the lp turbine outlet enthalpy by
conducting a thermal and energy balance around the whole turbine, the lp isentropic enthalpy and
the lp turbine efficiency.
LPTRB
Analog Inputs
SP_0030 453
9.98 Lptrb
LPTRB
Constants
Generation Energy
Where:
hlpadmin = hsstp(tlpadmin,pabslpadmin)
qlpadmin = (wlpadmin * hlpadmin) / RHTCNV
454 SP_0030
9.98 Lptrb
LP Turbine Efficiency
Where:
SP_0030 455
9.99 Lpturb3eff
9.99 Lpturb3eff
LPTURB3EFF
Analog Inputs
tlptai LP turbine stage A in temp REQUIRED
Analog Outputs
456 SP_0030
9.99 Lpturb3eff
LPTURB3EFF
Constants
RSTMQLOW 88.0
RSTMQHIGH 95.0
HLPTOTTEST 1010.93
ELPEXHTEST 89.24
ELPTOTTEST 90.68
RSTMQUALTEST 91.62
RMOISTRTEST 7.38
SP_0030 457
9.99 Lpturb3eff
Calculate overall efficiency factor for equation defined by the two efficiency points
Calculate exhaust stage efficiency factor for equation formed by the two points
458 SP_0030
9.99 Lpturb3eff
Solve for the steam quality at the intersection of the two lines. This is the starting point for the
iteration
Zero iteration counter, convergence error flag and last iteration flag
niter = 0;
kconv = 0;
lastiter = 0;
niter = niter + 1;
Test for convergence - exhaust stage enthalpy and average A, B stage efficiency must be within a
tolerance
SP_0030 459
9.99 Lpturb3eff
Convergence. calculate moisture content and overall LP turbine efficiency at steam quality
Rstmqual
Set results to values from G-3 Turbine Efficiency test data. Set all values to bad quality
hlptot = HLPTOTTEST;
elpexh = ELPEXHTEST;
elptot = ELPTOTTEST;
Rstmqual = RSTMQUALTEST;
Rmoistr = RMOISTRTEST;
460 SP_0030
9.100 Massflowliquid
MASSFLOWLIQUID
Analog Inputs
Analog Outputs
Constants
Where:
And
SP_0030 461
9.101 Mixer
9.101 Mixer
The Mixer algorithm calculates the outlet flow and enthalpy from a combination of up to 10 input
flows.
MIXER
Analog Inputs
Analog Outputs
462 SP_0030
9.101 Mixer
MIXER
Digital Outputs
Constants
kcqgain = 1
kcqbias = 0
Total Flow
woutlt = win1 + win2 + win3 + win4 + win5 + win6 + win7 + win8 + win9 + win10;
Enthalpy of Mixture
SP_0030 463
9.102 Moistair
9.102 Moistair
The Moistair algorithm calculates three of the five inputs which are not configured. Two of the
following five inputs must be configured.
dry bulb temperature
wet bulb temperature
ambient humidity
relative humidity
dew point temperature.
YES Units are Converted.
MOISTAIR
Analog Inputs
tdryarg dew point temp input [Optional] Two of 5 inputs must be configured:
tdryarg, twetarg, Wvarg, Rlhumarg, tdcwarg
twetarg wet bulb temp input [Optional] Two of 5 inputs must be configured:
tdryarg, twetarg, Wvarg, Rlhumarg, tdcwarg
Wvarg ambient humidity input [Optional] Two of 5 inputs must be configured:
tdryarg, twetarg, Wvarg, Rlhumarg, tdcwarg
Rlhumarg relative humidity input [Optional] Two of 5 inputs must be configured:
tdryarg, twetarg, Wvarg, Rlhumarg, tdcwarg
tdewarg dew point input [Optional] Two of 5 inputs must be configured:
tdryarg, twetarg, Wvarg, Rlhumarg, tdcwarg
patmos atmospheric pressure input REQUIRED
Digital Inputs
Analog Outputs
Digital Outputs
Constants
464 SP_0030
9.102 Moistair
Moistair calculates three of the five following inputs (tdryarg, twetarg, Wvarg, Rlhumarg, tdewarg).
Two of the five inputs must be configured as well as selected on the design screen.
SP_0030 465
9.103 Mult_add
9.103 Mult_add
The Mult_add algorithm adds eight pairs of numbers multiplied together. The result of the eight
pairs of numbers is then divided by the sum of the odd input values. The result of the eight pairs
added together can then be biased or gained by constants, points or both.
MULT_ADD
Analog Inputs
466 SP_0030
9.103 Mult_add
MULT_ADD
Analog Outputs
Constants
kcgain = 1
kcbias = 0
SP_0030 467
9.103 Mult_add
468 SP_0030
9.104 Multdiv
9.104 Multdiv
The Multdiv algorithm multiplies four numbers and divides by four numbers.
MULTDIV
Analog Inputs
Analog Outputs
Digital Outputs
Constants
kcgain = 1.0
kcbias = 0.0
kcdiv = 1.0
SP_0030 469
9.104 Multdiv
Multdiv calculates a result by multiplying four numbers (kmval1-kmval4) and dividing by the
product of four numbers (kdval1-kdval4). The result is gained and biased.
The gain and bias values can be points constants or both a point and a constant.
If either kmval3, kmval4, kdval1, kdval2, kdval3,kdval4 points are not configured, the
corresponding values are set to 1.0.
If the absolute value of the product of the divisors (kdval1, kdval2, kdval3, kdval4) is greater than
a tolerance (1.0 - 06) the result is defined by:
The total gain (ktotgain) and bias (ktotbias) values are obtained by summing the individual point
and constant values, then:
The gain and bias factors are applied to the result of the (kmultdiv_res) as follows:
If the absolute value of the divisors is less than the tolerance, the result (kmultdiv_res) is set to
zero, with bad quality.
470 SP_0030
9.105 Multiply4
9.105 Multipl y4
MULTIPLY4
Analog Inputs
Analog Outputs
Digital Outputs
Constants
kcgain = 1
kcbias = 0
Multiply4 calculates the product of the four input values (kvalue1, kvalue2, kvalue3, kvalue4).
The result is gained and biased. The individual gain and bias values can be a constant, a point, or
both a point and a constant.
If either kvalue3 or kvalue4 is not configured, the corresponding values are set to 1.0.
SP_0030 471
9.105 Multiply4
The gain and bias values are applied to the product by:
472 SP_0030
9.106 Mult_pwr
9.106 Mult_pw r
The Mult_pwr module performs the addition of up to eight pairs of numbers and also calculates
the sum of eight pairs divided by the sum of the odd inputs. This algorithm is similar to Mult_add
in that each input can be gained and/or biased.
Additionally, this algorithm allows the user to raise each input to a specified power before the
inputs are multiplied together.
MULT_PWR
Analog Inputs
SP_0030 473
9.106 Mult_pwr
MULT_PWR
474 SP_0030
9.106 Mult_pwr
MULT_PWR
Analog Outputs
Constants
kcval1_gain 1
kcval2_gain 1
kcval3_gain 1
kcval4_gain 1
kcval5_gain 1
kcval6_gain 1
kcval7_gain 1
kcval8_gain 1
kcval9_gain 1
kcval10_gain 1
kcval11_gain 1
kcval12_gain 1
kcval13_gain 1
kcval14_gain 1
kcval15_gain 1
kcval16_gain 1
kcval1_bias 0
kcval2_bias 0
kcval3_bias 0
kcval4_bias 0
SP_0030 475
9.106 Mult_pwr
MULT_PWR
kcval5_bias 0
kcval6_bias 0
kcval7_bias 0
kcval8_bias 0
kcval9_bias 0
kcval10_bias 0
kcval11_bias 0
kcval12_bias 0
kcval13_bias 0
kcval14_bias 0
kcval15_bias 0
kcval16_bias 0
kcval1_pwr 1
kcval2_pwr 1
kcval3_pwr 1
kcval4_pwr 1
kcval5_pwr 1
kcval6_pwr 1
kcval7_pwr 1
kcval8_pwr 1
kcval9_pwr 1
kcval10_pwr 1
kcval11_pwr 1
kcval12_pwr 1
kcval13_pwr 1
kcval14_pwr 1
kcval15_pwr 1
kcval16_pwr 1
kcgain 1
kcbias 0
476 SP_0030
9.106 Mult_pwr
The Mult_pwr module performs the addition of up to eight pairs of numbers and and calculates
the sum of eight pairs divided by the sum of the odd inputs.
SP_0030 477
9.106 Mult_pwr
Add the pairs together for the total and divide by the sum of the odd inputs.
478 SP_0030
9.107 NeuralNet
9.107 NeuralNet
The Neural Net algorithm uses the neuron values input and multiplies a gain times the actual
value input for linear values and multiplies the gain times the myTanh value of the input if the
value is non-linear. The function myTanh is the hyperbolic tangent function. The gained neuron
values are totaled and gained and biased. The final result is rescaled by a scaled gain and bias.
NEURALNET
Analog Inputs
Analog Outputs
SP_0030 479
9.107 NeuralNet
NEURALNET
480 SP_0030
9.107 NeuralNet
NEURALNET
Constants
The NeuralNet algorithm adds up to twenty neural net inputs. The neural net inputs are selected
to be linear or non-linear on the design screen.
If linear, the NeuralNet input values are multiplied by the gain value on the design screen.
If non-linear, the tanh(input value) is multiplied times the gain value from the design screen.
The neural net output values are totaled, gained, and biased. The total gain and bias values are
read from the design screen. The neural net output is then rescaled for the proper units using the
rescaling gain and bias values entered on the design screen.
kdes_gain1 = NN_GetInputGain(0);
if (NN_GetInputType(0) == NNIT_LINEAR)
SP_0030 481
9.107 NeuralNet
else
else
kneuron_out1 = 0.0;
kdes_gain2 = NN_GetInputGain(1);
if (NN_GetInputType(1) == NNIT_LINEAR)
else
else
kneuron_out2 = 0.0;
kdes_gain3 = NN_GetInputGain(2);
482 SP_0030
9.107 NeuralNet
if (NN_GetInputType(2) == NNIT_LINEAR)
else
if (NN_GetInputType(2) == NNIT_NONLINEAR)
else
kneuron_out3 = 0.0;
kdes_gain4 = NN_GetInputGain(3);
if (NN_GetInputType(3) == NNIT_LINEAR)
else
if (NN_GetInputType(3) == NNIT_NONLINEAR)
else
kneuron_out4 = 0.0;
SP_0030 483
9.107 NeuralNet
kdes_gain5 = NN_GetInputGain(4);
if (NN_GetInputType(4) == NNIT_LINEAR)
else
if (NN_GetInputType(4) == NNIT_NONLINEAR)
else
kneuron_out5 = 0.0;
kdes_gain6 = NN_GetInputGain(5);
if (NN_GetInputType(5) == NNIT_LINEAR)
else
if (NN_GetInputType(5) == NNIT_NONLINEAR)
484 SP_0030
9.107 NeuralNet
else
kneuron_out6 = 0.0;
kdes_gain7 = NN_GetInputGain(6);
if (NN_GetInputType(6) == NNIT_LINEAR)
else
if (NN_GetInputType(6) == NNIT_NONLINEAR)
else
kneuron_out7 = 0.0;
kdes_gain8 = NN_GetInputGain(7);
if (NN_GetInputType(7) == NNIT_LINEAR)
SP_0030 485
9.107 NeuralNet
else
if (NN_GetInputType(7) == NNIT_NONLINEAR)
else
kneuron_out8 = 0.0;
kdes_gain9 = NN_GetInputGain(8);
if (NN_GetInputType(8) == NNIT_LINEAR)
else
if (NN_GetInputType(8) == NNIT_NONLINEAR)
else
kneuron_out9 = 0.0;
kdes_gain10 = NN_GetInputGain(9);
486 SP_0030
9.107 NeuralNet
if (NN_GetInputType(9) == NNIT_LINEAR)
else
if (NN_GetInputType(9) == NNIT_NONLINEAR)
else
kneuron_out10 = 0.0;
kdes_gain11 = NN_GetInputGain(10);
if (NN_GetInputType(10) == NNIT_LINEAR)
else
if (NN_GetInputType(10) == NNIT_NONLINEAR)
else
kneuron_out11 = 0.0;
SP_0030 487
9.107 NeuralNet
kdes_gain12 = NN_GetInputGain(11);
if (NN_GetInputType(11) == NNIT_LINEAR)
else
if (NN_GetInputType(11) == NNIT_NONLINEAR)
else
kneuron_out12 = 0.0;
kdes_gain13 = NN_GetInputGain(12);
if (NN_GetInputType(12) == NNIT_LINEAR)
else
if (NN_GetInputType(12) == NNIT_NONLINEAR)
488 SP_0030
9.107 NeuralNet
else
kneuron_out13 = 0.0;
kdes_gain14 = NN_GetInputGain(13);
if (NN_GetInputType(13) == NNIT_LINEAR)
else
if (NN_GetInputType(13) == NNIT_NONLINEAR)
else
kneuron_out14 = 0.0;
kdes_gain15 = NN_GetInputGain(14);
if (NN_GetInputType(14) == NNIT_LINEAR)
SP_0030 489
9.107 NeuralNet
else
if (NN_GetInputType(14) == NNIT_NONLINEAR)
else
kneuron_out15 = 0.0;
kdes_gain16 = NN_GetInputGain(15);
if (NN_GetInputType(15) == NNIT_LINEAR)
else
if (NN_GetInputType(15) == NNIT_NONLINEAR)
else
kneuron_out16 = 0.0;
kdes_gain17 = NN_GetInputGain(16);
490 SP_0030
9.107 NeuralNet
if (NN_GetInputType(16) == NNIT_LINEAR)
else
if (NN_GetInputType(16) == NNIT_NONLINEAR)
else
kneuron_out17 = 0.0;
kdes_gain18 = NN_GetInputGain(17);
if (NN_GetInputType(17) == NNIT_LINEAR)
else
if (NN_GetInputType(17) == NNIT_NONLINEAR)
else
kneuron_out18 = 0.0;
SP_0030 491
9.107 NeuralNet
kdes_gain19 = NN_GetInputGain(18);
if (NN_GetInputType(18) == NNIT_LINEAR)
else
if (NN_GetInputType(18) == NNIT_NONLINEAR)
else
kneuron_out19 = 0.0;
kdes_gain20 = NN_GetInputGain(19);
if (NN_GetInputType(19) == NNIT_LINEAR)
else
if (NN_GetInputType(19) == NNIT_NONLINEAR)
492 SP_0030
9.107 NeuralNet
else
kneuron_out20 = 0.0;
ktotal_gain = NN_GetTotalGain();
ktotal_bias = NN_GetTotalBias();
krescale_gain = NN_GetRescaledGain();
krescale_bias = NN_GetRescaledBias();
SP_0030 493
9.108 Nlog
9.108 Nlog
NLOG
Analog Inputs
Analog Outputs
Digital Outputs
Constants
kcgain = 1
kcbias = 0
The Nlog algorithm takes the natural log of a number, multiplies by the gain and bias and adds
the bias. The gain and bias values can be points, constants or both points and constants.
494 SP_0030
9.109 O2calc
9.109 O2calc
The O2calc algorithm estimates the O2 in the flue gas from the estimated air heater leakage.
O2CALC
Analog Inputs
vfgtot total vol of stoich fl gases [Optional] required if O2 bef ahtr meas wet
vfgstp vol of stoich fl gases at stp [Optional] required if O2 bef ahtr meas dry
Digital Inputs
Constants
SP_0030 495
9.109 O2calc
The O2calc algorithm estimates the amount of O2 in the flue gas from the estimated air heater
leakage.
Calculate the O2 at the heater outlet based on if the air heater O2 is measured on a wet or dry
basis.
if (zwetflag)
else
496 SP_0030
9.110 Or6
9.110 Or6
OR6
Analog Inputs
Digital Inputs
Digital Outputs
Constants
The Or6 algorithm computes the logical or result of six digital inputs. For each unconfigured point,
the corresponding value is set FALSE.
SP_0030 497
9.111 Overall_trb
9.111 Overall_trb
The Overall_trb algorithm calculates the turbine inlet enthalpy, isentropic enthalpy and the overall
turbine efficiency.
OVERALL_TRB
Analog Inputs
Analog Outputs
Constants
Turbine Efficiency
498 SP_0030
9.111 Overall_trb
Where:
SP_0030 499
9.112 P1stg
9.112 P1stg
The P1stg algorithm calculates a correction factor, absolute first stage pressure, rated absolute
pressure and corrected first stage pressure.
P1STG
Analog Inputs
Analog Outputs
Constants
500 SP_0030
9.112 P1stg
SP_0030 501
9.113 Patmos
9.113 Patmos
PATMOS
Analog Inputs
Digital Inputs
Analog Outputs
Digital Outputs
Constants
The barometric pressure (usually input in inches of mercury absolute) input pabsbaro is converted
to the output patmos (usually pounds per square inch absolute).
502 SP_0030
9.114 Pntvalidate
9.114 Pntvalidate
The Pntvalidate algorithm validates a point by checking a primary point for selected quality and
limits. If this point is not valid, possible substitutions are alternate point 1, alternate point 2 or a
constant value if neither the alternate points are configured or valid.
PNTVALIDATE
Analog Inputs
Analog Outputs
Digital Outputs
zsubflag [Optional]
Constants
SP_0030 503
9.114 Pntvalidate
Pntvalidate checks an input's quality and perform a substitution based on the information
configured in the design screen.
The input value is substituted based on an optional low/high range or quality. The point is always
substituted for bad quality and is substituted for uncertain quality if desired.
The Pntvalidate algorithm checks up to two alternate points. These alternate points can also be
checked for quality as well as low/high limits.
If the user desires, a constant may also be specified for substitution. A constant must be
specified if the first alternate and second alternate points are not configured. If the first
alternate's value is not valid or second alternate's value is not valid or a constant is not specified,
the original value and quality will be passed through.
Finally, the quality can be set to uncertain or good for the primary point based on the user's
choice on the design screen. Below is pseudo code to show the algorithm's execution.
if (Is 1st alternate not configured? ) // oops! 1st alternate not configured
if (okToProceed)
if (Is the second alternate not configured) // oops! 1st alternate not configured
okToProceed = 0
if (okToProceed)
504 SP_0030
9.114 Pntvalidate
if (Should we substitute for 2nd alternate?) // Yes, check the final possible substitution
if (Should we use the constant?) // Yes, use the constant
kout = Constant
kout = kprim
else // dont need to sub for ALT2, The 2nd alternate will do just fine!
kout = kalt2
kout = Constant
kout = kprim
else // dont sub for ALT_1, The 1st alternate will do just fine!
kout = kalt1
kout = Constant
kout = kprim
SP_0030 505
9.115 Poly
9.115 Pol y
POLY
Analog Inputs
Analog Outputs
Digital Outputs
Constants
kpoly[0] = 0
kpoly[1] = 1.0
kpoly[2] = 0
kpoly[3] = 0
kpoly[4] = 0
kpoly[5] = 0
kcgain = 1
kcbias = 0
The Poly algorithm calculates the result of a 5th order polynomial defined by the coefficients
(kpoly) kpoly [0], kpoly[1], kpoly[2], kpoly[3], kpoly[4], kpoly[5] which are specified on the constant
tab.
506 SP_0030
9.115 Poly
The total gain (ktotgain) and bias (ktotbias) values are obtained by summing the point and
constant values. Then,
The gain and bias values are applied to the result as follows:
SP_0030 507
9.116 Pump
9.116 Pump
The Pump algorithm computes the actual efficiency, design efficiency and efficiency deviation for
a pump.
PUMP
Analog Inputs
508 SP_0030
9.116 Pump
PUMP
Ppmpdrvrindes driver input pwr mtr driven [Optional] Use if not motor
driven.
Digital Inputs
SP_0030 509
9.116 Pump
PUMP
510 SP_0030
9.116 Pump
PUMP
Digital Outputs
Check if pump is in service. If not in service, all calculations are set to zero Per ASME PTC
PM-1993, pump performance has very little impact on heat rate, thus pump efficiency is seldom of
concern.
Determining whether or not the pump is meeting its capacity head curve within a given tolerance
is of significant importance. Therefore, the total head is calculated by the procedure defined in
ASME PTC 8.2, and divided by the design head that is calculated from the pump characteristic
curve.
The result is defined as the capacity of the pump. Check the number of phases, if configured,
then read the number of phases. If not configured, set the number of phases to three.
First, compute the saturated liquid pressure in psia corresponding to the measured suction
temperature using the steam table function 'pslt' to determine if the pressure lies in the saturated
or compressed liquid regions for boiler feedpumps only.
pabssucsat = pslt(tpmpsuc)
Check to see if suction pressure is measured for boiler feedpumps only. If not, add the constant
head from the design screen to the deaerator outlet pressure.
vpmpbfps = vslt(tpmpsuc);
dpmpbfps = 1 / vpmpbfps;
pabspmpsuc = pdeaout + patmos + (Hcondea * dpmpbfps / ARACNV);
else
Check to see what region the pressure lies for the boiler feedpumps only. The other types of
pumps are assumed to be in the saturated liquid region.
if
SP_0030 511
9.116 Pump
Calculate suction enthalpy from the compressed region steam table call
else
The liquid is in saturated region. Compute the pump suction enthalpy in btu/lb as a saturated
liquid steam table function of the pressure
Compute the saturated liquid pressure in psia corresponding to the measured suction
temperature using the steam table function 'pslt' to determine if the pressure lies in the saturated
or compressed liquid regions.
pabsdissat = pslt(tpmpdis)
Calculate the boiler feedpump discharge enthalpy in btu/lb as a compressed or saturated liquid
steam table function of the feedpump measured discharge pressure and the temperature if using
the compressed steam table call. If not a boiler feedpump, calculate the pump discharge enthalpy
as a saturated liquid call.
if
else
hpmpdis = hslt(tpmpdis)
Compute the heat added by the pump in btu/lb as the difference between the discharge and
suction enthalpies.
Depending on whether the suction pressure lies in the saturated liquid or compressed liquid
regions, the specific volume of the feed water at the pump suction is calculated accordingly.
if
else
vpmpsuc = vslt(tpmpsuc)
Compute the density of the feedwater at the pump suction in lb/ft3 as the inverse of the specific
volume at this location.
Compute the feedwater suction specific gravity from the specific volume and the density of water.
512 SP_0030
9.116 Pump
Compute the water velocity in ft/sec by dividing the water flow by the product of the suction area
of the pump nozzle and the suction density.
Compute the suction velocity in feet as a function of the velocity and gravity.
if
else
vpmpdis = vslt(tpmpdis)
dpmpdis = 1.0 / vpmpdis;
Compute the feedwater discharge specific gravity from the specific volume and the density of
water.
Compute the discharge velocity head as a function of the velocity and gravity.
Compute the total suction head in feet as the sum of the pressure head, suction elevation head
and the suction velocity head.
Compute the total discharge head in feet as the sum of the pressure head, discharge elevation
head and the discharge velocity head.
Compute the total pump head in feet as the difference between the total discharge head and the
total suction head.
For motor driven pumps, compute the design pump motor efficiency if it is not available. For
steam driven pumps, set the design pump motor efficiency to 0.
epmpmeff = epmpmdes;
SP_0030 513
9.116 Pump
else
if (Motor driven)
Ppmpdrvrin = Ppmpdrvrin
else
Calculate pump input power by multiplying nameplate motor efficiency by the driver input power.
Ppmpdrvrin = Ppmpdrvrindes;
Ppmpin = Ppmpdrvrin;
Obtain design speed information for pump. If design speed is entered and actual speed is
configured, calculate the speed ratio. Otherwise, set the speed ratio to 1.
Compute the pump output power as the product of the specific gravity, the volumetric water flow
and the pump head.
514 SP_0030
9.116 Pump
Compute the corrected pump output power as the product of the specific gravity, the volumetric
water flow and the pump head.
Compute pump actual efficiency as the ratio of pump output power to pump input power.
Compute corrected pump actual efficiency as the ratio of corrected pump output power to
corrected pump input power.
Compute pump overall efficiency as the ratio of pump output power to pump driver input power.
Compute corrected pump overall efficiency as the ratio of corrected pump output power to pump
driver input power.
Hpmphdd
Hpmphevcorr = Hpmphdcorr - Hpmpehdcorr;
SP_0030 515
9.116 Pump
Compute the pump head deviation percent as the ratio of corrected pump head to expected head
516 SP_0030
9.117 PUMP1SPD
9.117 PUMP1SPD
The Pump1spd algorithm calculates pump performance for pumps running at a constant speed.
Expected head, actual head, pump efficiency, efficiency deviation, and percent head deviations
are also calculated.
PUMP1SPD
Analog Inputs
SP_0030 517
9.117 PUMP1SPD
PUMP1SPD
518 SP_0030
9.117 PUMP1SPD
PUMP1SPD
if (PumpInService)
zdopump = 1;
else
zdopump = 0;
zinsvcpmp = zdopump;
SP_0030 519
9.117 PUMP1SPD
Per ASME PTC PM-1993, pump performance has very little impact on heat rate, thus pump
efficiency is seldom of concern. The bottom line is determining whether or not the pump is
meeting its capacity head curve within a given tolerance. Therefore, the total head is calculated
by the procedure defined in ASME PTC 8.2, and divided by the design head that is calculated
from the pump characteristic curve. The result is defined as the capacity of the pump.
if (zdopump)
Check the number of phases, if configured, read the number of phases. If not configured, set the
number of phases to three.
if (Configured)
knumphases = kphases;
else
knumphases = 3.0;
First, compute the saturated liquid pressure in psia corresponding to the measured suction
temperature using the steam table function 'pslt' to determine if the pressure lies in the saturated
or compressed liquid regions for boiler feedpumps only.
Check to see if suction pressure is measured for boiler feedpumps only. If not, add the constant
head from the design screen to the deaerator outlet pressure.
if (! SuctionPressMeas)
vslt(&vpmpbfps,&tpmpsuc,&ITRNGE);
dpmpbfps = 1 / vpmpbfps;
Hcondea = OutletPressHead(1);
pabspmpsuc = pdeaout + patmos + (Hcondea * dpmpbfps / ARACNV);
else
Check to see what region the pressure lies for the boiler feedpumps only. The other types of
pumps are assumed to be in the saturated liquid region.
The liquid is in compressed region if this is a boiler feedpump. Otherwise, the liquid is in saturated
region.
else
The liquid is in saturated region. Compute the pump suction enthalpy in btu/lb as a saturated
liquid steam table function of the pressure.
520 SP_0030
9.117 PUMP1SPD
Compute the saturated liquid pressure in psia corresponding to the measured suction
temperature using the steam table function 'pslt' to determine if the pressure lies in the saturated
or compressed liquid regions.
Calculate the boiler feedpump discharge enthalpy in btu/lb as a compressed or saturated liquid
steam table function of the feedpump measured discharge pressure and the temperature if using
the compressed steam table call. If not a boiler feedpump, calculate the pump discharge enthalpy
as a saturated liquid call.
else
hslt(&hpmpdis,&tpmpdis,&ITRNGE);
Compute the heat added by the pump in btu/lb as the difference between the discharge and
suction enthalpies.
Depending on whether the suction pressure lies in the saturated liquid or compressed liquid
regions, the specific volume of the feed water at the pump suction is calculated accordingly.
Compute the specific volume of the feed water at the pump suction in ft3/lb as a compressed
liquid steam table function of the feedpump measured suction temperature in deg.f and the
absolute suction pressure in psia. 'vcltp' is a steam table function.
else
Calculate the specific volume of the feed water at the pump suction in ft3/lb as a saturated liquid
steam table function of the feedpump measured suction temperature in deg.f. 'vslt' is a steam
table function.
Compute the density of the feedwater at the pump suction in lb/ft3 as the inverse of the specific
volume at this location.
Compute the feedwater suction specific gravity from the specific volume and the density of water.
Compute the water velocity in ft/sec by dividing the water flow by the product of the suction area
of the pump nozzle and the suction density.
ksucindia = InnerDia(SUCTION,0);
SP_0030 521
9.117 PUMP1SPD
if (CurUnits != ENGLISH)
Compute the suction velocity in feet as a function of the velocity and gravity.
else
Compute the feedwater discharge specific gravity from the specific volume and the density of
water.
Compute the discharge velocity head as a function of the velocity and gravity.
kdisindia = InnerDia(DISCHARGE,0);
if (CurUnits != ENGLISH)
Compute the total suction head in feet as the sum of the pressure head, suction elevation head
and the suction velocity head.
Hpmpselv = ElevHead(SUCTION,1);
Hpmpshd = (pabspmpsuc * vpmpsuc * ARACNV) + Hpmpselv + Hpmpsvel;
Compute the total discharge head in feet as the sum of the pressure head, discharge elevation
head and the discharge velocity head.
Hpmpdelv = ElevHead(DISCHARGE,1);
Hpmpdhd = (pabspmpdis * vpmpdis * ARACNV) + Hpmpdelv + Hpmpdvel;
522 SP_0030
9.117 PUMP1SPD
Compute the total pump head in feet as the difference between the total discharge head and the
total suction head.
For motor driven pumps, compute the design pump motor efficiency if it is not available. For
steam driven pumps, set the design pump motor efficiency to 0.
Ppmpmtr = 0.0;
Ipmpvltmtr = 0.0;
ipmpampmtr = 0.0;
kpmppfmtr = 0.0;
epmpmeff = epmpmdes;
else
if (! PUMP_STEAM_DRIVEN)
Ppmpmtr = MotorNPPower(1);
Ipmpvltmtr = MotorNPVolts();
ipmpampmtr = MotorNPAmps();
kpmppfmtr = MotorNPPowFact();
epmpmeff = ((Ppmpmtr / WtoMW) / (Ipmpvltmtr * ipmpampmtr * kpmppfmtr *
pow(knumphases,0.5))) * 100.0;
else
Ppmpmtr = 0.0;
Ipmpvltmtr = 0.0;
ipmpampmtr = 0.0;
kpmppfmtr = 0.0;
epmpmeff = 0.0;
if (PUMP_MOTOR_DRIVEN)
if (Configured)
Ppmpdrvrin = Ppmpdrvrindes;
else
SP_0030 523
9.117 PUMP1SPD
Calculate pump input power by multiplying nameplate motor efficiency by the driver input power.
else
Ppmpdrvrin = Ppmpdrvrindes;
Ppmpin = Ppmpdrvrin;
Convert the measured mass flow in klb/hr to volumetric flow in gallons/minute. The definitions
used in the following equation are included in the global header file.
Compute the pump output power as the product of the specific gravity, the volumetric water flow
and the pump head.
Compute pump actual efficiency as the ratio of pump output power to pump input power.
else
epmpaeff = 0.0;
Compute pump overall efficiency as the ratio of pump output power to pump driver input power.
else
epmpoeff = 0.0;
if (Configured)
epmpdes = epumpdes;
else
524 SP_0030
9.117 PUMP1SPD
Compute pump efficiency deviations as the difference between overall and design efficiencies.
if (Configured)
Hpmpehd = Hpumpehd;
else
Compute the pump head deviation percent as the ratio of corrected pump head to expected head.
else
Rpmphddev = 0.0;
else
SP_0030 525
9.118 PUMP2STG
9.118 PUMP2STG
The Pump2stg algorithm calculates pump performance for a pump which has an extraction or
discharge between two stages of the pump. If available, expected heads for individual stages are
calculated and compared to actual.
Total expected head and actual total head can also be calculated and a deviation reported.
Pump efficiency, efficiency deviation, and percent head deviations are also calculated.
PUMP2STG
Analog Inputs
526 SP_0030
9.118 PUMP2STG
PUMP2STG
SP_0030 527
9.118 PUMP2STG
PUMP2STG
528 SP_0030
9.118 PUMP2STG
PUMP2STG
SP_0030 529
9.118 PUMP2STG
PUMP2STG
zinsvcpmp = zdopump;
Per ASME PTC PM-1993, pump performance has very little impact on heat rate, thus pump
efficiency is seldom of concern. The bottom line is determining whether or not the pump is
meeting its capacity head curve within a given tolerance. Therefore, the total head is calculated
by the procedure defined in ASME PTC 8.2, and divided by the design head that is calculated
from the pump characteristic curve. The result is defined as the capacity of the pump.
if (zdopump)
{
Check the number of phases, if configured, read the number of phases. If not configured, set the
number of phases to three.
if configured
knumphases = kphases;
530 SP_0030
9.118 PUMP2STG
else
knumphases = 3.0;
First, compute the saturated liquid pressure in psia corresponding to the measured suction
temperature using the steam table function 'pslt' to determine if the pressure lies in the saturated
or compressed liquid regions for boiler feedpumps only.
Check to see if suction pressure is measured for boiler feedpumps only. If not, add the constant
head from the design screen to the deaerator outlet pressure.
if (!(IsSuctionPressMeas()))
vslt(&vpmpbfps,&tpmpsuc,&ITRNGE);
dpmpbfps = 1 / vpmpbfps;
Hcondea = OutletPressHead(1);
pabspmpsuc = pdeaout + patmos + (Hcondea * dpmpbfps / ARACNV);
else
Check to see what region the pressure lies for the boiler feedpumps only. The other types of
pumps are assumed to be in the saturated liquid region.
The liquid is in compressed region if this is a boiler feedpump. Otherwise, the liquid is in saturated
region.
else
The liquid is in saturated region. Compute the pump suction enthalpy in btu/lb as a saturated
liquid steam table function of the pressure.
First, compute the saturated liquid pressure in psia corresponding to the measured extraction
temperature using the steam table function 'pslt' to determine if the pressure lies in the saturated
or compressed liquid regions for boiler feedpumps only.
SP_0030 531
9.118 PUMP2STG
Check to see what region the pressure lies for the boiler feedpumps only. The other types of
pumps are assumed to be in the saturated liquid region.
else
The liquid is in saturated region. Compute the pump stage extraction enthalpy in btu/lb as a
saturated liquid steam table function of the pressure.
Compute the saturated liquid pressure in psia corresponding to the measured suction
temperature using the steam table function 'pslt' to determine if the pressure lies in the saturated
or compressed liquid regions.
Calculate the boiler feedpump discharge enthalpy in btu/lb as a compressed or saturated liquid
steam table function of the feedpump measured discharge pressure and the temperature if using
the compressed steam table call. If not a boiler feedpump, calculated the pump discharge
enthalpy as a saturated liquid call.
absolute in psia.
else
hslt(&hpmpdis,&tpmpdis,&ITRNGE);
Compute the heat added by the two sections of the pump as well as the entire pump in btu/lb as
the difference between the discharge and suction enthalpies.
532 SP_0030
9.118 PUMP2STG
Depending on whether the suction pressure lies in the saturated liquid or compressed liquid
regions, the specific volume of the feed water at the pump suction is calculated accordingly.
Compute the specific volume of the feed water at the pump suction in ft3/lb as a compressed
liquid steam table function of the feedpump measured suction temperature in deg.f and the
absolute suction pressure in psia. 'vcltp' is a steamtable function.
else
Calculate the specific volume of the feed water at the pump suction in ft3/lb as a saturated liquid
steam table function of the feedpump measured suction temperature in deg.f. 'vslt' is a steam
table function.
Compute the density of the feedwater at the pump suction in lb/ft3 as the inverse of the specific
volume at this location.
Compute the feedwater suction specific gravity from the specific volume and the density of water.
Compute the water velocity in ft/sec by dividing the water flow by the product of the suction area
of the pump nozzle and the suction density.
ksucindia = InnerDia(SUCTION,0);
if (units != ENGLISH)
Compute the suction velocity in feet as a function of the velocity and gravity.
SP_0030 533
9.118 PUMP2STG
Depending on whether the stage extraction pressure lies in the saturated liquid or compressed
liquid regions, the specific volume of the feed water at the pump stage extraction is calculated
accordingly.
Compute the specific volume of the feed water at the pump stage extraction in ft3/lb as a
compressed liquid steam table function of the feedpump measured stage extraction temperature
in deg.f and the absolute stage extraction pressure in psia. 'vcltp' is a steam table function.
else
Calculate the specific volume of the feed water at the pump stage extraction in ft3/lb as a
saturated liquid steam table function of the feedpump measured stage extraction temperature in
deg.f. 'vslt' is a steam table function.
Compute the density of the feedwater at the pump stage extraction in lb/ft3 as the inverse of the
specific volume at this location.
Compute the feedwater stage extraction specific gravity from the specific volume and the density
of water.
Compute the discharge velocity head as a function of the velocity and gravity.
kdisindia = InnerDia(DISCHARGE,0);
if (units != ENGLISH)
Average the suction and discharge diamaters to obtain the stage extraction diameter
Compute the stage extraction velocity in feet as a function of the velocity and gravity.
534 SP_0030
9.118 PUMP2STG
else
Compute the feedwater discharge specific gravity from the specific volume and the density of
water.
Compute the total suction head in feet as the sum of the pressure head, suction elevation head
and the suction velocity head.
Hpmpselv = ElevHead(SUCTION,1);
Hpmpshd = (pabspmpsuc * vpmpsuc * ARACNV) + Hpmpselv + Hpmpsvel;
Compute the total stage extraction head in feet as the sum of the pressure head, and the stage
extraction velocity head.
Compute the total discharge head in feet as the sum of the pressure head, discharge elevation
head and the discharge velocity head.
Hpmpdelv = ElevHead(DISCHARGE,1);
Hpmpdhd = (pabspmpdis * vpmpdis * ARACNV) + Hpmpdelv + Hpmpdvel;
Compute the total pump head as well as the ip and hp stage heads in feet as the difference
between the total discharge head and the total suction head.
For motor driven pumps, compute the design pump motor efficiency if it is not available. For
steam driven pumps, set the design pump motor efficiency to 0.
Ppmpmtr = 0.0;
Ipmpvltmtr = 0.0;
ipmpampmtr = 0.0;
kpmppfmtr = 0.0;
epmpmeff = epmpmdes;
else
if (PUMP_STEAM_DRIVEN)
Ppmpmtr = MotorNPPower(1);
SP_0030 535
9.118 PUMP2STG
Ipmpvltmtr = MotorNPVolts();
ipmpampmtr = MotorNPAmps();
kpmppfmtr = MotorNPPowFact();
epmpmeff = ((Ppmpmtr / WtoMW) / (Ipmpvltmtr * ipmpampmtr * kpmppfmtr *
pow(knumphases,0.5))) * 100.0;
else
Ppmpmtr = 0.0;
Ipmpvltmtr = 0.0;
ipmpampmtr = 0.0;
kpmppfmtr = 0.0;
epmpmeff = 0.0;
if (PUMP_MOTOR_DRIVEN)
else
Calculate pump input power by multiplying nameplate motor efficiency by the driver input power.
else
Ppmpdrvrin = Ppmpdrvrindes;
Ppmpin = Ppmpdrvrin;
Obtain design speed information for pump. If design speed is entered and actual speed is
configured, calculate the speed ratio. Otherwise, set the speed ratio to 1.
ndesspeed = DesignSpeed();
Fspeed = 1.0;
else
536 SP_0030
9.118 PUMP2STG
Convert the measured input mass flow in klb/hr to volumetric flow in gallons/minute. The
definitions used in the following equation are included in the global header file.
Convert the measured output mass flow in klb/hr to volumetric flow in gallons/minute. The
definitions used in the following equation are included in the global header file.
Compute the pump output power as the product of the specific gravity, the volumetric water flow
and the pump head.
Compute the corrected pump output power as the product of the specific gravity, the volumetric
water flow and the pump head.
Compute pump actual efficiency as the ratio of pump output power to pump input power.
SP_0030 537
9.118 PUMP2STG
else
epmpaeff = 0.0;
Compute corrected pump actual efficiency as the ratio of corrected pump output power to
corrected pump input power.
else
epmpaeffcorr = 0.0;
Compute pump overall efficiency as the ratio of pump output power to pump driver input power.
else
epmpoeff = 0.0;
Compute corrected pump overall efficiency as the ratio of corrected pump output power to pump
driver input power.
else
epmpoeffcorr = 0.0;
if (Configured)
epmpdes = epumpdes;
else
if (Configured)
epmpdescorr = epumpdescorr;
else
Compute pump efficiency deviations as the difference between overall and design efficiencies.
538 SP_0030
9.118 PUMP2STG
if (Configured)
Hpmpipehd = Hehdipin;
else
if (Configured)
Hpmphpehd = Hehdhpin;
else
if (Configured)
Hpmptotehd = Hehdtotin;
else
if (Configured)
Hpmpipehdcorr = Hehdcorripin;
else
if (Configured)
Hpmphpehdcorr = Hehdcorrhpin;
else
if (Configured)
Hpmptotehdcorr = Hehdcorrtotin;
SP_0030 539
9.118 PUMP2STG
else
Compute the pump head deviation percent as the ratio of corrected pump head to expected head.
else
Rpmpiphddev = 0.0;
else
Rpmphphddev = 0.0;
else
Rpmptothddev = 0.0;
else
Riphddevcorr = 0.0;
else
Rhphddevcorr = 0.0;
540 SP_0030
9.118 PUMP2STG
else
Rtothddevcorr = 0.0;
else
SP_0030 541
9.119 Qavg4
9.119 Qavg4
The Qavg4 algorithm calculates the average of four values. Only the good quality points are
counted in the averaged value.
QAV G4
Analog Inputs
Analog Outputs
Digital Outputs
Constants
kcgain = 1
kcbias = 0
This algorithm calculates the average of four inputs. Only points with good or fair quality count in
the average. The result may be modified by multiplying by a gain and adding the bias. The gain
and bias values can be points, constants or both points and constants.
Unconfigured points and configured points not having good or fair quality are set to zero.
Then the average value of the points having good or fair quality is calculated by:
542 SP_0030
9.119 Qavg4
SP_0030 543
9.120 Qavg10
9.120 Qavg10
The Qavg10 algorithm calculates the average of 10 values Only the points with good quality are
counted in the average.
QAV G10
Analog Inputs
Analog Outputs
Digital Outputs
Constants
kcgain = 1
kcbias = 0
544 SP_0030
9.120 Qavg10
This algorithm calculates the average of 10 inputs. Only points with good or fair quality count in
the average. The result may be modified by multiplying by a gain and adding the bias. The gain
and bias values can be points, constants or both points and constants.
Unconfigured points and configured points not having good or fair quality are set to zero.
Then the average value of the points having good or fair quality is calculated by:
SP_0030 545
9.121 RANGECHECK10
9.121 RANGECHECK10
The RANGECHECK10 algorithm checks the values of up to 10 points. If the value is found to be
within the total hi and lo limits, the value and quality is passed thru.
If the value is found to be outside the hi or lo limit, the value is passed thru, the quality is set to
BAD, and the RNGCHECK flag is set.
The total hi and lo limits are calculated by adding the hi and lo limit input values to the hi and lo
limit constants.
RANGECHECK10
Analog Inputs
546 SP_0030
9.121 RANGECHECK10
RANGECHECK10
Analog Outputs
SP_0030 547
9.121 RANGECHECK10
RANGECHECK10
kchilimit1 0.0
kclolimit1 0.0
kchilimit2 0.0
kclolimit2 0.0
kchilimit3 0.0
kclolimit3 0.0
kchilimit4 0.0
kclolimit4 0.0
kchilimit5 0.0
kclolimit5 0.0
kchilimit6 0.0
kclolimit6 0.0
kchilimit7 0.0
kclolimit7 0.0
kchilimit8 0.0
kclolimit8 0.0
548 SP_0030
9.121 RANGECHECK10
RANGECHECK10
kchilimit9 0.0
kclolimit9 0.0
kchilimit10 0.0
kclolimit10 0.0
Next, the input values are passed thru to the output values and the digital flags are set to FALSE.
koutput1 = kinput1;
zrngcheck1 = 0;
koutput2 = kinput2;
zrngcheck2 = 0;
koutput3 = kinput3;
SP_0030 549
9.121 RANGECHECK10
zrngcheck3 = 0;
koutput4 = kinput4;
zrngcheck4 = 0;
koutput5 = kinput5;
zrngcheck5 = 0;
koutput6 = kinput6;
zrngcheck6 = 0;
koutput7 = kinput7;
zrngcheck7 = 0;
koutput8 = kinput8;
zrngcheck8 = 0;
koutput9 = kinput9;
zrngcheck9 = 0;
koutput10 = kinput10;
zrngcheck10 = 0;
For each configured point, check to see if the point's value is within the limits.
If it is, pass the value and quality thru. If it is not, pass the value thru and set the quality to bad
and set the digital range check flag.
koutput1 = QUAL_BAD;
zrngcheck1 = 1;
koutput2 = QUAL_BAD;
zrngcheck2 = 1;
koutput3 = QUAL_BAD;
zrngcheck3 = 1;
koutput4 = QUAL_BAD;
zrngcheck4 = 1;
koutput5 = QUAL_BAD;
zrngcheck5 = 1;
koutput6 = QUAL_BAD;
550 SP_0030
9.121 RANGECHECK10
zrngcheck6 = 1;
koutput7 = QUAL_BAD;
zrngcheck7 = 1;
koutput8 = QUAL_BAD;
zrngcheck8 = 1;
koutput9 = QUAL_BAD;
zrngcheck9 = 1;
koutput10 = QUAL_BAD;
zrngcheck10 = 1;
SP_0030 551
9.122 Reheat
9.122 Reheat
The Reheat algorithm calculates the heat recovery steam generator cold reheat steam flow and
enthalpy before and after the cold reheat steam flow mixes with the intermediate pressure outlet
steam flow. The hot reheat flow and enthalpy are also calculated.
REHEAT
Analog Inputs
Analog Outputs
Constants
552 SP_0030
9.122 Reheat
Hot reheat steam enthalpy is calculated from a steam table using hot reheat temperature and
pressure.
SP_0030 553
9.123 Reheat_trb
9.123 Reheat_trb
The Reheat_trb algorithm calculates the reheat turbine efficiency, the reheat design efficiency and
the reheat turbine efficiency deviation.
REHEAT_TRB
Analog Inputs
Analog Outputs
554 SP_0030
9.123 Reheat_trb
REHEAT_TRB
SP_0030 555
9.123 Reheat_trb
The Reheat_trb algorithm calculates the reheat turbine efficiency, the reheat design efficiency and
the reheat turbine efficiency deviation.
Reheat_trb Overview:
Calculate the correction to expansion line end point for exhaust pressure at 0 percent moisture.
else
pabspcnprs_avg = pabspcnprs
hchng_elep = CORELEP[0] + CORELEP[1]*(log(pabspcnprs_avg/INHGtoPSI)) +
CORELEP[2]*(pow(log(pabspcnprs_avg/INHGtoPSI),2))
Check to see if the theoretical expansion line end point is configured. If not,calculate it by
starting with the base efficiency and adding on any applicable corrections.
exp_elep(&htheo_elep,zipspd3600,zlpspd3600,wreheat_des,vreheat_des,pabsipbwl,sipbwl,hi
pbwl,
CPABSELEP, pabspcnprs_avg, kparallel_flows, hitrex)
else
htheo_elep = htheor_elep
Calculate the quality of steam at the theoretical expansion line end point
Calculate the percent moisture at the theoretical expansion line end point and 1.5
556 SP_0030
9.123 Reheat_trb
Calculate the quality of steam at the expected expansion line end point
xswhp(&Fqualexp_elep,&hexpect_elep,&pabspcnprs_avg,&ITRNGE)
vsvp(&vcnprs,&pabspcnprs_avg,&ITRNGE)
Calculate the annulus velocity. First, read the area and number of lp extraction flows
alpannulus = LPTurbAnnulusArea
klpextflows = LPExtFlows
Vannulus = (KLBtoLB * wltrex * vcnprs * (1.0 - 0.01 * Rmst_exp_elep)) / (klpextflows *
alpannulus * HRtoSEC);
hexlss(&hexloss,&hexp_uenergy,pabspcnprs_avg,htheo_elep,hexpect_elep,&Vannulus,Rmst
_exp_elep,wltrex,
alpannulus,klpextflows, zlpspd3600, VLIMIT, &zerrcode);
if (zerrcode)
histpp(&hisen_uenergy,&tipbwl,&pabsipbwl,&pabspcnprs_avg,&ITRNGE)
SP_0030 557
9.124 Select10
9.124 Select10
This module selects an analog input based on the selected analog input value.
The select input value will be changed into an integer and if the value is less than 1 or greater
than 10, the output value will be set to 0.0 with bad quality. If no input values are configured, the
output value will also be set to 0.0 with bad quality. Otherwise, the analog input value and quality
corresponding to the number in the selected analog input value will be moved into the output
point.
SELECT10
Analog Inputs
Digital Inputs
Digital Outputs
<NONE>
Constants
kcgain, 1
kcbias, 0
558 SP_0030
9.124 Select10
kselect = int(kselect_val);
if (kselect < 2)
kresult = kinput1;
else
if (kselect < 3)
kresult = kinput2;
else
if (kselect < 4)
kresult = kinput3;
else
if (kselect < 5)
kresult = kinput4;
else
if (kselect < 6)
kresult = kinput5;
else
if (kselect < 7)
kresult = kinput6;
else
if (kselect < 8)
kresult = kinput7;
else
if (kselect < 9)
kresult = kinput8
else
if (kselect < 10)
kresult = kinput9;
else
kresult = kinput10;
SP_0030 559
9.124 Select10
else
kresult = 0.0;
kresult quality = BAD;
560 SP_0030
9.125 Setdig
9.125 Setdig
The Setdig algorithm sets a Digital to 1 if an Analog value is greater than a limit. Otherwise, the
Digital is set to zero.
SETDIG
Analog Inputs
Analog Outputs
Digital Outputs
Constants
kcload = 0.0
kclimit = 0.0
The Setdig algorithm sets a digital output (zflag) based on an analog input's value (kptload) plus a
constant load (kcload).
If the total load is less than or equal to the specified limit (kptlimit + kclimit), the digital flag (zflag)
is set to false. Otherwise, if the total load is greater than the specified limit (kptlimit + kclimit), the
digital flag (zflag) is set to true.
zflag = 0
else
zflag = 1
SP_0030 561
9.126 Setdig2
9.126 Setdig2
The Setdig2 algorithm sets one of three digital flags based on an analog input.
If the analog input is less than a specified limit, the first digital flag is set.
If the analog input is equal to the specified limit, the second digital flag is set.
If the analog input is greater than the specified limit, the third digital flag is set.
SETDIG2
Analog Inputs
Analog Outputs
Digital Outputs
kcload 0.0
kclimit 0.0
562 SP_0030
9.126 Setdig2
ktolerance = 1E-08;
zequalflag = 1;
else
zlessflag = 1;
else
zgreaterflag = 1;
SP_0030 563
9.127 Setvalidate
9.127 Setvalidate
The Setvalidate algorithm validates an entire Analoginavg tagset's output tags by checking limits
and quality.
SETVALIDATE
Analog Inputs
Analog Outputs
Constants
The Setvalidate algorithm allows the same substitution to be performed as pntvalidate except the
substitutions can be specified for an entire tag set instead of one point at a time.
In order for this algorithm to work, the box on the Analoginavg Tag Definition Screen must be
checked to allow additional points to be built for point validation/substitution. In setvalidate, a tag
set is selected and is automatically configured to the primary points in the setvalidate algorithm.
Alternate point(s) may be configured for any or all of the primary points. The design screen must
be modified for each point requiring validation. If no modifications are made for a point on the
design screen, no substitution will be made.
if (Is 1st alternate not configured?) // oops! 1st alternate not configured
564 SP_0030
9.127 Setvalidate
okToProceed = 0
if (okToProceed)
if (Is the second alternate not configured) // oops! 1st alternate not configured
if (okToProceed)
if (Should we substitute for 2nd alternate?) // Yes, check the final possible substitution
kout = Constant
kout = kprim
else // don't need to sub for ALT2, The 2nd alternate will do just fine!
kout = kalt2
kout = Constant
SP_0030 565
9.127 Setvalidate
kout = kprim
else // don't sub for ALT_1, The 1st alternate will do just fine!
kout = kalt1
kout = Constant
kout = kprim
566 SP_0030
9.128 Sin
9.128 Sin
The Sin algorithm performs the sine function on an input value (kvalue), gains and biases the
result and outputs the result in ksin_res.
SIN
Analog Inputs
Analog Outputs
Digital Outputs
Constants
kcgain = 1 kcbias = 0
ksin_res = sin(kvalue)
kgain = kptgain + kcgain
kbias = kptbias + kcbias
ksin_res = (ksin_res * kgain) + kbias
SP_0030 567
9.129 Specheatair
9.129 Specheatair
The Specheatair algorithm calculates the specific heat of air at a given temperature (cpair)
entering the boiler per Figure 3, ASME PTC 4.1 as a polynomial function of the air temperature
(tair).
SPECHEATAIR
Analog Inputs
Digital Inputs
Analog Outputs
Digital Outputs
Constants
CPAIR[0] = 0.23897
CPAIR[1] =
6.7857E-06
CPAIR[2] =
1.9643E-08
The coefficients used are obtained from regressing the curve in Figure 3 of ASME PTC-4 1.
The value of the constant CPAIR can be found on the constants tab and should not be modified.
The code for this algorithm is shown below.
568 SP_0030
9.130 Spechtair
9.130 Spechtair
The Spechtair algorithm calculates the specific heat ratio for air which is needed in the FAN
algorithm to calculate the compressibility factor.
SPECHTAIR
Analog Inputs
Analog Outputs
Constants
KWTCO2, 44.01
KWTO2, 32.0
KWTCO, 28.01
KWTN2, 28.02
KCONSTJC, 778.2
SP_0030 569
9.130 Spechtair
570 SP_0030
9.131 Specheatgas
9.131 Specheatgas
The Specheatgas algorithm calculates the specific heat of flue gas at a given temperature. The
coefficients are obtained from regressing the curve in Figure 7 of AMSE PTC-4 1.
SPECHEATGAS
Analog Inputs
Digital Inputs
Analog Outputs
Digital Outputs
Constants
CPGAS[0] = 0.237058
CPGAS[1] =
1.065875E-05
CPGAS[2] = 4.18508E-08
CPGAS[3] = 2.20475E-11
This module calculates the specific heat of flue gas (cpfluegas) at a given temperature (tfluegas).
The coefficients (CPGAS) are obtained from regressing the curve in Figure 7 of AMSE PTC-4.1
and can be found on the constants tab and should not be modified.
SP_0030 571
9.132 Spechtgas
9.132 Spechtgas
The Spechtgas algorithm calculates the specific heat ratio for gas which is needed in the FAN
algorithm to calculate the compressibility factor.
SPECHTGAS
Analog Inputs
Analog Outputs
Constants
KWTCO2, 44.01
KWTO2, 32.0
KWTCO, 28.01
KWTN2, 28.02
572 SP_0030
9.132 Spechtgas
SPECHTGAS
KCONSTJC, 778.2
SP_0030 573
9.133 Squareroot
9.133 Squareroot
SQUAREROOT
Analog Inputs
Analog Outputs
Digital Outputs
Constants
kcgain = 1
kcbias = 0
The Squareroot algorithm takes the square root of a number, multiplies by the gain and adds the
bias. The gain and bias values can be points, constants or both points and constants.
If the input value (kvalue) is non negative, and greater than a tolerance (1.0e - 16), the square
root is calculated by:
If the input value is less than the tolerance, the result is set to zero and bad quality.
574 SP_0030
9.134 Steadystate
9.134 Steadystate
The Steadystate algorithm checks for periods of steady state and logs the steady state periods to
the event logger. If the system stays in state beyond the maximum number of cycles, an event
message is logged and the steady state counter is reset.
STEADYSTATE
Analog Inputs
Constants
kchilimit 0.0
kclowlimit 0.0
kcmaxcyclecnt 720.0
SP_0030 575
9.134 Steadystate
First, the high and low limits for steady state are selected. If the analog input for the high limit is
configured, that value will be used. Otherwise, the constant for the high limit will be used. The
low limit works the same way. If the input is configured for the low limit, that value will be used.
Otherwise, the constant value will be used.
Next, check to see if mw are within limits, if they are increment the counter. If not, write an event
log message out with the number of steady state periods.
ksteadycnt = ksteadycnt + 1;
ksteadycnt = 0;
else
ksteadycnt = 0;
576 SP_0030
9.135 Sub4
9.135 Sub4
SUB4
Analog Inputs
Analog Outputs
Digital Outputs
Constants
kcgain = 1
kcbias = 0
The Sub4 algorithm subtracts four numbers from an input value, multiplies the result by the gain
and adds the bias.
SP_0030 577
9.136 Sub10
9.136 Sub10
The Sub10 algorithm subtracts 10 numbers from an input value, multiplies the result by the gain
and adds the bias.
SUB10
Analog Inputs
Analog Outputs
ksub10_res subtract 10 result REQUIRED
Digital Outputs
< NONE >
Constants
kcgain = 1
kcbias = 0
578 SP_0030
9.136 Sub10
SP_0030 579
9.137 Superhtr
9.137 Superhtr
The Superhtr algorithm computes the superheater efficiency and deviation from design.
SUPERHTR
Analog Inputs
Analog Outputs
Constants
580 SP_0030
9.137 Superhtr
SUPERHTR
Calculate the feedwater inlet and outlet enthalpies as a superheated steam function
SP_0030 581
9.138 Ttd
9.138 Ttd
The Ttd algorithm calculates the terminal temperature difference and deviation.
TTD
Analog Inputs
Analog Outputs
Constants
Actual terminal temperature difference is the feedheater extraction saturation temperature minus
the feedheater outlet temperature.
Terminal temperature difference deviation is the difference between the design terminal
temperature difference and the actual terminal temperature difference.
582 SP_0030
9.139 Turbgen
9.139 Turbgen
The Turbgen algorithm computes heat generated and percent load produced by each turbine
section.
TURBGEN
Analog Inputs
SP_0030 583
9.139 Turbgen
TURBGEN
Analog Outputs
Constants
< NONE >
The heat generated by the HP turbine is calculated by subtracting the heat in the HP turbine
extractions, the heat in the HP turbine leakages and the heat in the HP turbine exhaust, from the
HP turbine inlet steam heat. Miscellaneous steam flows that mix with steam before the turbine
throttle are included in the inlet steam heat. The result is converted to Mbtu/H.
Where:
The percent total load produced by the HP turbine section is calculated by converting the heat
generated by the HP turbine to megawatts, and dividing the result by total shaft power.
Where:
584 SP_0030
9.139 Turbgen
The heat generated by the IP turbine is calculated by subtracting the heat in the turbine
extractions, the heat in the turbine leakages and heat in the turbine exhaust from the inlet steam
heat. Miscellaneous inlet steam flows are included in the inlet steam heat. The result is converted
to MBTU/H.
The percent total load produced by the IP turbine section is calculated by converting the heat
generated by the IP turbine to megawatts, and dividing the results by total shaft power.
The percent load produced by the LP turbine (Rlpturb) is calculated by subtracting the percent
load produced by the HP turbine (Rhpturb) and the percent load produced by the IP turbine
(Ripturb) from 100%.
The heat generated by the reheat turbine (qrhturb) is calculated by adding the heat generated by
the IP turbine (qipturb) and the heat generated by the LP turbine (qlpturb). Similarly, the percent
load produced by the reheat turbine (Rrhturb) is calculated by adding percent load produced by
the IP turbine (Ripturb) and the percent load produced by the LP turbine (Rlpturb).
SP_0030 585
9.140 Turbin
9.140 Turbin
The Turbin algorithm calculates the turbine inlet enthalpy, the turbine outlet flow, the turbine outlet
enthalpy, the isentropic enthalpy and the turbine efficiency.
TURBIN
Analog Inputs
Analog Outputs
Constants
586 SP_0030
9.140 Turbin
The turbine outlet flow is calculated as the inlet flow minus the total extraction flow.
Turbine Efficiency
Where:
SP_0030 587
9.141 Unhraitdev
9.141 Unhraitdev
The Unhraitdev algorithm calculates the unit heat rate deviation for air heater air inlet temperature
deviation and the cost of the deviation.
UNHRAITDEV
Analog Inputs
Analog Outputs
Constants
Unhraitdev calculates the fractional change in boiler efficiency for the air heater air inlet
temperature being off design by subtracting one from the ratio of the corrected boiler efficiency to
the actual boiler efficiency.
Calculate the fractional change in unit heat rate for the air heater air inlet temperature being off
design by subtracting one from the ratio of the corrected boiler efficiency to the actual boiler
efficiency.
588 SP_0030
9.141 Unhraitdev
Compute the unit heat rate deviation in BTU/KWH and cost of the deviation in $/HR for air heater
air inlet temperature deviation from design.
SP_0030 589
9.142 Unhrasmecsc
9.142 Unhrasmecsc
The Unhrasmecsc algorithm calculates the ASME heat rate correction for five degrees Fahrenheit
of subcooling at the percent of valves wide open throttle flow.
UNHRASMECSC
Analog Inputs
Digital Inputs
Analog Outputs
Digital Outputs
Constants
CONCSC[0] = 0.066
CONCSC[1] =
-0.00036
The Unhrasmecsc algorithm calculates the heat rate correction factor for degrees Fahrenheit of
subcooling at the percent of valves wide open throttle flow.
590 SP_0030
9.143 Unhrasmeffw
9.143 Unhrasmeffw
The Unhrasmeffw algorithm calculates the ASME heat rate correction for five degrees Fahrenheit
final feedwater temperature deviation at the percent of valves wide open throttle flow.
UNHRASMEFFW
Analog Inputs
Digital Inputs
Analog Outputs
Digital Outputs
Constants
CONFFW[0] = 0.024
CONFFW[1] =
0.00114
Unhrasmeffw calculates the ASME heat rate correction for five degrees Fahrenheit final feedwater
temperature deviation at the percent of valves wide open throttle flow.
SP_0030 591
9.144 Unhrasmeipdev1
9.144 Unhrasmeipdev1
The Unhrasmeipdev1 algorithm calculates the ASME IP turbine loss factor number 1 as a function
of ip exhaust pressure.
UNHRASMEIPDEV1
Analog Inputs
Digital Inputs
Analog Outputs
Digital Outputs
Constants
CONLS1[0] = 0.7990657
CONLS1[1] = - 0.4785131E-02
CONLS1[2] = 0.3258645E-04
CONLS1[3] = -0.853411E-07
This algorithm calculates the ASME IP turbine loss factor number 1 as a function of IP exhaust
pressure.
592 SP_0030
9.145 Unhrasmeipdev2
9.145 Unhrasmeipdev2
The Unhrasmeipdev2 algorithm calculates the ASME IP turbine loss factor number 2 as a function
of ip exhaust pressure.
UNHRASMEIPDEV2
Analog Inputs
Digital Inputs
Analog Outputs
Digital Outputs
Constants
CONLS2[0] = 0.7781887
CONLS2[1] = -0.4812128E-02
CONLS2[2] = 0.3382398E-04
CONLS2[3] = -0.914272E-07
The Unhrasmeipdev2 algorithm calculates the ASME IP turbine loss factor number 2 as a function
of IP exhaust pressure.
SP_0030 593
9.146 Unhrasmemkp
9.146 Unhrasmemkp
The Unhrasmemkp algorithm calculates the ASME heat rate correction for one percent makeup
flow at the percent of valves wide open throttle flow.
UNHRASMEMKP
Analog Inputs
Digital Inputs
zdocalc Digital perf calc run flag REQUIRED
Analog Outputs
Digital Outputs
Constants
CONMKP[0] = 0.1410
CONMKP[1] = 0.00034
The Unhrasmemkp algorithm calculates the ASME heat rate correction for one percent makeup
flow at the percent of valves wide open throttle flow.
594 SP_0030
9.147 Unhrasmersf
9.147 Unhrasmersf
The Unhrasmersf algorithm calculates the ASME heat rate correction for one percent reheat
spray flow at the percent of valves wide open throttle flow.
UNHRASMERSF
Analog Inputs
Digital Inputs
Analog Outputs
Digital Outputs
Constants
CONRSF[0] = 0.05
CONRSF[1] = 0.0015
The Unhrasmersf algorithm calculates the ASME heat rate correction for one percent reheat
spray flow at the percent of valves wide open throttle flow.
SP_0030 595
9.148 Unhrasmessf
9.148 Unhrasmessf
This algorithm calculates the ASME heat rate correction for one percent superheat spray flow at
the percent of valves wide open throttle flow.
UNHRASMESSF
Analog Inputs
Digital Inputs
Analog Outputs
Digital Outputs
Constants
CONSSF[0] = 0.007
CONSSF[1] = 0.00016
The Unhrasmessf algorithm calculates the ASME heat rate correction for one percent superheat
spray flow at the percent of valves wide open throttle flow.
596 SP_0030
9.149 Unhrauxstm
9.149 Unhrauxstm
The Unhrauxstm algorithm calculates the unit heat rate deviation for auxiliary steam and the cost
of the deviation.
UNHRAUXSTM
Analog Inputs
Analog Outputs
Constants
The unit heat rate deviation in btu/kwh and the cost of the deviation in $/hr for auxiliary steam is
calculated.
SP_0030 597
9.150 Unhrbfpt
9.150 Unhrbfpt
The Unhrbfpt algorithm calculates the unit heat rate deviation for the total boiler feed pump
turbine auxiliary steam heat rate and the cost of the deviations.
UNHRBFPT
Analog Inputs
598 SP_0030
9.150 Unhrbfpt
UNHRBFPT
Analog Outputs
SP_0030 599
9.150 Unhrbfpt
UNHRBFPT
Constants
Calculate high pressure bfp turbine supply steam heat rate deviation if high pressure steam
present, otherwise set result to zero
HP steam is present. Calculate high pressure bfp turbine bfp supply steam heat rate deviation by
multiplying the deviation between the actual (whpbfpt) and expected (whpbfptes) high pressure
steam supplies by the enthalpy difference between aggregate high pressure supply steam
enthalpy (hhpbfpt) and final feedwater enthalpy (hcycle)
else
rmnbfptdev = 0.0;
600 SP_0030
9.150 Unhrbfpt
Since different exhaust pressures are possible, heat rate deviations are computed separately for
bfp turbine a and bfp turbine b extraction steam, and are summed to compute the total boiler
feedpump turbine extraction steam heat rate deviation. BFP turbine b is not processed if only one
bfp / bfp turbine exists.
Corrected BFP turbine a (b) extraction flows are calculated per procedure described by K.C.
Cotton, "Evaluating and Improving Steam Turbine Performance", Chapter 7 if they exist.
Set design extraction steam enthalpy to common design extraction steam enthalpy
wexbfptdesa / knobfp
Calculate available energy based on actual conditions, the difference between the inlet steam
enthalpy (hexbfpta) and the inlet steam isentropic enthalpy (hexbfptisena)
Calculate isentropic enthalpy from actual inlet conditions (hexbfpta) to design exhaust pressure
(pabfptexdesa).
Calculate available energy from actual inlet conditions to design exhaust pressure
Calculate isentropic enthalpy from design inlet conditions (hexbfptdes) to actual exhaust pressure
(paexbfpta).
Calculate available energy from design inlet conditions to actual exhaust pressure,
Calculate BFP turbine a steam flow correction for exhaust pressure (Fexbfptcorrhpa) by dividing
the actual available energy (hexbfptaea) by the available energy from the actual inlet conditions to
design exhaust pressure (hexbfptaebpa),
Calculate BFP turbine a steam flow correction for inlet conditions (Fexbfptcorrinita) by dividing the
actual available energy (hexbfptaea) by the available energy from design inlet conditions to actual
exhaust pressure (hexbfptaeinita),
Calculate reheat spray flow correction (Fexbfptrhta) by dividing throttle flow (wmnstm) by the sum
of thottle flow and reheat spray flow (wdsrhta)
SP_0030 601
9.150 Unhrbfpt
Calculate heat rate correction for BFP turbine a extraction steam from curve fit based on percent
of corrected extraction steam to throttle flow
Calculate correction at lower (Frefcor) and upper (Fupcor) flows in throttle flow segment. force
throttle flow argument to be in range (wvwo50, wvwo).
warga = WVWO50;
warga = WVWO;
else
warga = wmnstm;
Throttle flow argument in range (50% valves wide open throttle flow, 75% valves wide open
throttle flow)
else
The thottle flow argument in range (75% valves wide open throttle flow, valves wide open throttle
flow)
602 SP_0030
9.150 Unhrbfpt
Compute the fractional correction for 1% aux extraction scah supply steam at actual percent
valves wide open throttle flow by linear interpolation.
Calculate the heat rate deviation for the actual amount of bfp turbine a corrected extraction steam.
The above calculations are repeated for the b extraction if present. Otherwise, all outputs are set
to zero.
Calculate the total boiler feed turbine auxiliary steam heat rate deviation (rbfptdev) by summing
high pressure steam (rmnbfptdev), and turbine a extraction steam (rexbfptdeva) and turbine b
extraction steam (rexbfptdevb) deviations.
Calculate design boiler feedpump turbine supply steam flow depending on supply mode.
If (mixed steam)
wbfptdes = wmixbfptdes
wbfptdes = wexbfptdes
wbfptdes = whpbfptdes
SP_0030 603
9.151 Unhrauxdev
9.151 Unhrauxdev
The Unhrauxdev algorithm calculates the unit heat rate deviation for auxiliary power deviation and
the cost of the deviation.
UNHRAUXDEV
Analog Inputs
Analog Outputs
Constants
Unit Heat rate deviation in Btu/Kwh and cost of the deviation in $/Hr for auxiliary power deviation.
604 SP_0030
9.152 Unhrcbp
9.152 Unhrcbp
The Unhrcbp algorithm calculates the unit heat rate deviation for condenser back pressure and
the cost of the deviation in $/hr.
UNHRCBP
Analog Inputs
Digital Inputs
Analog Outputs
Digital Outputs
Constants
Compute the unit heat rate deviation in btu/kwh and the cost of the deviation in $/hr for condenser
back pressure.
SP_0030 605
9.153 Unhrcontot
9.153 Unhrcontot
The Unhrcontot algorithm computes the total unit heat rate deviations and cost of the deviation in
$/hr for the controllable parameters.
UNHRCONTOT
Analog Inputs
rmstdev main stm temp unit ht rt dev [Optional] Use if main steam temp unit
heat rate deviation is calculated.
rrstdev reheat stm temp unit ht rt dev [Optional] Use if reheat steam temp
unit heat rate deviation is calculated.
rmspdev mn stm pressure unit ht rt dev [Optional] Use if main steam pressure
unit heat rate deviation is calculated.
rssfdev supht spr flow unit ht rt dev [Optional] Use if superheat flow unit
heat rate deviation is calculated.
rrsfdev reht spr flow unit ht rt dev [Optional] Use if reheat spray flow unit
heat rate deviation is calculated.
regtdev exit gas temp dev ht rt dev [Optional] Use if exit gas temp unit
heat rate deviation is calculated.
Digital Inputs
Analog Outputs
Digital Outputs
Constants
606 SP_0030
9.153 Unhrcontot
Compute the total unit heat rate deviation in Btu/Kwh and the cost of the deviation in $/Hr for the
controllable parameters.
SP_0030 607
9.154 Unhrcsc
9.154 Unhrcsc
The Unhrcsc algorithm calculates the unit heat rate deviation for condenser subcooling and the
cost of the deviation in $/hr.
UNHRCSC
Analog Inputs
Digital Inputs
Analog Outputs
Digital Outputs
Constants
KTEMP = 5.0
Compute the unit heat rate deviation in Btu/Kwh and the cost of the deviation in $/Hr for
condenser subcooling.
608 SP_0030
9.155 Unhregt
9.155 Unhregt
The Unhregt algorithm calculates the heat rate deviation and the cost of deviation for exit gas
temperature.
UNHREGT
Analog Inputs
SP_0030 609
9.155 Unhregt
UNHREGT
Digital Inputs
Analog Outputs
Digital Outputs
Constants
610 SP_0030
9.155 Unhregt
The Unhregt algorithm calculates the heat rate deviation in btu/kwh and the cost of deviation in
$/hr for exit gas temperature.
Calculate the corrected design exit gas temperature as the sum of the corrected exit gas temp for
deviation from design air heater air inlet temperature and the corrected design exit gas
temperature from design air heater gas inlet temperature minus exit gas design temperature.
Calculate the modified exit gas temperature corrected for no leakage based on the corrected
design exit gas temperature.
Calculate the vapor enthalpy at the corrected modified design exit gas temperature and 1.0 psia
as follows:
hsstp(&hfgexs,&thtrmos,&onepsia,&ITRNGE);
Calculate the specific heat of the flue gas at the corrected modified design exit gas temperature.
Calculate the corrected heat loss in dry gas in percent attributable to the exit gas temperature
being off design.
Calculate corrected heat loss due to the moisture in fuel and hydrogen that are attributable to the
exit gas temperature being off design.
Calculate corrected heat loss due to moisture in the air supplied to the boiler from exit gas
temperature being off design.
Calculate the fractional boiler efficiency correction for exit gas temperature being off design.
Calculate the fractional change in unit heat rate for exit gas temperature being off design.
SP_0030 611
9.155 Unhregt
Calculate the heat rate deviation by multiplying the fractional correction factor by the design net
unit heat rate.
612 SP_0030
9.156 Unhrffw
9.156 Unhrffw
The Unhrffw algorithm calculates the heat rate deviation and the cost of deviation in $/hr for final
feedwater temperature.
UNHRFFW
Analog Inputs
Digital Inputs
Analog Outputs
Digital Outputs
Constants
KTEMP = 5.0
The Unhrffw algorithm calculates the heat rate deviation in Btu/Kwh and the cost of deviation in
$/Hr for final feedwater temperature.
ktfhttd = tfhttd
rffwdev = (Rfwcor / 100.0) * (ktfhttd / KTEMP) * rhrnetref
Dffwdhr = (rffwdev / RHTCNV) * Dcstbtu * Pennet
SP_0030 613
9.157 Unhrhpdev
9.157 Unhrhpdev
The Unhrhpdev algorithm calculates the unit heat rate deviation for hp turbine efficiency deviation
and the cost of the deviation.
UNHRHPDEV
Analog Inputs
Digital Inputs
Analog Outputs
Digital Outputs
Constants
614 SP_0030
9.157 Unhrhpdev
The Unhrhpdev algorithm calculates the unit heat rate deviation for HP turbine efficiency deviation
in Btu/Kwh and the cost of the deviation in $/Hr.
Compute the percent change in heat rate due to high pressure turbine efficiency deviation as
follows:
Compute the unit heat rate deviation in Btu/Kwh and cost of the deviation in $/Hr for HP turbine
efficiency deviation.
SP_0030 615
9.158 Unhripdev
9.158 Unhripdev
The Unhripdev algorithm calculates the unit heat rate deviation for ip turbine efficiency deviation
and the cost of the deviation.
UNHRIPDEV
Analog Inputs
Analog Outputs
Constants
616 SP_0030
9.159 Unhrmaintot
The Unhripdev algorithm calculates the unit heat rate deviation for IP turbine efficiency deviation
in Btu/Kwh and the cost of the deviation in $/Hr
Calculate the loss factor based on actual crossover pressure and actual reheat temperature using
interpolation.
Compute the unit heat rate deviation in Btu/Kwh and the cost of the deviation in $/Hr for IP turbine
efficiency deviation.
9.159 Unhrmaintot
The Unhrmaintot algorithm totals the unit heat rate deviations for the maintenance parameters
and the cost of the deviations in $/hr.
UNHRMAINTOT
Analog Inputs
rmkpdev mkup wtr dev ht rt corr fact [Optional] Use if makeup water dev
heat rate deviation is calculated.
rffwdev fin fw tmp dev ht rt corr fact [Optional] Use if final feedwater unit
heat rate deviation is calculated.
SP_0030 617
9.159 Unhrmaintot
UNHRMAINTOT
Analog Outputs
Constants
This algorithm totals the unit heat rate deviations for the maintenance parameters in Btu/Kwh and
the cost of the deviations in $/Hr.
Compute the total unit heat rate deviation in Btu/Kwh and cost of the deviation in $/Hr for the
maintenance parameters.
618 SP_0030
9.160 Unhrmisctot
9.160 Unhrmisctot
The Unhrmisctot algorithm totals the unit heat rate deviations for the miscellaneous parameters
and the cost of the deviations.
UNHRMISCTOT
Analog Inputs
rhpedev ht rt dev hp trb eff dev [Optional] Use if unit heat rate
for hp dev is calculated.
ripedev ip eff dev unit ht rt dev [Optional] Use if unit heat rate
for ip dev is calculated.
rlpedev lp eff dev unit ht rt dev [Optional] Use if unit heat rate
for lp dev is calculated.
rstsdev aux pwr dev ht rt dev [Optional] Use if unit heat rate
for aux pwr dev is calculated.
raitdev ht rt dev ahtr air in temp [Optional] Use if unit heat rate
for air htr air inlet temp dev is
calculated.
rauxstmdev aux pwr dev unit ht rt dev [Optional] Use if unit heat rate
for aux stm dev is calculated.
rphdev plant heat unit ht rt dev [Optional] Use if unit heat rate
for plant heating dev is
calculated.
Dcstbtu cost of heat rate dev REQUIRED
Analog Outputs
Constants
SP_0030 619
9.160 Unhrmisctot
This algorithm totals the unit heat rate deviations for the miscellaneous parameters in Btu/Kwh
and the cost of the deviations in $/Hr.
Compute the total unit heat rate deviation in Btu/Kwh and the cost of the deviation in $/Hr for the
miscellaneous parameters.
620 SP_0030
9.161 Unhrmkp
9.161 Unhrmkp
The Unhrmkp algorithm calculates the heat rate deviation and the cost of deviation in $/hr for
makeup water flow.
UNHRMKP
Analog Inputs
Analog Outputs
Constants
Unhrmkp calculates the heat rate deviation in Btu/Kwh and the cost of deviation in $/Hr for
makeup water flow.
Next, compute the percentage of design makeup water flow to throttle flow.
SP_0030 621
9.161 Unhrmkp
Compute heat rate deviation in Btu/Kwh and cost of the deviation in $/Hr for makeup water flow.
622 SP_0030
9.162 Unhrmsp
9.162 Unhrmsp
The Unhrmsp algorithm computes the unit heat rate deviation and cost of the deviation in $/hr for
main steam pressure.
UNHRMSP
Analog Inputs
Analog Outputs
Constants
Unhrmsp calculates the unit heat rate deviation for main steam pressure in Btu/Kwh and the cost
of the deviation in $/Hr.
SP_0030 623
9.163 Unhrmst
9.163 Unhrmst
The Unhrmst algorithm computes the unit heat rate deviation and cost of the deviation in $/hr for
main steam temperature.
UNHRMST
Analog Inputs
Analog Outputs
Constants
Unhrmst calculates the unit heat rate deviation for main steam temperature in Btu/Kwh and the
cost of the deviation in $/Hr.
624 SP_0030
9.164 Unhro2calc
9.164 Unhro2calc
The Unhro2calc algorithm calculates the heat rate deviation and the cost of deviation for exit
oxygen deviation.
UNHRO2CALC
Analog Inputs
Analog Outputs
SP_0030 625
9.164 Unhro2calc
UNHRO2CALC
Constants
Unhro2calc calculates the heat rate deviation in Btu/Kwh and the cost of deviation in $/Hr for
excess oxygen deviation. The following method calculates the heat rate deviation due to excess
oxygen deviation from design. The boiler losses associated with excess oxygen are recomputed
with design excess oxygen and the heat rate deviation in Btu/Kwh and cost of the deviation in
$/Hr are calculated.
This procedure is used when correction curves for excess oxygen are not available.
Compute the volume of free oxygen in the flue gases per lb of fuel in ft3/lb (ovs).
Calculate the weight of the design excess air (Warexs) based on volume of design oxygen in the
flue gases.
Compute the total mass of flue gas per lb of fuel (Wdgdes) based on design excess oxygen.
Calculate dry gas heat loss in Btu/Lb (hdgdes) based on design excess oxygen.
Compute dry heat loss deviation in Btu/Lb (hdev1) due to excess oxygen deviation - heat loss
difference between actual and design excess oxygen.
Calculate heat loss in moisture in air in Btu/Lb (hwvdes) based on design excess oxygen.
626 SP_0030
9.164 Unhro2calc
Compute moisture in air heat loss deviation in Btu/Lb (hdev2) due to excess oxygen deviation -
heat loss difference between actual and design excess oxygen.
Calculate the total losses in Btu/Lb (tloss) due to excess oxygen deviation.
Compute the fractional boiler efficiency correction (Fo2ble) for excess oxygen being off design.
Calculate the fractional change in unit heat rate (Fo2cor) for excess oxygen being off design.
Compute heat rate deviation in Btu/Kwh (ro2edev) and cost of the deviation in $/Hr (Do2edhr) for
the exit gas temperature being off design.
SP_0030 627
9.165 Unhrpcthr
9.165 Unhrpcthr
The Unhrpcthr algorithm calculates the percentage of actual main steam flow to valves wide open
throttle flow.
UNHRPCTHR
Analog Inputs
Analog Outputs
Digital Outputs
Constants
< NONE >
Calculate the ratio of percent of actual main steam flow to valves wide open throttle flow. 'wvwo' is
the valves wide open throttle flow.
628 SP_0030
9.166 Unhrrpd
9.166 Unhrrpd
The Unhrrpd algorithm calculates the unit heat rate deviation for reheat pressure drop and the
cost of the deviation.
UNHRRPD
Analog Inputs
Analog Outputs
Constants
< NONE >
Unhrrpd computes the unit heat rate deviation in Btu/Kwh and cost of the deviation in $/Hr for
reheat pressure drop.
SP_0030 629
9.167 Unhrrsf
9.167 Unhrrsf
The Unhrrsf algorithm calculates the heat rate deviation and the cost of deviation in $/hr for reheat
spray flow.
UNHRRSF
Analog Inputs
Constants
Unhrrsf calculates the heat rate deviation in Btu/Kwh and the cost of deviation in $/Hr for reheat
spray flow.
Compute heat rate deviation in Btu/Kwh and cost of the deviation in $/Hr for the actual reheat
spray water flow.
630 SP_0030
9.168 Unhrrst
9.168 Unhrrst
The Unhrrst algorithm calculates the heat rate deviation for reheat steam temperature and the
cost of the deviation in $/hr.
UNHRRST
Analog Inputs
Digital Inputs
Analog Outputs
Constants
Unhrrst computes the unit heat rate deviation in Btu/Kwh and cost of the deviation in $/Hr for
reheat steam temperature.
SP_0030 631
9.169 Unhrscah
9.169 Unhrscah
The Unhrscah algorithm calculates the heat rate deviation for the stm coil air htr and the cost of
the deviation.
UNHRSCAH
Analog Inputs
Digital Inputs
Analog Outputs
632 SP_0030
9.169 Unhrscah
UNHRSCAH
Digital Outputs
Constants
Unhrscah calculates the unit heat rate deviation for the Steam Coil Air Heater (SCAH) in Btu/Kwh
and the cost of the deviations in $/Hr
Calculate main steam, extraction steam SCAH supply steam heat rate deviations, and sum to
compute total SCAH auxiliary steam credit if SCAH supply steam is present.
Calculate relative weight main steam (Fmnscah) and extraction (Fexscah) SCAH steam supplies
Calculate main steam aux supply heat rate deviation by multiplying the difference between actual
and design main steam aux supply by the enthalpy difference between main steam aux supply
enthalpy and final feedwater enthalpy
SP_0030 633
9.169 Unhrscah
Calculate heat rate correction extraction SCAH supply steam from curve fit based on percent of
supply steam to throttle flow
Calculate % SCAH extraction (Rexscah) and design extraction (Rexscahdes) to throttle flow
Calculate correction at lower (Frefcor) and upper (Fupcor) flows in throttle flow segment. Force
throttle flow argument to be in range (wvwo50, wvwo).
If the throttle flow argument is in the 75% valves wide open throttle flow range,
Compute fractional correction for 1% aux extraction SCAH supply steam at actual % valves wide
open throttle flow by linear interpolation
Calculate heat rate deviation for the actual amount of aux extraction SCAH supply steam
Calculate steam coil air heater heat rate credit by adding main steam SCAH deviation
(rmnscahdev) and extraction steam SCAH deviation (rexscahdev)
If the steam coil air heater is not in service all of the parameters are set to zero.
634 SP_0030
9.170 Unhrssf
9.170 Unhrssf
The Unhrssf algorithm calculates the heat rate deviation and the cost of deviation in $/hr for
superheat spray flow.
UNHRRSF
Analog Inputs
Analog Outputs
Constants
The Unhrssf algorithm calculates the heat rate deviation in Btu/Kwh and the cost of deviation in
$/Hr for superheat spray flow.
SP_0030 635
9.170 Unhrssf
Compute heat rate deviation in Btu/Kwh and cost of the deviation in $/Hr for the actual superheat
spray water flow.
636 SP_0030
9.171 Unhrtot
9.171 Unhrtot
The Unhrtot algorithm compute the total unit heat rate deviation in Btu/kWh and the cost of the
deviation in $/hr for all parameters.
UNHRTOT
Analog Inputs
SP_0030 637
9.171 Unhrtot
UNHRTOT
Analog Outputs
Constants
Unhrtot computes the total unit heat rate deviation in Btu/Kwh and cost of the deviation in $/Hr for
all the parameters.
638 SP_0030
9.171 Unhrtot
Compute the total unaccounted unit heat rate deviation in Btu/Kwh and cost of the deviation in
$/Hr
SP_0030 639
9.172 Unhtrt
9.172 Unhtrt
The Unhtrt algorithm calculates the net unit heat rate of the plant as well as the gross and net unit
heat rate. The design gross and net unit heat rates are also calculated. Finally, the deviations for
the gross and net unit heat rates are calculated.
UNHTRT
Analog Inputs
Analog Outputs
Constants
640 SP_0030
9.172 Unhtrt
Unhtrt calculates the net unit heat rate of the plant as well as the gross net unit heat rate. The
design gross and net unit heat rates are also calculated. Finally, the deviations for the gross and
net unit heat rates are calculated.
Calculate gross unit heat rate in Btu/Kwh (rhrgrs) by dividing the heat created in the boiler by the
gross megawatts (Pmwatt) and dividing the result by the fractional heat loss boiler efficiency
(eblreff).
Compute net unit heat rate in Btu/Kwh (rhrnet) by dividing the heat created in the boiler by the net
megawatts (Pennet) and dividing the result by the fractional heat loss boiler efficiency (rblreff).
Compute design gross unit heat rate in Btu/Kwh (rhrgrsref) based on design turbine cycle heat
rate.
Calculate design net unit heat rate in Btu/Kwh (rhrnetref) based on the design turbine cycle heat
rate.
Compute gross unit heat rate deviation in Btu/Kwh (rgrsdev) as the difference between the actual
(rhrgrs) and design gross (rhrgrsref) unit heat rates.
Compute net unit heat rate deviation (heat loss) in Btu/Kwh (rnetdev) as the difference between
the actual (rhrnet) and design net (rhrnetref) unit heat rates.
SP_0030 641
9.173 Volflowgas
VOLFLOWGAS
Analog Inputs
Analog Outputs
Digital Outputs
Constants
Volflowgas converts a mass gas flow in kilopounds per hour to a volumetric flow in 1000 cubic
feet per minute.
Where:
KLBtoLB = 1000lb/klb
MIN_TO_HOUR = 60 min/hour
642 SP_0030
9.174 Volflowliquid
VOLFLOWLIQUID
Analog Inputs
Digital Inputs
Analog Outputs
Digital Outputs
Constants
SP_0030 643
9.174 Volflowliquid
The Volflowliquid algorithm converts a liquid mass flow in kilopounds per hour to a volumetric flow
in gallon per minute.
To determine if the point defined by pressure and temperature (pressinlet, tempinlet) is in the
saturated or compressed liquid region, calculate the saturation pressure (pabssat) at temperature
(tempinlet). If the pressure (pressinlet) is greater than the saturation pressure, the point is in the
compressed liquid region. Specific volume (vinlet) is calculated as a compressed liquid function
(vcltp) of pressure (pressinlet) and temperature (tempinlet).
Then:
Otherwise, the point is in the saturated liquid region. Specific volume is calculated as a saturated
liquid function (vslt) of temperature. Then:
The density of the liquid (dinlet) is the inverse of specific volume. Then:
dinlet = 1.0/vinlet
Specific gravity (Sspecgrav) is the ratio of the density to the density of water at 60 degrees F
(DWATER = 62.3/.lb ft3) or dinlet divided by the amount of water.
Sspecgrav = dinlet/DWATER
Where:
644 SP_0030
9.175 Wexpan
9.175 Wexpan
The Wexpan algorithm computes used energy end point, expansion line end point, low pres
turbine last stage extraction flow and enthalpy, and last stage heater extraction flow and enthalpy
for Westinghouse steam turbo-generators in an iterative procedure using the GER2007C
expansion line equations and the Siemens Westinghouse recommendation that the line is
straight.
WEXPAN
Analog Inputs
SP_0030 645
9.175 Wexpan
WEXPAN
646 SP_0030
9.175 Wexpan
WEXPAN
SP_0030 647
9.175 Wexpan
WEXPAN
Constants
hdelta 25.0
WVSEG0 110.0
WVSEG1 160.0
WVSEG2 260.0
WVSEG3 360.0
WVSEG4 520.0
WVSEG5 520.0
lpturbends 4.0
exloss1 [4] 57.958544, -1.3774511, 0.012635167, -4.0471311e-05
exloss2 [4] 17.419598, -0.25917085, 0.0013693467, 0.0
exloss3 [4] -18.55, 0.1630571, 0.00013392857, 0.0
exloss4 [4] -169.65873, 1.5955026, -0.0041911683, 4.0509259e-06
exloss5 [4] -90.905844, 0.73675144, -0.0012391775, 7.8914141e-07
exloss6 [4] -90.905844, 0.73675144, -0.0012391775, 7.8914141e-07
648 SP_0030
9.175 Wexpan
The Wexpan algorithm calculates the extraction, drain, outlet and inlet flows for the lp parallel
heaters, (if there are any), based on whether the heaters are in service or not in service.
zerrflag = 0;
Set expansion line curvature constant (khzero) to 1500 to designate a straight line
khzero = 1500.0;
Calculate average condenser back pressure (pacnprs). this is low pressure turbine exhaust
pressure. Convert to psia.
Calculate dry specific volume at exhaust pressure of each low pressure turbine
vdrylp = vsvp(pacnabslp);
vdryhp = vsvp(pacnabshp);
Calculate steam flow to lp turbine last stage by subtracting lp turbine extractions from crossover
flow (witrex)
Calculate heat acquired by steam (qsttot) by calculating a steam heat balance around the turbine
Calculate heat in turbine extractions, excluding lp turbine last stage, by summing the product of
flow and enthalpy for each turbine stage extraction
Calculate heat flow to glands - the total heat supplied to the steam seal regulator & gland steam
condenser minus lp gland supply.
SP_0030 649
9.175 Wexpan
if (zlpheater > 0)
Heater in-service, extraction steam superheated. Otherwise, the steam is wet. Calculate
degrees superheat (tshtlphtr) as the difference between the measured heater extraction steam
temp (textrlphtr) and the heater saturation temp (tsatlphtr) and test for superheated steam.
Superheated steam. calculate enthalpy directly as function of temp and absolute pressure
hextrlphtr = hsstp(textrlphtr, pabsextrlphtr);
else
hextrlphtr = hsvp(pabsextrlphtr);
hwtstm = 10000.0;
If flash tank present (flag zflashdrain set true) updteam heater drain goes to flash tank, and lp
heater inlet drain flow argument is set to zero. If a flash tank is not present, the inlet drain flow
argument is set to the upstream drain flow (wdrnoutup). The flash steam flow argument is
zeroed if a flash tank is not present.
if (zflashdrain > 0)
wflashin = wflashsteam;
else
wdrainin = wdrnoutup;
Start of overall iterative loop. If lp heater in service both the heater extraction enthalpy (hextrlphtr)
and estimated enthapy (hnew) are recalculated during the iterative procedure. Iterate until the
absolute difference between hfhelphtr and hnew is <= 0.1 btu/lb, or the number of iterations is
exceeded. Zero overall iteration counter.
kcntlphtr = 0.0;
while ((fabs(hextrlphtr - hwtstm) > 0.1) && (kcntlphtr <= 30))
if (zlpheater > 0)
Heater in service, calculate lp heater and lp turbine last stage extraction flow and enthalpy.
Update current estimate of lp heater extraction enthalpy.
hwtstm = hextrlphtr;
650 SP_0030
9.175 Wexpan
Low pressure heater drain pump present and in service if flag zlpdrainpump set
if (zlpdrainpump > 0)
Drain pump present and in service. Low pressure heater drain pumped forward into condensate
before upstream heater. Calculate extraction steam flow at heater shell (wextrlphtr) by
performing a heat balance.
pumped forward (wdrnoutlplphtr) from condensate flow (wcndea). Set heater inlet flow to outlet
flow
else
Heater drain flows to condenser hotwell. Flow through heater is condensate flow to deaerator
(wcndea).
Calculate extraction flow at heater shell from heat balance, and calculate drain flow.
Set condensate flows into and out of heater to condensate flow to deaerator.
wfhoutlphtr = wcndea;
wfhinlphtr = wcndea;
wturblaststg = wextrlphtr;
hturblaststg = hextrlphtr;
lp turbine last stage extraction flow (wturblaststg) from steam flow to last stage (wstmlaststg).
SP_0030 651
9.175 Wexpan
Calculate used energy end point (low pressure turbine exhaust enthalpy) by conducting a thermal
and electrical energy balance around the whole turbine to establish the net heat flow to the
condenser and the dividing by the net steam flow to the condenser which is the low pressure
turbine exhaust flow.
Net heat flow to the condenser comprised of the following elements - net heat acquired by both
superheated and reheated steam supplied to turbine (qsttot)
Total heat in turbine stage extractions (qext) by summing the heat in previous extractions
(sumext) to the heat in the number 7 extraction
Calculate net heat in low pressure turbine exhaust (qexhst) by subtracting heat in turbine stage
extractions (qext), heat flow to glands (qleaks) and generation energy (qgen) from net heat
acquired (qsttot).
Calculate low pressure turbine exhaust enthalpy (hltrex) by dividing net heat in exhaust (qexhst)
by exhaust steam flow (wltrex). Set used energy end point (ueep) to exhaust enthalpy (hltrex).
this is average used energy end point of both low turbines.
The exhaust loss and expansion line end point are calculated by an iterative procedure because
the moisture at the expansion line end point has to be known to calculate exhaust loss. Once the
expansion line end point has converged, an expansion is projected from the expansion line point
to the stauration line. The lp turbine last stage extraction enthalpy is initially assumed to be
saturated, and is calculated using an expansion line swing method.
Calculate initial expansion line end point estimate (helepes) by subtracting constant enthalpy drop
(hdelta = 25 btu/lb) from used energy end point (hueep)
Calculate expansion line end point (helepe) by iterative procedure until elep and estimated elep
(helepes) within 0.1 btu/lb. do not exceed 30 ierations.
helepe = 10000.0;
kcount = 0;
Increment number iterations. reset estimated elep (helepe) to new calculated value (helepes)
652 SP_0030
9.175 Wexpan
Calculate quality of the steam (qltrex) at estimated expansion line end point (helepe) and average
turbine exhaust pressure (pacnabs)
Calculate low pressure exhaust hood specific volume of exhaust steam (vcnprslp) by multiplying
dry specific volume (vdrylp) by the moisture factor
Calculate lp hood exhaust loss per end. assume total exhaust loss equally divide between lp and
hp hoods. there are lpturbends / 2 per hood.
Calculate lp hood exhaust loss (hexlsslp) as function of lp hood exhaust vol flow per end
(wvolexhstlp) based on Westinghouse exhaust loss curve.
else
else
else
else
else
SP_0030 653
9.175 Wexpan
Calculate high pressure exhaust hood specific volume of exhaust steam (vcnprshp) by multiplying
dry specific volume (vdryhp) by the moisture factor
Calculate hp hood exhaust loss per end. assume total exhaust loss equally divided between lp
and hp hoods. there are lpturbends / 2 per hood.
Calculate hp hood exhaust loss (hexlsshp) as function of hp hood exhaust vol flow per end
(wvolexhsthp) based on Westinghouse exhaust loss curve
else
else
else
else
else
Calculate new expansion line endpoint (elepes) as function used energy end point (ueep),
exhaust loss (hexlss) and percent moisture (Rmstrex) per Westinghouse definition
654 SP_0030
9.175 Wexpan
Set expansion line end point (helep) to final calculated estimate (helepes), set error flag (errflg) if
no convergence. This is average expansion line end point for both low pressure turbines.
helep = helepes;
Calculate entropy, enthalpy coordinates on the expansion line in the wet region at the last stage
extraction pres (pabsturblaststg) using expansion line equation in GER2007C. the lp heater, last
stage extraction, low pressure turbine exhaust flow, used energy end point and expansion line
end point calculations are repeated using the new lp heater extraction enthalpy until the estimated
and calculated extraction enthalpies agree within 0.1 btu/lb.
Calculate the entropy (selep) at the calculate expansion line end point (helep) and turbine exhaust
pressure (pacnabs).
Calculate the GER2007C rzero term. first calculate required exponent (krzexpn).khzero is
expansion line curvature constant.
For first pass assume initial estimate (hnew) of last stage extraction enthalpy is saturated steam
function of extraction pressure (pabsturblaststg)
hnew = hsvp(pabsturblaststg);
hest = hnew;
Calculate entropy (sest) at estimated extraction enthalpy (hest) and last stage extraction pressure
(pabsturblaststg). Test for error condition if subccooled enthalpy return. In this case, set error flag
and exit the function.
zerrflag = 1;
break;
else
sest = stemp;
SP_0030 655
9.175 Wexpan
Calculate new last stage extraction enthalpy (hnew) by adding the product of the expansion line
curvature (hzero) times the difference between the expansion line entropy (sxline) and estimated
last stage extraction entropy (sest) to the current estimated extraction enthalpy (hest)
Convergence. Calculate overall iterative loop result - heater 7 extraction enthalpy (hextrlp) and
number 7 extraction enthalpy (hturb7) - to the converged value hnew
hextrlphtr = hnew;
hturblaststg = hnew;
zerrflag = 1;
For parallel heaters calculate a,b parameters. we are assuming the total last stage extraction flow
is equally divided between the two heaters.
if (zlpparallel > 0)
656 SP_0030
9.176 Wmncor
9.176 Wmncor
The Wmncor algorithm calculates the deviation between corrected and reference throttle flows.
WMNCOR
Analog Inputs
Analog Outputs
Constants
Corrected throttle steam flow is calculated by multiplying the calculated throttle flow (wmnstm) by
the calculated throttle flow correction factor (kfact). Then
SP_0030 657
S E C T I O N 10
Steamtable algorithms
IN THIS SECTION
SP_0030 659
10.1 CLTEST
10.1 CLTEST
The CLTEST algorithm calculates an enthalpy based on temperature and/or pressure. This
algorithm checks to see if the compressed liquid steam table or the saturated liquid steam table
should be called. The enthalpy is calculated accordingly.
CLTEST
Analog Inputs
Analog Outputs
Constants
660 SP_0030
10.2 Hclsp
10.2 Hclsp
Hclsp calculates compressed liquid enthalpy given entropy and absolute pressure.
HCLSP
Analog Inputs
Analog Outputs
Constants
SP_0030 661
10.3 Hclsp_chk
10.3 Hclsp_chk
Hclsp_chk checks input value and if above limit call steam table.
HCLSP_CHK
Analog Inputs
Analog Outputs
Constants
662 SP_0030
10.4 Hcltp
10.4 Hcltp
Hcltp calculates compressed liquid enthalpy given temperature and absolute pressure.
HCLTP
Analog Inputs
Digital Inputs
Analog Outputs
Digital Outputs
Constants
SP_0030 663
10.5 Hcltp_chk
10.5 Hcltp_chk
If input value above limit, call hcltp. Otherwise, set the enthalpy to 0.
HCLTP_CHK
Analog Inputs
Digital Inputs
Analog Outputs
Digital Outputs
Constants
kclimit = 0.0
664 SP_0030
10.6 Hichpp
10.6 Hichpp
Hichpp calculates enthalpy of the outlet of an isentropic process given inlet pressure, exit
absolute pressures and inlet enthalpy in compressed liquid region.
HICHPP
Analog Inputs
Digital Inputs
Analog Outputs
Digital Outputs
Constants
SP_0030 665
10.7 Hichpp_chk
10.7 Hichpp_chk
HICHPP_CHK
Analog Inputs
Digital Inputs
Analog Outputs
Digital Outputs
Constants
kclimit = 0.0
666 SP_0030
10.8 Hictpp
10.8 Hictpp
Hictpp calculates enthalpy of isentropic rise from conditions t1, p1 to pressure p2 in compressed
liquid region.
HICTPP
Analog Inputs
Digital Inputs
Analog Outputs
Digital Outputs
Constants
SP_0030 667
10.9 Hishpp
10.9 Hishpp
Hishpp calculates enthalpy of outlet of an isentropic process given inlet pressure, exit absolute
pressure and inlet enthalpy in superheated or wet steam regions.
HISHPP
Analog Inputs
Digital Inputs
Analog Outputs
Digital Outputs
Constants
668 SP_0030
10.10 Histpp
10.10 Histpp
Histpp calculates enthalpy of an isentropic drop from conditions t1, p1, down to pressure p2.
HISTPP
Analog Inputs
Digital Inputs
Analog Outputs
Digital Outputs
Constants
SP_0030 669
10.11 Hslp
10.11 Hslp
HSLP
Analog Inputs
Digital Inputs
Analog Outputs
Digital Outputs
Constants
670 SP_0030
10.12 Hslp_chk
10.12 Hslp_chk
HSLP_CHK
Analog Inputs
Digital Inputs
Analog Outputs
Digital Outputs
Constants
kclimit = 0.0
SP_0030 671
10.13 Hslt
10.13 Hslt
HSLT
Analog Inputs
Digital Inputs
Analog Outputs
Digital Outputs
Constants
672 SP_0030
10.14 Hslt_chk
10.14 Hslt_chk
HSLT_CHK
Analog Inputs
Digital Inputs
Analog Outputs
Digital Outputs
Constants
kclimit = 0.0
SP_0030 673
10.15 Hsstp
10.15 Hsstp
Hsstp calculates superheated steam enthalpy, given temperature and absolute pressure.
HSSTP
Analog Inputs
Digital Inputs
Analog Outputs
Digital Outputs
Constants
674 SP_0030
10.16 Hsstp_chk
10.16 Hsstp_chk
If input value above limit, call hsstp. Otherwise, set the enthalpy to 0.
HSSTP_CHK
Analog Inputs
Digital Inputs
Analog Outputs
Digital Outputs
Constants
kclimit = 0.0
SP_0030 675
10.17 Hsvp
10.17 Hsvp
HSVP
Analog Inputs
Digital Inputs
Analog Outputs
Digital Outputs
Constants
676 SP_0030
10.18 Hswsp
10.18 Hsw sp
Hswsp calculates steam enthalpy, given entropy and absolute pressure of superheated or wet
steam.
HSWSP
Analog Inputs
Digital Inputs
Analog Outputs
Digital Outputs
Constants
SP_0030 677
10.19 Pslt
10.19 Pslt
PSLT
Analog Inputs
Digital Inputs
Analog Outputs
Digital Outputs
Constants
678 SP_0030
10.20 Psvs
10.20 Psvs
PSVS
Analog Inputs
Digital Inputs
Analog Outputs
Digital Outputs
Constants
SP_0030 679
10.21 Sclhp
10.21 Sclhp
Sclhp calculate compressed liquid entropy, given enthalpy and absolute pressure.
SCLHP
Analog Inputs
Digital Inputs
Analog Outputs
Digital Outputs
Constants
680 SP_0030
10.22 Scltp
10.22 Scltp
Scltp calculates compressed liquid entropy, given temperature and absolute pressure.
SCLTP
Analog Inputs
Digital Inputs
Analog Outputs
Digital Outputs
Constants
SP_0030 681
10.23 Sslp
10.23 Sslp
SSLP
Analog Inputs
Digital Inputs
Analog Outputs
Digital Outputs
Constants
682 SP_0030
10.24 Sslt
10.24 Sslt
SSLT
Analog Inputs
Digital Inputs
Analog Outputs
Digital Outputs
Constants
SP_0030 683
10.25 Ssstp
10.25 Ssstp
Ssstp calculates superheated steam entropy, given temperature and absolute pressure.
SSSTP
Analog Inputs
Digital Inputs
Analog Outputs
Digital Outputs
Constants
684 SP_0030
10.26 Ssvp
10.26 Ssvp
SSVP
Analog Inputs
Digital Inputs
Analog Outputs
Digital Outputs
Constants
SP_0030 685
10.27 Sswhp
10.27 Ssw hp
Sswhp calculates steam entropy, given enthalpy and absolute pressure of superheated or wet
steam.
SSWHP
Analog Inputs
Digital Inputs
Analog Outputs
Digital Outputs
Constants
686 SP_0030
10.28 Tclhp
10.28 Tclhp
Tclhp calculates compressed liquid temperature given enthalpy and absolute pressure.
TCLHP
Analog Inputs
Digital Inputs
Analog Outputs
Digital Outputs
Constants
SP_0030 687
10.29 Tslp
10.29 Tslp
TSLP
Analog Inputs
Digital Inputs
Analog Outputs
Digital Outputs
Constants
688 SP_0030
10.30 Tslqh
10.30 Tslqh
TSLQH
Analog Inputs
Digital Inputs
Analog Outputs
Digital Outputs
Constants
SP_0030 689
10.31 Tswhp
10.31 Tsw hp
Tswhp calculates steam temperature, given entropy and absolute pressure of superheated or wet
steam.
TSWHP
Analog Inputs
Digital Inputs
Analog Outputs
Digital Outputs
Constants
690 SP_0030
10.32 Tswsp
10.32 Tsw sp
Tswsp calculates steam temperature, given entropy and absolute pressure of superheated or wet
steam.
TSWSP
Analog Inputs
Digital Inputs
Analog Outputs
Digital Outputs
Constants
SP_0030 691
10.33 Vcltp
10.33 Vcltp
Vcltp calculates compressed liquid specific volume, given temperature and absolute pressure.
VCLTP
Analog Inputs
Digital Inputs
Analog Outputs
Digital Outputs
Constants
692 SP_0030
10.34 Vslt
10.34 Vslt
VSLT
Analog Inputs
Digital Inputs
Analog Outputs
Digital Outputs
Constants
SP_0030 693
10.35 Vsstp
10.35 Vsstp
Vsstp calculates superheated steam specific volume, given temperature and absolute pressure.
VSSTP
Analog Inputs
Digital Inputs
Analog Outputs
Digital Outputs
Constants
694 SP_0030
10.36 Vsvp
10.36 Vsvp
VSVP
Analog Inputs
Digital Inputs
Analog Outputs
Digital Outputs
Constants
SP_0030 695
10.37 Vswhp
10.37 Vsw hp
Vswhp calculates steam specific volume, given enthalpy and absolute pressure of superheated or
wet steam.
VSWHP
Analog Inputs
Digital Inputs
Analog Outputs
Digital Outputs
Constants
696 SP_0030
10.38 Vswsp
10.38 Vsw sp
Vswsp calculates steam specific volume, given entropy and absolute pressure of superheated or
wet steam.
VSWSP
Analog Inputs
Digital Inputs
Analog Outputs
Digital Outputs
Constants
SP_0030 697
10.39 Xswsp
10.39 Xsw sp
Xswsp calculates steam quality, given entropy and absolute pressure of superheated or wet
steam.
XSWSP
Analog Inputs
Digital Inputs
Analog Outputs
Digital Outputs
Constants
698 SP_0030
10.40 Xswhp
10.40 Xsw hp
Xswhp calculates steam quality, given entropy and absolute pressure of superheated or wet
steam.
XSWHP
Analog Intputs
Digital Inputs
Analog Outputs
Digital Outputs
Constants
SP_0030 699
S E C T I O N 11
IN THIS SECTION
The GPA package collects data through input functional block diagrams. This functional block
diagram should contain the input algorithms (analog and digital) as well as the FBD ordering
algorithm.
After the INPUT DOCUMENT is created, tab over to the W INPUT algorithm tab. This group
contains the Analoginavg, Digitalin and FBDorder algorithms:
Analoginavg algorithm inputs data agent server analog values and outputs local GPA
averaged analog values.
Digitalin algorithm inputs data agent server digital values and outputs local GPA digital
values.
FBDorder algorithm orders functional block diagrams.
SP_0030 701
11.1 Input functional block diagram
11.1.1 Analoginavg
The Analoginavg algorithm Configuration tab allows the averaged period as well as the type of
average and percentages of samples to be changed. The name can also be changed to
accommodate multiple Analoginavg algorithms.
The Analoginavg algorithm and the Digitalin algorithm(s) should be the first algorithms configured.
No other algorithms can be created until the algorithm's input points exist.
The TAGS tab allows the points to be created/configured/listed. To create tags, choose
create/configure tags. The next screen will allow the you to define a new set, list the current sets
already defined, choose default units and the data agent server name and node.
On the define tag screen, select a point, check the configure box and fill in the point information.
After completing the information, select Update List. Continue configuring all the analog inputs
needed.
If more analog inputs are needed than contained in the Analoginavg algorithm, a second
Analoginavg algorithm can be dropped and configured.
The Digitalin algorithm CONFIGURATION tab does not contain any average information. Only the
analoginavg algorithms contain this information. The name and description fields can be modified
on this screen.
Note: Output points are automatically updated from the input list. Therefore, nothing needs to
be done with output points. After configuring all the analog inputs, select the Save or Save as
button.
11.1.2 Digitalin
The Digitalin algorithm TAGS tab allows the points to be created/configured/listed. After choosing
the create/configure tags, select the default units as well as the data agent server name and
node.
On the define tags screen, select a point, check the configure box and fill in the point information.
After completing the information, select Update List. Continue configuring all the digital inputs
needed.
Note: Output points are automatically updated from the input list. Therefore, nothing needs to
be done with output points. After configuring all the analog inputs, select the Save or Save as
button.
If more digital inputs are needed than contained in the Digitalin algorithm, a second Digitalin
algorithm can be dropped and configured.
11.1.3 FBDorder
The FBDorder algorithm only needs the Design Info configured. After adding a functional block
diagram, the FBDorder algorithm Design Info tab needs to be updated.
Note: The FBDorder algorithm must be put on the very first document.
702 SP_0030
11.2 Main functional block diagram
The main functional block diagram contains calculations concerning the entire plant, such as:
Any other calculations, such as averages, pertaining to the entire plant should also be done on
this FBD.
Chkload - is the check load algorithm. (Chkload) checks the load and will set the flag for the GPA
package to run if the load is above the user-specified load.
Patmos - is the atmospheric pressure algorithm. (Patmos) calculates the atmospheric pressure
according to the barometric pressure.
Hwblrstm - is the boiler steam enthalpy and flow algorithm. (Hwblrstm) calculates the boiler
steam flow and enthalpy. The flow is calculated according to any flows added and subtracted from
the boiler steam flow. These flows are selected from the design screen. The enthalpy is
calculated from a steam table call using the temperature and pressure.
Hwmnstm - is the main steam enthalpy and flow algorithm. (Hwmnstm) calculates the main
steam flow and enthalpy. The flow is calculated according to any flows added and subtracted from
the main steam flow. Select these flows from the design screen. The enthalpy is calculated from a
steam table call using the temperature and pressure.
The rated main steam temperature and pressure are calculated as a curve fit. The curve fit
algorithms can be found in the W Curves algorithm section.
P1stg - is the first stage pressure algorithm. (P1stg) calculates a correction factor, absolute first
stage pressure, rated absolute pressure and corrected first stage pressure.
The reference main steam flow is calculated from a curve fit. The curve fit algorithms can be
found in the W Curves algorithm section.
Wmncor - is the main steam corrected flow and deviation algorithm. (Wmncor) calculates the
main steam corrected flow and the deviation from the reference main steam flow.
SP_0030 703
11.3 Main input algorithm checklist
Chkload algorithm must be used first after the analoginavg and digital algorithms. This algorithm
sets the digital flag zdocalc, which allows all other algorithms to execute.
The feedheater functional block diagram document contains the feedheater algorithm, as well as
any curve fits needed for the design terminal temperature differences and design drain cooler
approaches.
FEEDHEATER ALGORITHMS
Hpfedhtr - This is the hp feedheater algorithm. (Hpfedhtr) calculates a heat and materials
balance around a shell and tube type heat exchanger. Extraction and drain flows are calculated.
Turbine extraction flow and enthalpy are also calculated. This algorithm does not account for
drains pumped forward.
Feedheater number.
In-service logic - digital signal or feedheater temperature rise.
Out-of-service logic - cascading drain flow to condenser or another feedheater.
Extraction temperature and pressure measurement locations.
Leakage existence and the location.
Auxiliary leakage split from extraction flow existence.
Lpfedhtr - This is the lp feedheater algorithm. (Lpfedhtr) calculates a heat and materials balance
around a low pressure shell and tube type heat exchanger. The extraction and drain flows are
calculated for the feedheater.
The turbine extraction flow and enthalpy are also calculated. This algorithm does not account for
drains pumped forward.
Feedheater number
In-service logic - digital signal or feedheater temperature rise
Out-of-service logic - cascading drain flow to condenser or another feedheater and SSR
overflow diverted existence
Extraction temperature and pressure measurement locations
Leakage existence and the location
Auxiliary leakage split from extraction flow existence
704 SP_0030
11.4 Equipment functional block diagrams
Deaerator - This algorithm calculates the condensate inlet flow, outlet flow, inlet enthalpy and
outlet enthalpy for a direct contact heat exchanger. The extraction steam flow and enthalpy are
also calculated.
Drnpmp - This algorithm calculates condensate inlet flow, outlet flow, inlet enthalpy and outlet
enthalpy for a direct contact heat exchanger. The extraction steam flow and enthalpy are also
calculated. Turbine extraction flow and enthalpy are also calculated. This algorithm accounts for
drains pumped forward. The design information needed is the same as lpfedhtr.
Drnclr - This is the drain cooler approach algorithm, (drnclr) calculates drain cooler approach and
deviation. The design drain cooler approach for a particular feedheater has to be calculated by a
curve fit algorithm before the drain cooler approach algorithm for this feedheater is placed on the
document.
ttd - This is the terminal temperature difference algorithm (ttd) calculates the terminal temperature
difference and deviation. The design terminal temperature difference for a particular feedheater
has to be calculated by a curve fit algorithm before the terminal temperature difference algorithm
for this feedheater is placed on the document.
The condenser functional block diagram contains the algorithms for condenser performance.
These include the condenser design, condenser average temperature, and the condenser
algorithm.
Cnddesign - The condenser design algorithm reads in the condenser design information. The
design information along with the length, outer diameter, bwg, condenser material correction
factor and thickness are all assigned to output points. The inner diameter is also calculated for the
compartment(s).
Cndavgtemp - The condenser average temperature algorithm calculates the condenser average
inlet and outlet temperature as well as the average circulating water temperature.
Condsr - The condenser algorithm determines the method for out-of-service compartments. After
checking for out-of-service compartments, the specific heat, specific volume and specific gravity
of circulating water are calculated. Next, the condenser duty, the condenser circulating water flow,
the actual and design heat transfer, the cleanliness factor, expected back pressure with clean
tubes and the back pressure deviation are calculated. The calculations are done in accordance
with ASME Power Test Code PTC 12.2 (1983) and heat exchange Institute Standards for Steam
Surface Condensers, Ninth edition.
SP_0030 705
11.4 Equipment functional block diagrams
The steam turbine functional block diagram document contains the generator-related algorithm
and the turbine stage efficiency algorithms.
for Alstsom steam turbogenerators in an iterative procedure using the GER2007C expansion
line equations. Assume the expansion line is straight.
Expelep - This function computes expected expansion line end point if design curve is not
provided. Refer to the procedure specified in Spenser, Cotton, Cannon paper "A Method for
Predicting the Performance of Steam Turbine Generators, 16,500 KW and Larger" (GER2007C).
Ge_stg - This module computes the following for GE steam turbine generators:
Gencorr - This function computes corrected steam turbine generator output based on correction
curves provided by turbine manufacturer.
generator mva
generator power factor
auxiliary power
ratio of auxiliary power to gross power
total shaft power and generator efficiency
Variable generator losses need to be calculated before this algorithm by a curve fit.
Next, any flows and leakages associated with the high-pressure stage need to be calculated by
using W Curves algorithms and W Math algorithms. After these are calculated, the high-pressure
design efficiency needs to be calculated by a curve fit algorithm. Finally, the turbine algorithm
should be used for the hp stage.
Ipturbdeseff - This function calculates design (or expected) intermediate pressure turbine
efficiency using the method outlined in chapter 4, section iii.a.1, in K.C. Cotton's Evaluating and
Improving Steam Turbine Performance. the function calculates the expected efficiency from the
inlet bowl conditions to the turbine exhaust. the calculated expected efficiency is then corrected to
compute the expected efficiency from the turbine inlet conditions to the measured crossover
conditions.
706 SP_0030
11.4 Equipment functional block diagrams
lp turbine outlet enthalpy by conducting a thermal and energy balance around the whole
turbine
lp isentropic enthalpy
lp turbine efficiency
Overall_trb - This module calculates the turbine inlet enthalpy, the isentropic enthalpy and the
overall turbine efficiency.
Reheat_trb - This module calculates the reheat turbine efficiency, the reheat design efficiency
and the reheat turbine efficiency deviation.
Turbgen - This function computes heat generated and percent load produced by each turbine
section.
The calculations for the intermediate pressure stage are done the same as the high-pressure
stage. Flows and leakages associated with the intermediate pressure stage are calculated and
then the turbine algorithm should be used for the intermediate stage.
The low pressure stage efficiency is calculated by summing the total heat and dividing by the total
flow. The mixer algorithm can be used to calculate the total heat. Next, the design low pressure
efficiency is calculated by a curve fit and the low pressure efficiency deviation is calculated using
a subtraction algorithm.
Lastly, the stage(s) used energy and the condenser vapor enthalpy are calculated.
SP_0030 707
11.4 Equipment functional block diagrams
The boiler functional block diagram contains the fuels, modified air heater temperature, boiler,
corrected boiler efficiency and air heater algorithms. The design boiler efficiency, design excess
air and design air heater air inlet temperature also needs to be calculated on this document.
Fuels - The fuels algorithm is under the W Fuel tab and performs a fuel analysis on the total
fuel(s) used. This algorithm requires design information.
Boiler - The boiler algorithm calculates the boiler efficiency by the heat loss method. Before this
algorithm is used, the design boiler efficiency, design excess air and design air heater air inlet
temperature need to be calculated by a curve fit.
Corblrloss - The corrected boiler efficiency calculates the corrected boiler efficiency and
deviation.
Airhtr - The air heater algorithm monitors the performance of the air heater. It computes the
x-ratio, the air side efficiency and the gas side efficiency.
The fan functional block diagram contains the fan design, the density correction, design discharge
pressure, design horsepower, design fan motor efficiency (if available) and the fan algorithm. The
fan airflow is expected to be in volumetric units. If the airflow is not in volumetric units, the
Volflowgas algorithm under the W Misc tab can be used to change the mass flow into a volumetric
flow.
Densityair - This module computes the air density at current temperature and pressure
conditions as well as a density correction factor.
Densitycor - This module computes a density corrected to current temperature and pressure
conditions as well as a density correction factor.
Densitygas - This module computes gas density as well as a density correction factor.
Fan - The fan algorithm is found under the W Fan tab and calculates the fan efficiency, design fan
efficiency and the fan efficiency deviation.
Fandesign - The fan design algorithm is under the W Fan tab and reads the fan design
information. The information required is fan discharge area, reference temperature and pressure
for fan curves, fan characteristic curve reference density, design fan motor efficiency existence
and the type of in-service logic used - digital signal or minimum air flow.
Fanvelocity - This module computes the velocity pressure of the fan using the volumetric flow,
density and area.
708 SP_0030
11.4 Equipment functional block diagrams
The pump functional block diagram contains the pump design efficiency, the pump design head,
the pump motor design efficiency (if available) and the pump algorithm.
The pump design efficiency, the pump design head and the pump motor design efficiency (if
available) are calculated by curve fits.
Pump - The pump algorithm is under the W Pump tab and calculates the actual efficiency, design
efficiency and efficiency deviation for a pump. Design information is required for this algorithm.
The pump suction and discharge inner diameter and suction heads as well as in-service logic,
design pump motor efficiency existence, constant speed existence and for boiler feedpumps only
- suction pressure measurement existence.
Bfptrb - Boiler feed pump turbine algorithm to calculate performance of feed pump turbine that
can be supplied by
Mixed supply steam and isentropic enthalpies are computed. Boiler feed pump turbine exhaust
steam enthalpy is computed by a heat balance comparing the heat in the steam to the work done
on the water by the boiler feed pump, i.e. the water horsepower. Turbine efficiency is computed
and compared to design efficiency.
PUMP2STG - calculates pump performance for a pump which has an extraction or discharge
between two stages of the pump. If available, expected heads for individual stages are
calculated and compared to actual.
Total expected head and actual total head can also be calculated and a deviation reported.
Pump efficiency, efficiency deviation, and percent head deviations are also calculated.
PUMP1SPD - calculates pump performance for a pump which runs at constant speed. Expected
head, actual head, pump efficiency, efficiency deviation, and percent head deviations are also
calculated.
SP_0030 709
11.4 Equipment functional block diagrams
The heat recovery steam generator block diagram contains all algorithms which calculate the heat
recovery steam generator input/output efficiency as well as the thermal loss efficiency.
Hpipsec - the hp/ip section algorithm calculates the flow and enthalpies required for each section.
Bldwin - The blowdown algorithm calculates the flow and enthalpies required for the blowdown
section.
Lpsec - The lp section algorithm calculates the flow and enthalpies required for the lp section.
Reheat - The reheat algorithm calculates the flow and enahlpies required for the reheat section.
The design input/output and thermal loss efficiencies are calculated using a curve fit algorithm.
Hrsg - The final algorithm of the heat recovery steam generator algorithm calculates the
input/output and thermal loss efficiencies.
Ge_hrsg - This module calculates the input/output efficiency of the HRSG per GE specification.
710 SP_0030
11.4 Equipment functional block diagrams
The combustion turbine functional block diagram contains designs for power, heat rate and
evaporator (if one is present) and the combustion turbine algorithms.
The design combustion turbine power, heat rate and evaporator are calculated by using curve fits.
Basectg - This module calculates evaporator/chiller efficiency if one is present, corrected load,
ratio to guaranteed or ISO load, heat input in fuel, total heat input into combustion turbine, thermal
efficiency, heat rate, corrected heat rate, ratio to guarantee design or ISO heat rate, heat rate
deviation, corrected turbine efficiency, heat consumption, exhaust gas heat and exhaust gas flow.
Combturb - The combustion turbine algorithm is under the W Cturb tab and calculates corrected
power, heat rate, thermal efficiency, corrected thermal efficiency and heat consumption. This
algorithm has design information which includes the types of fuel(s) being used, the types of
corrections used, chillier/cooler existence, miscellaneous heat loss percentage and injection
existence.
Ge_combcycle - This module computes calculations using GE standards for the uncorrected
plant gross power output, gross thermal efficiency and gross heat rate in combined cycle
operation. The plant heat rate is calculated as the inverse of thermal efficiency. The plant gross
power output, thermal efficiency and heat rate are corrected for deviations from guaranteed
conditions based on GE correction curves.
Ge_combturb - This module computes calculations using GE standards for the uncorrected gas
turbine gross thermal efficiency and gross heat rate in combined cycle operation. The gas turbine
heat rate is calculated as the inverse of thermal efficiency. The gas turbine gross power output,
thermal efficiency and heat rate are corrected for deviations from guaranteed conditions based on
General Electric correction curves. The deviation between the calibrated run performance and the
corrected performance is also computed.
Gastrbintemp - The Gastrbintemp algorithm calculates the actual gas turbine inlet enthalpy. This
algorithm uses an estimated gas turbine temperature as well as a calculated gas turbine inlet
enthalpy to calculate the actual gas turbine inlet enthalpy. This algorithm calls the enthal routine
which solves for the enthalpy at the estimated temperature and will iterate and re-calculate the
enthalpy based on a new temperature estimate until the calculated gas turbine inlet enthalpy is
reached.
If the maximum number of loops is exceeded, the gas turbine inlet temperature will be set to 0
with BAD quality as well as the zerrflag being set. This may happen if the estimated gas turbine
inlet temperature is too far away from the actual gas turbine inlet temperature. If this happens, the
algorithm has constants which can be tuned depending on the project.
SP_0030 711
11.4 Equipment functional block diagrams
The heat rate functional block diagram contains all the corrections for the heat rate, a design heat
rate and the heat rate algorithm.
All the heat rate corrections should be calculated by curve fits. The ASME heat rate corrections
are available for main steam pressure, main steam temperature, reheat pressure drop and reheat
steam temperature and are located under the W Heatrate tab.
Hetrte - The heat rate algorithm can be found under the W Heatrate tab and calculates gross and
net turbine cycle heat rate. Adjusted turbine cycle heat rates with and without process steam are
also calculated. The deviations from the reference heat rate is calculated as well as the individual
heat rate corrections for main steam temperature, main steam pressure, reheat steam
temperature, reheat pressure drop, condenser back pressure and miscellaneous. The heat rate
design information is a selection of which heat rate correction factors are used.
The unit heat rate functional block diagram contains all unit heat rate corrections applicable to the
project. The heat rate correction factors are broken down into three categories: controllable,
maintenance and miscellaneous. At the beginning of the functional block diagram, the unit heat
rate algorithm should be used to calculate net, gross and design unit heat rate. The unit heat rate
corrections are dropped next with a total algorithm for each category. Lastly, the total unit heat
rate algorithm will be used. All unit heat rate algorithms can be found under the W Unithr tab.
Unhtrt
The Unhtrt or unit heat rate algorithm calculates the net unit heat rate of the plant as well as the
gross net unit heat rate. The design gross and net unit heat rates are also calculated. Finally, the
deviations for the gross and net unit heat rates are calculated.
Unhrasmersf
The Unhrasmersf or Unit heat rate ASME reheat spray flow algorithm calculates the ASME heat
rate correction for one percent reheat spray flow at the percent of valves wide open throttle flow.
Unhrasmessf
The Unhrasmessf or Unit heat rate ASME superheat spray flow algorithm calculates the ASME
heat rate correction for one percent superheat spray flow at the percent of valves wide open
throttle flow.
Unhregt
The Unhregt or Unit heat rate exit gas temp algorithm calculates the heat rate deviation in
Btu/kWh and the cost of deviation in $/hr for exit gas temperature.
712 SP_0030
11.4 Equipment functional block diagrams
Unhrmsp
The Unhrmsp Unit heat rate main steam pressure algorithm calculates the unit heat rate
deviation for main steam pressure in Btu/kWh and the cost of the deviation in $/hr.
Unhrmst
The Unhrmst or Unit heat rate main steam temperature algorithm calculates the unit heat rate
deviation for main steam temperature in Btu/kWh and the cost of the deviation in $/hr.
Unhro2calc
The Unhro2calc or Unit heat rate excess oxygen deviation algorithm calculates the heat rate
deviation in Btu/kWh and the cost of deviation in $/hr for excess oxygen deviation.
Unhrrsf
The Unhrrsf or Unit heat rate reheat spray flow algorithm calculates the heat rate deviation in
Btu/kWh and the cost of deviation in $/hr for reheat spray flow.
Unhrrst
The Unhrrst or Unit heat rate reheat steam temperature algorithm calculates the unit heat rate
deviation for reheat steam temperature in Btu/kWh and the cost of the deviation in $/hr.
Unhrssf
The Unhrssf or Unit heat rate superheat spray flow algorithm calculates the heat rate deviation in
Btu/kWh and the cost of deviation in $/hr for superheat spray flow.
Unhrpcthr
The Unhrpcthr or Percent main steam flow to valves wide open flow algorithm calculates the
ratio of percent of actual main steam flow to valves wide open throttle flow.
Unhrcontot
The Unhrcontot or Unit heat rate controllable total algorithm totals the unit heat rate deviations
for the controllable parameters in Btu/kWh and the cost of the deviations in $/hr. This algorithm
has a design screen to select which controllable heat rate corrections are needed.
SP_0030 713
11.4 Equipment functional block diagrams
Curve fit algorithms can be found under the W Curves tab and contain different forms of
polynomials and a function generator. Multiplying by a gain and/or adding a bias can modify the
results from all curve fit algorithms. Note that the gain and bias can be points, constants or both
points and constants.
If the gains and biases are not needed, the constants do not need to be modified and the analog
input points do not need to be configured. The polynomials are as follows.
Anlgcmppoly - This algorithm calculates the y-value of a polynomial based on the x input
between two values. If the x input does not fall between the two limits, the y-value is set to zero.
Anlgcmp2poly - This algorithm calculates one of two y-value polynomials based on an x input
and is split into two polynomials by an analog value.
Diganlgcmppoly - This algorithm calculates the y-value of a polynomial based on the x input in a
specified range and a digital flag. If the digital flag is not set and the x input does not fall in the
specified range, the y-value is set to zero.
Diganlgcmp2poly - This algorithm calculates one of two y-value polynomials based on an x input
value, digital input and is split by a specified analog value.
Digcmppoly - This algorithm calculates the y-value of a polynomial based on an x input and
digital flag. If the digital flag is not set, the y-value is set to zero.
Digcmp2poly - This algorithm calculates one of two y-value polynomials based on an x input and
a digital flag.
Funcgen - The function generator calculates the independent value based on one variable or the
independent value based on two dependent variables. The independent value is calculated using
linear interpolation.
Interpolate - This algorithm interpolates between two y values given the x values.
714 SP_0030
11.4 Equipment functional block diagrams
Unhrasmecsc - Unit heat rate ASME condenser subcooling. This algorithm calculates the
degrees Fahrenheit of subcooling at the percent of valves wide-open throttle flow.
Unhrasmeffw - Unit heat rate ASME final feedwater temperature. This algorithm calculates the
ASME heat rate correction for five degrees Fahrenheit final feedwater temperature deviation at
the percent of valves wide open throttle flow.
Unhrasmemkp - Unit heat rate ASME makeup water flow. This algorithm calculates the ASME
heat rate correction for one percent makeup flow at the percent of valves wide open throttle flow.
Unhrcbp - Unit heat rate condenser back pressure. This algorithm calculates the unit heat rate
deviation for condenser back pressure in Btu/kWh and the cost of the deviation in $/hr.
Unhrffw - Unit heat rate final feedwater temperature. This algorithm calculates the heat rate
deviation in Btu/kWh and the cost of deviation in $/hr for final feedwater temperature.
Unhrmkp - Unit heat rate makeup water flow. This algorithm calculates the heat rate deviation in
Btu/kWh and the cost of deviation in $/hr for makeup water flow.
Unhrrpd - Unit heat rate reheat pressure drop. This algorithm calculates the unit heat rate
deviation for reheat pressure drop in Btu/kWh and the cost of the deviation in $/hr.
Unhrmaintot - Unit heat rate maintenance total. This algorithm totals the unit heat rate deviations
for the maintenance parameters in Btu/kWh and the cost of the deviations in $/hr. This algorithm
has a design screen to select which maintenance heat rate corrections are needed.
SP_0030 715
11.4 Equipment functional block diagrams
Unhrasmeipdev1 - Unit heat rate ASME IP turbine loss factor number 1. This algorithm
calculates the ASME IP turbine loss factor number 1 as a function of ip exhaust pressure.
Unhrasmeipdev2 - Unit heat rate ASME IP turbine loss factor number 2.This algorithm calculates
the ASME IP turbine loss factor number 2 as a function of ip exhaust pressure.
Unhraitdev - Unit heat rate air heater air inlet temperature. This algorithm calculates the unit heat
rate deviation for air heater air inlet temperature deviation in Btu/kWh and the cost of the deviation
in $/hr.
Unhrauxdev - Unit heat rate auxiliary power deviation. This algorithm calculates the unit heat rate
deviation for auxiliary power deviation in Btu/kWh and the cost of the deviation in $/hr.
Unhrauxstm - Unit heat rate auxiliary steam. This algorithm calculates the unit heat rate deviation
for auxiliary steam in Btu/kWh and the cost of the deviation in $/hr.
Unhrhpdev - Unit heat rate HP turbine efficiency deviation. This algorithm calculates the unit heat
rate deviation for hp turbine efficiency deviation in Btu/kWh and the cost of the deviation in $/hr.
Unhripdev - Unit heat rate IP turbine efficiency deviation. This algorithm calculates the unit heat
rate deviation for ip turbine efficiency deviation in Btu/kWh and the cost of the deviation in $/hr.
Unhrmisctot - Unit heat rate miscellaneous totals. This algorithm totals the unit heat rate
deviations for the miscellaneous parameters in Btu/kWh and the cost of the deviations in $/hr.
This algorithm has a design screen to select which miscellaneous heat rate corrections are
needed.
Unhrtot - Unit heat rate totals. This algorithm computes the total unit heat rate deviation in
Btu/kWh and the total cost in $/hr for all the parameters.
716 SP_0030
11.4 Equipment functional block diagrams
The cooling tower functional block diagram contains five main algorithms:
design.
power.
cooling tower capability using estimated outlet temperature.
cooling tower predicted flow and capability of mechanical draft cooling towers.
predicted flow for the cooling tower from the adjusted and predicted flows.
Cooltwrdes - The cooling tower design algorithm reads in the design information and outputs the
design information to output points. The design cooling water flow, design hot water temperature,
design cold water temperature, number of fans, design fan horsepower per fan, design ambient
wet bulb temperature, cooling tower elevation, design L/G, design characteristic curve exponent,
design characteristic curve constant and in-service criteria must be entered on the Design Info
screen.
Cooltwrpwr - The cooling tower power algorithm calculates individual cell power, design water
flow, the ratio of design water flow to actual flow, total fan power and ratio of design power to
actual power.
Cooltwr - The cooling tower algorithm computes estimated cooling tower outlet temperature.
Capab - This algorithm calculates the capability of mechanical draft cooling towers. This algorithm
uses the output from cooltwr.
Coolcurv - This algorithm calculates the predicted flow for the cooling tower and the capability is
calculated from the adjusted and predicted flows.
SP_0030 717
11.4 Equipment functional block diagrams
All Emerson math algorithm results can be modified by a gain and bias. The result is multiplied by
a gain and then increased by the bias. The total gain is comprised of an analog input gain value
and a constant gain value. The total bias value is comprised of an analog input point bias value
and a constant gain value.
The default value for the constant gain value is 1 and the constant bias value is 0 so if the user
does not need to gain or bias the results, the constants do not need to be modified and the analog
input gain and analog input bias points do not need to be configured.
Addsub - Adds four numbers together and Subtracts the total of four numbers.
Mixer - Calculates the outlet flow, total heat and enthalpy of ten input flows and enthalpies.
Mult_add - Multiplies eight pairs of numbers and totals the result. Also divides the total by the
sum of odd inputs.
Multdiv - Multiplies four numbers together and divides by the product of four numbers.
Multpwr - Takes inputs to a specified power and adds together the products of eight pairs. Also
divides the total by the sum of the odd inputs.
718 SP_0030
11.4 Equipment functional block diagrams
SP_0030 719
11.4 Equipment functional block diagrams
The miscellaneous algorithms are contained in the W Misc tab and calculate corrected density,
specific heats of air and gas and volumetric flows for flue gas and water.
Avalgen - The analog generated value algorithm transfers the value from one point to another
point. This new point value can also be biased and gained if needed. The avalgen algorithm can
also be used to generate a constant value point.
Dvalgen - Ands the value of a digital constant and point and outputs the result to a digital output
point.
Enthal - The Enthal algorithm calculates the gas enthalpy given the fuel analysis, gas
temperature, reference enthalpy, and weight of ambient and injection moisture.
Frloss - Computes pipe section friction loss for fairly smooth pipe.
Massflowliquid - The mass flow algorithm converts water volumetric flow to mass flow.
Mixer - Calculates the outlet flow and enthalpy from a combination of up to 10 input flows.
Moistair - Calculates the three of the five inputs which are not configured. Two of the inputs must
be configured. The five inputs are dry bulb temperature, wet bulb temperature, ambient humidity,
relative humidity and dew point temperature.
Setdig - The set digital algorithm sets a digital point to 1 if a point value is above a limit.
Otherwise, if the point value is below the limit, the digital point is set to zero.
Setdig2 - Sets one of three digital flags based on an analog input. If the analog input is less than
a specified limit, the first digital flag is set. If the analog input is equal to the specified limit, the
second digital flag is set. If the analog input is greater than the specified limit, the third digital flag
is set.
Specheatair - The specific heat of air algorithm calculates the specific heat of air at a given air
temperature. The coefficients used are obtained from regressing the curve in Figure 3 of ASME
PTC-4.1.
Specheatgas - The specific heat of gas algorithm calculates the specific heat of flue gas at a
given temperature. The coefficients are obtained from regressing the curve in Figure 7 of AMSE
PTC-4.1.
Volflowgas - The volumetric gas flow algorithm converts a mass gas flow to a volumetric flow.
Volflowliquid - The volumetric liquid flow algorithm converts water mass flow to a volumetric
flow.
720 SP_0030
11.4 Equipment functional block diagrams
The steam table algorithms are found under the Stm Algs tab. The steam table algorithms include
the following:
Hclsp - Calculates compressed liquid enthalpy given entropy and absolute pressure.
Hclsp_chk - Checks input value and if above limit, call steam table call for compressed liquid
enthalpy.
Hcltp - Calculates compressed liquid enthalpy, given temperature and absolute pressure.
Hcltp_chk - If input value above limit, call hcltp. Otherwise set the enthalpy to zero.
Hichpp - Calculates enthalpy of the outlet of an isentropic process given inlet pressure, exit
absolute pressures and inlet enthalpy in the compressed liquid region.
Hichpp_chk - If input value above limit, calculate enthalpy using hichpp. Otherwise, set enthalpy
to zero.
Hishpp - Calculates enthalpy of the outlet of an isentropic process given inlet pressure, exit
absolute pressure and inlet enthalpy in the superheated or wet steam regions.
Histpp - Calculates enthalpy of an isentropic drop from conditions t1, p1, down to pressure p2.
Hslp_chk - If input value above limit, calculate enthalpy. Otherwise, set to zero.
Hslt_chk - If input value above limit, calculate enthalpy. Otherwise, set enthalpy to zero.
Hsstp - Calculates superheated steam enthalpy, given temperature and absolute pressure.
Hsstp_chk - If input value above limit, calculate enthalpy using hsstp. Otherwise, set to zero.
Hswsp - Calculates steam enthalpy, given entropy and absolute pressure of superheated or wet
steam.
Sclhp - Calculates compressed liquid entropy given enthalpy and absolute pressure.
Scltp - Calculates compressed liquid entropy, given temperature and absolute pressure.
SP_0030 721
11.4 Equipment functional block diagrams
Ssstp - Calculates superheated steam entropy, given temperature and absolute pressure.
Sswhp - Calculates steam entropy, given enthalpy and absolute pressure of superheated or wet
steam.
Tclhp - Calculates compressed liquid temperature given enthalpy and absolute pressure.
Tswhp - Calculates steam temperature, given entropy and absolute pressure of superheated or
wet steam.
Tswsp - Calculates steam temperature, given entropy and absolute pressure of superheated or
wet steam.
Vcltp - Is the calculated compressed liquid specific volume, given temperature and absolute
pressure.
Vslt - This algorithm calculates saturated liquid specific volume given temperature.
Vsstp - Calculates superheated steam specific volume, given temperature and absolute pressure.
Vswhp - Is the calculated steam specific volume, given enthalpy and absolute pressure of
superheated or wet steam.
Vswsp - Calculates steam specific volume, given entropy and absolute pressure of superheated
or wet steam.
Xswhp - Calculates steam quality, given entropy and absolute pressure of superheated or wet
steam.
Xswsp - Calculates steam quality, given entropy and absolute pressure of superheated or wet
steam.
722 SP_0030
11.5 Output functional block diagram
The GPA package outputs data through the output functional block diagram. These functional
block diagrams should contain the output algorithms (analog and digital).
After creating the OUTPUT DOCUMENT, tab over to the W OUTPUT algorithm tab. This group
contains the Analogout and Digitalout algorithms. The Analogout algorithm outputs data agent
server analog values and qualities from local GPA values and qualities. The Digitalout algorithm
outputs data agent server digital values from local GPA digital values.
Analogout - The analog output algorithm will output the quality and value from the local GPA
values and qualities to the data highway through the data agent Server. The tags for this
algorithm are configured by selecting local tags, which will go to the data highway and assign a
data agent server name. All data agent server names must exist, if they do not exist, these points
will be logged in the Event log. OPC Data Agent server points with a .QQ Extension are output
points and the Event log should not contain any unrecognized .QQ points.
Digitalout - The digital output algorithm will output the digital local GPA values to the data
highway through the data agent Server. The tags for this algorithm are configured by selecting
local tags and assigning a data agent server name.
SP_0030 723
11.6 Display graphics development
By using the drawing tools and methods, you can build displays to help visualize the process by
creating a representative drawing of the project. Some examples are shown below:
724 SP_0030
11.6 Display graphics development
SP_0030 725
11.6 Display graphics development
726 SP_0030
11.6 Display graphics development
SP_0030 727
Index
Basectg • 174
A Basectg Calculation Overview • 178
Absval • 118 Bfpturb • 182
Absval Calculation Overview • 119 Bfpturb Calculation Overview • 184
ACNDSRCORR • 120 Bldwn • 186
ACNDSRCORR Calculation Overview • 121 Bldwn Calculation Overview • 186
Add10 • 125 Blrio • 187
Add10 Calculation Overview • 126 Blrio Calculation Overview • 189
Add4 • 124 Boiler • 192
Add4 Calculation Overview • 124 Boiler Calculation Overview • 196
Adding algorithms • 29 Boiler Efficiency (Boiler) • 73
Adding tag sets to a project from external Boiler Feed Pump Turbine (Bfpturb) • 72
cross-reference (.xref) files. • 34 Boiler functional block diagram • 708
Addsub • 127 Boiler Steam Flow (Hwblrsm) • 74
Addsub Calculation Overview • 127 BOILERASME4 • 201
Air Cooled Condenser (Acndsrcorr) • 70 BoilerASME4 Calculation Overview • 205
Air Heater Performance (Airhtr) • 71 C
AIRCONDSR • 129
AIRCONDSR Calculation Overview • 130 Capab • 211
Airhtrs • 131 Capab Calculation Overview • 212
Airhtrs Calculation Overview • 143 Chkload • 213
Algorithm checklist • 35 Chkload Calculation Overview • 213
Algorithm properties • 115 CLTEST • 660
Algorithms (Calculation Blocks) • 105 Cndavgtemp • 215
Algorithms (Calculation Blocks) List • 105 Cndavgtemp Calculation Overview • 216
Alstomexpan • 145 Cnddesign • 217
Alstomexpan Calculation Overview • 149 Cnddesign Calculation Overview • 221
Analog input filtering • 10 Co2econ • 224
Analoginavg • 157, 702 Co2econ Calculation Overview • 226
Analoginavg Calculation Overview • 157 Combturb • 228
Analogout • 158 Combturb Calculation Overview • 233
Analogout Calculation Overview • 158 Combustion Turbine (Comturb) • 75
And6 • 159 Combustion turbine calculation method • 10
And6 Calculation Overview • 159 Combustion turbine functional block diagram
Anlgcmp2poly • 160 • 711
Anlgcmp2poly Calculation Overview • 161 Combustion turbine performance module • 5
Anlgcmppoly • 162 Common functional block diagrams • 701
Anlgcmppoly Calculation Overview • 162 Compair • 239
Arctan • 169 Compair Calculation Overview • 240
Arctan Calculation Overview • 169 Compr • 257
Asmeflowcomp • 164 Compr Calculation Overview • 260
Asmeflowcomp Calculation Overview • 165 Compressor (Compr) • 76
Avalgen • 170 Compressor Wash (Compwash) • 77
Avalgen Calculation Overview • 170 CompWash • 242
Avg10 • 172 CompWash Calculation Overview • 246
Avg10 Calculation Overview • 173 Condenser (Cnddesign) • 78
Avg4 • 171 Condenser functional block diagram • 705
Avg4 Calculation Overview • 171 Condenser module • 8
Condsr • 268
B Condsr Calculation Overview • 274
Backing up data files • 15 Configuration tab • 50
SP_0030 729
Index
730 SP_0030
Index
SP_0030 731
Index
732 SP_0030
Index
SP_0030 733
Index
734 SP_0030