Class GasLiftCalculator

java.lang.Object
neqsim.process.fielddevelopment.screening.GasLiftCalculator
All Implemented Interfaces:
Serializable

public class GasLiftCalculator extends Object implements Serializable
Gas lift design and optimization calculator.

This class implements comprehensive gas lift calculations for artificial lift screening and design, including:

  • GLR optimization: Optimal gas-liquid ratio for maximum production
  • Valve spacing: Unloading and operating valve depths
  • Performance curves: Production rate vs. injection rate
  • Gas lift power: Energy requirements for gas compression
  • Economic screening: Cost vs. benefit analysis

Gas Lift Theory

Gas lift reduces the hydrostatic head in the production tubing by injecting gas to lighten the fluid column. The pressure balance is:

P_reservoir = P_wellhead + ΔP_friction + ΔP_hydrostatic

where the hydrostatic term depends on the average mixture density, which decreases with increasing GLR.

Optimal GLR

Production increases with gas injection until friction losses dominate. The optimal GLR represents the economic balance between increased production and compression costs.

Usage Example

GasLiftCalculator calc = new GasLiftCalculator();
calc.setReservoirPressure(250.0, "bara");
calc.setReservoirTemperature(85.0, "C");
calc.setWellheadPressure(20.0, "bara");
calc.setWellDepth(3000.0, "m");
calc.setTubingID(0.1, "m");
calc.setProductivityIndex(5.0); // Sm3/day/bar
calc.setOilGravity(35.0, "API");
calc.setWaterCut(0.3);
calc.setFormationGOR(100.0); // Sm3/Sm3

