home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
Hall of Fame
/
HallofFameCDROM.cdr
/
oilfield
/
compress.lzh
/
COMPRESS.DOC
< prev
Wrap
Text File
|
1986-09-15
|
10KB
|
265 lines
COMPRESSOR - VERSION 1.1
BY TOM WALTON - SEPTEMBER 1, 1986
NATURAL GAS PIPELINE COMPRESSOR CALCULATION
WITH
VARIABLE COMPRESSION EFFICIENCY
ANOTHER PRODUCT OF Midnight Magic Software
===========================================
COMPRESSOR is a demonstration program that is useful to the
engineer working with centrifugal compressors to compress natural
gas or gas with high CO2(up to 80%) or H2S(up to 80%) content.
The program uses data taken from the compressor characteristic
curve to determine the actual operational efficiency at the
operating point. The technique for determining the operating
efficiency, using three data points from the MAX SPEED CURVE, was
published in the SEPTEMBER 1, 1986 Oil and Gas Journal. This
program uses a slightly more complex method to fit four
efficiency data points to a curve.
The program uses the gas gravity and inert analysis (plus methane
mole fraction if gravity > 0.75 or if the gas contains H2S) to
calculate the necessary fluid properties. These calculations are
based on the compressability correlation taken from "VOLUMETRIC
AND PHASE BEHAVIOR OF OILFIELD HYDROCARBON SYSTEMS", M.B.
Standing, 9th printing, SPE, 1981, Page 121. This correlation is
a curve fit of the Standing-Katz compressability charts. Its
applicable range is 1.2<Tr<2.4 and 0<Pr<13. There are no
messages to indicate that these limits have been exceeded, so
check your results if the gravity is high. The specific gravity
is arbitrarily limited to 1.50.
To use the program, enter;
d:COMPRESS<cr> -- where d: is the drive designation.
The first screen tells the user what data is required to run the
program. To continue, press any key.
The second screen is the fluid property input screen. The
program contains an example which may be run by pressing the down
arrow on the numeric keypad once for each entry. This feature is
also available for normal use to allow the user to go back and
modify one value without entering all the data over again.
Backtracking through the data is done by pressing the <esc> key
until the proper value is replaced with the curser bar. Pressing
a carrage return without entering a value will cause a zero to be
used.
Skipping to previous screens puts the curser at the first entry
on the screen and the down arrow is used to move the curser to
the proper entry. Existing values are replaced by entering the
new value and pressing the <cr>. Pressing the down arrow at any
point in an entry will cause the entry to be lost and the old
value to be used.
1
The third and fourth screens are used to describe the compressor
envelope. The third screen asks for a description of the SURGE
LINE. The values entered here do not effect the calculations,
but are used to tell the user if the selected operating point is
within the operation envelope. If both data points entered are
the same, or describe a vertical line, the program will halt with
a zero divide error ( Run-time error 02).
The fourth screen asks for four data points along the MAXIMUM
SPEED CURVE. The data required are the ACFM, HEAD and
% EFFICIENCY at four points on the curve. If the efficiency
exhibits a maximum, select two points from either side of the
maximum if possible. Poor data will cause messages to be
displayed on the last line of the screen, but will normally not
halt processing.
The fifth screen is the operational data screen. The inlet
temperature, inlet and discharge pressures and flow rate are
required. The final calculated results are also displayed on
this screen. As described above, the program allows the user to
go back through the data with the <esc> key and to move forward
through it with the down arrow key and to change one value
without disturbing other values. Pressing the return key when
the curser bar is visible will cause the corresponding value to
be replaced with what has been entered.
BUILT IN SAMPLE PROBLEM
The sample problem built into the program is taken from the
compressor envelope published in the Oil and Gas Journal. To try
it, run the program and simply press the down arrow key for each
entry. When the fourth screen has been entered and any key
pressed to continue, a slight pause of one or two seconds is
experienced while the final calculations are done for the
envelope. When the fifth screen is displayed, continue to press
the down arrow until the last entry is filled and the bottom line
message is showing.
The data displayed is a complete picture of the operating
parameters of a centrifugal compressor. The operating point is
displayed as are the limiting parameters. The SURGE ACFM is the
minimum ACFM that would be permitted at the operating head before
the unit went into surge (or the surge controller became active).
The MAX HEAD is the maximum head that can be obtained at the
operating ACFM without overspeeding the compressor. The
calculated operating speed and the operating efficiency are also
displayed along with the efficiency-corrected compression
horsepower. The fluid parameters are displayed as well.
The user can modify the example to see what the effects of higher
flow rates, higher discharge pressure, changes in suction
temperature, etc. will have on the operation of the compressor.
2
For example, press the <esc> to move the curser bar to DISCHARGE
PRESSURE and enter 1200<cr>. Make sure you press the return and
not the down arrow or the value will be unchanged. Look at the
bottom of the right hand column, the calculated speed, the
calculated efficiency and the discharge temperature.
Change the discharge pressure back to 1020 and change the inlet
flow rate to 700 MCFD. Look at the bottom of the right hand
column, the calculated discharge temperature, the efficiency and
the calculated ACFM.
ERROR MESSAGES
The program has a number of data checks built into the program
to prevent or reduce data errors. The basic input routine will
accept numbers in the form xxxx.x or x.xxxExx. Checks are made
to ensure that letters and other symbols are not entered and the
form of the numbers is checked. For example, "0.-55", "-.3.6"
and "34.5-" are not valid data forms. If these are entered the
computer beeps and a message is displayed on the bottom line of
the screen.
Once an input value has been entered, it is checked for validity
if this is possible. Some of the checks made are:
- specific gravity 0.5539 < G < 1.50
- mole fraction 0.0 < Z < 1.0 and SUM(Z) <= 1.0
- suction pressure 14.7 < Ps
- discharge pressure Pd > Ps
In addition, a number of data checks are made of the envelope
data. The ACFM - Head data are fitted to quadratic curves in two
sets of three points: (1,2,4) and (1,3,4). The coefficients of
the curves are checked as described in the O&GJ article. If one
curve is concave upward or has a negative constant, a message is
printed to indicate that one of the two sets of data have a bad
point. The bad set of data is discarded and the program
continues. If both sets of coefficients are bad, the following
message is printed on the screen:
** ERROR ** IMPROPER VALUES IN ENVELOPE DATA
If you continue at this point, a fatal error will result and the
program will have to be restared.
After these checks are done, the first curve is used to calculate
the head at the third ACFM point and the result is compared to
the input data. If the values are different by more than 2%, the
following message is printed:
PROBLEM WITH MAX SPEED DATA - CHECK ACCURACY BEFORE PROCEEDING
If this or no message is printed, the resulting quadratic
coefficients are averaged and the program proceeds.
3
OTHER PRODUCTS
The methods used in this program are taken from a larger pipeline
simulation program written by the author. This product, called
"PLM", is commercially available on a licence or timeshare basis
and priced to be competitive. For further information, write to;
Tom Walton
9 Acadie Road
Aylmer, Quebec
Canada
J9J 1H7
4