GasLiftResult result = calc.calculate();
System.out.println("Optimal GLR: " + result.getOptimalGLR() + " Sm3/Sm3");
System.out.println("Oil rate: " + result.getOilRate() + " Sm3/day");
System.out.println("Injection rate: " + result.getInjectionRate() + " MSm3/day");
System.out.println("Compression power: " + result.getCompressionPower() + " kW");
Version:
1.0
Author:
ESOL
See Also:
  • Field Details

    • serialVersionUID

      private static final long serialVersionUID
      See Also:
    • GRAVITY

      private static final double GRAVITY
      See Also:
    • GAS_CONSTANT

      private static final double GAS_CONSTANT
      See Also:
    • STANDARD_PRESSURE

      private static final double STANDARD_PRESSURE
      See Also:
    • STANDARD_TEMPERATURE

      private static final double STANDARD_TEMPERATURE
      See Also:
    • reservoirPressure

      private double reservoirPressure
    • reservoirTemperature

      private double reservoirTemperature
    • wellheadPressure

      private double wellheadPressure
    • wellheadTemperature

      private double wellheadTemperature
    • wellDepth

      private double wellDepth
    • tubingID

      private double tubingID
    • tubingRoughness

      private double tubingRoughness
    • productivityIndex

      private double productivityIndex
    • bubblePointPressure

      private double bubblePointPressure
    • oilDensityStd

      private double oilDensityStd
    • waterDensity

      private double waterDensity
    • gasMolecularWeight

      private double gasMolecularWeight
    • formationGOR

      private double formationGOR
    • waterCut

      private double waterCut
    • injectionPressure

      private double injectionPressure
    • injectionTemperature

      private double injectionTemperature
    • valveSpacing

      private double valveSpacing
    • valvePressureDrop

      private double valvePressureDrop
    • maxValves

      private int maxValves
    • compressorEfficiency

      private double compressorEfficiency
    • compressionRatio

      private double compressionRatio
    • optimalGLR

      private double optimalGLR
    • maxProductionRate

      private double maxProductionRate
    • injectionRateAtOptimal

      private double injectionRateAtOptimal
    • compressionPower

      private double compressionPower
    • valvePositions

      private List<GasLiftCalculator.ValvePosition> valvePositions
    • performanceCurve

      private List<GasLiftCalculator.PerformancePoint> performanceCurve
  • Constructor Details

    • GasLiftCalculator

      public GasLiftCalculator()
      Creates a new gas lift calculator with default parameters.
  • Method Details

    • calculate

      public GasLiftCalculator.GasLiftResult calculate()
      Performs complete gas lift calculation.
      Returns:
      gas lift result with all calculated values
    • calculateNaturalFlowRate

      private double calculateNaturalFlowRate()
      Calculates natural flow rate without gas lift using inflow performance.
      Returns:
      natural flow rate in Sm3/day
    • generatePerformanceCurve

      private void generatePerformanceCurve()
      Generates performance curve: production rate vs. total GLR.
    • calculateProductionAtGLR

      private double calculateProductionAtGLR(double totalGLR)
      Calculates production rate at a given total GLR.

      Uses iterative solution of the well flow equation with multiphase flow correlations.

      Parameters:
      totalGLR - total gas-liquid ratio (Sm3/Sm3)
      Returns:
      production rate (Sm3/day liquid)
    • calculateBHPfromVLP

      private double calculateBHPfromVLP(double liquidRate, double totalGLR)
      Calculates bottom-hole pressure from VLP (vertical lift performance).

      Uses simplified multiphase flow correlation based on Hagedorn-Brown with modifications for gas lift.

      Parameters:
      liquidRate - liquid rate (Sm3/day)
      totalGLR - total GLR (Sm3/Sm3)
      Returns:
      bottom-hole pressure (bara)
    • calculateMixtureDensity

      private double calculateMixtureDensity(double pressure, double temperature, double totalGLR)
      Calculates mixture density at given conditions.
      Parameters:
      pressure - pressure (bara)
      temperature - temperature (K)
      totalGLR - total GLR (Sm3/Sm3)
      Returns:
      mixture density (kg/m³)
    • calculateZfactor

      private double calculateZfactor(double pressure, double temperature)
      Calculates Z-factor using Standing-Katz correlation (simplified).
      Parameters:
      pressure - pressure (bara)
      temperature - temperature (K)
      Returns:
      Z-factor
    • calculateHallYarboroughY

      private double calculateHallYarboroughY(double ppr, double tpr)
      Hall-Yarborough Y function (simplified).
      Parameters:
      ppr - pseudo-reduced pressure
      tpr - pseudo-reduced temperature
      Returns:
      Y parameter
    • calculateLiquidHoldup

      private double calculateLiquidHoldup(double insituGLR)
      Calculates liquid holdup using simplified drift-flux correlation.
      Parameters:
      insituGLR - in-situ gas-liquid ratio (m³/m³)
      Returns:
      liquid holdup (fraction)
    • calculateFrictionGradient

      private double calculateFrictionGradient(double liquidRate, double totalGLR, double pressure, double temperature)
      Calculates friction pressure gradient.
      Parameters:
      liquidRate - liquid rate (Sm3/day)
      totalGLR - total GLR (Sm3/Sm3)
      pressure - pressure (bara)
      temperature - temperature (K)
      Returns:
      friction gradient (Pa/m)
    • calculateFrictionFactor

      private double calculateFrictionFactor(double reynolds)
      Calculates Darcy friction factor using Colebrook-White equation.
      Parameters:
      reynolds - Reynolds number
      Returns:
      friction factor
    • findOptimalGLR

      private void findOptimalGLR()
      Finds optimal GLR that maximizes production.
    • calculateValvePositions

      private void calculateValvePositions()
      Calculates valve positions for gas lift unloading.

      Uses the Timmerman method for unloading valve design:

      • First valve: Positioned to unload kill fluid
      • Subsequent valves: Spaced for progressive unloading
      • Operating valve: Deepest valve, typically near perforations
    • calculateAverageFluidDensity

      private double calculateAverageFluidDensity(double glr)
      Calculates average fluid density for gradient estimation.
      Parameters:
      glr - gas-liquid ratio (Sm3/Sm3)
      Returns:
      average density (kg/m³)
    • calculateCompressionPower

      private void calculateCompressionPower()
      Calculates compression power for gas lift injection.
    • setReservoirPressure

      public GasLiftCalculator setReservoirPressure(double pressure, String unit)
      Sets reservoir pressure.
      Parameters:
      pressure - pressure value
      unit - pressure unit ("bara", "psia", etc.)
      Returns:
      this for chaining
    • setReservoirTemperature

      public GasLiftCalculator setReservoirTemperature(double temperature, String unit)
      Sets reservoir temperature.
      Parameters:
      temperature - temperature value
      unit - temperature unit ("K", "C", "F")
      Returns:
      this for chaining
    • setWellheadPressure

      public GasLiftCalculator setWellheadPressure(double pressure, String unit)
      Sets wellhead pressure.
      Parameters:
      pressure - pressure value
      unit - pressure unit
      Returns:
      this for chaining
    • setWellDepth

      public GasLiftCalculator setWellDepth(double depth, String unit)
      Sets well depth (true vertical depth).
      Parameters:
      depth - depth value
      unit - depth unit ("m", "ft")
      Returns:
      this for chaining
    • setTubingID

      public GasLiftCalculator setTubingID(double diameter, String unit)
      Sets tubing inner diameter.
      Parameters:
      diameter - diameter value
      unit - diameter unit ("m", "in", "mm")
      Returns:
      this for chaining
    • setProductivityIndex

      public GasLiftCalculator setProductivityIndex(double pi)
      Sets productivity index.
      Parameters:
      pi - productivity index (Sm3/day/bar)
      Returns:
      this for chaining
    • setOilGravity

      public GasLiftCalculator setOilGravity(double gravity, String unit)
      Sets oil gravity.
      Parameters:
      gravity - gravity value
      unit - gravity unit ("API", "SG")
      Returns:
      this for chaining
    • setWaterCut

      public GasLiftCalculator setWaterCut(double waterCut)
      Sets water cut.
      Parameters:
      waterCut - water cut fraction (0-1)
      Returns:
      this for chaining
    • setFormationGOR

      public GasLiftCalculator setFormationGOR(double gor)
      Sets formation GOR.
      Parameters:
      gor - formation GOR (Sm3/Sm3)
      Returns:
      this for chaining
    • setInjectionPressure

      public GasLiftCalculator setInjectionPressure(double pressure, String unit)
      Sets gas lift injection pressure.
      Parameters:
      pressure - injection pressure value
      unit - pressure unit
      Returns:
      this for chaining
    • setBubblePointPressure

      public GasLiftCalculator setBubblePointPressure(double pressure, String unit)
      Sets bubble point pressure.
      Parameters:
      pressure - bubble point pressure value
      unit - pressure unit
      Returns:
      this for chaining
    • setCompressorEfficiency

      public GasLiftCalculator setCompressorEfficiency(double efficiency)
      Sets compressor efficiency.
      Parameters:
      efficiency - efficiency (0-1)
      Returns:
      this for chaining
    • convertPressure

      private double convertPressure(double value, String unit)
    • convertTemperature

      private double convertTemperature(double value, String unit)
    • convertLength

      private double convertLength(double value, String unit)