Class PumpChart

java.lang.Object
neqsim.process.equipment.pump.PumpChart
All Implemented Interfaces:
Serializable, Cloneable, PumpChartInterface

public class PumpChart extends Object implements PumpChartInterface, Serializable
Pump performance curve handler for centrifugal pump simulation.

This class manages manufacturer pump curves and provides interpolation/extrapolation of pump performance data. It supports:

Performance Curves

  • Head vs Flow (H-Q): Pump head at various flow rates
  • Efficiency vs Flow (η-Q): Pump efficiency variation
  • NPSH vs Flow: Net Positive Suction Head required

Affinity Laws

Performance scaling with speed using reduced variables:

  • Reduced flow: Q_red = Q / N
  • Reduced head: H_red = H / N²
  • NPSH scaling: NPSH ∝ N²

Density Correction

Pump curves are typically measured with water (~998 kg/m³). When pumping different fluids, head is corrected using: H_actual = H_chart × (ρ_chart / ρ_actual)

Set reference density via:

Operating Status

Monitors for abnormal conditions:

  • Surge: Low flow instability (dH/dQ > 0)
  • Stonewall: Maximum flow limit exceeded
  • Low Efficiency: Operating far from BEP

Usage Example

PumpChart chart = new PumpChart();
double[] speed = {1000.0};
double[][] flow = {{10, 20, 30, 40, 50}};
double[][] head = {{120, 115, 108, 98, 85}};
double[][] efficiency = {{65, 75, 82, 80, 72}};
double[] conditions = {18.0, 298.15, 1.0, 1.0, 998.0};

chart.setCurves(conditions, speed, flow, head, efficiency);
chart.setHeadUnit("meter");

// Get performance at operating point
double headAtPoint = chart.getCorrectedHead(35.0, 1200.0, 850.0);
double effAtPoint = chart.getEfficiency(35.0, 1200.0);
String status = chart.getOperatingStatus(35.0, 1200.0);
Version:
$Id: $Id
Author:
asmund
See Also:
  • Field Details

    • serialVersionUID

      private static final long serialVersionUID
      Serialization version UID.
      See Also:
    • logger

      static org.apache.logging.log4j.Logger logger
      Logger object for class.
    • chartValues

      ArrayList<PumpCurve> chartValues
    • isSurge

      boolean isSurge
    • maxSpeedCurve

      double maxSpeedCurve
    • minSpeedCurve

      double minSpeedCurve
    • refMW

      double refMW
    • headUnit

      private String headUnit
    • usePumpChart

      private boolean usePumpChart
    • refTemperature

      double refTemperature
    • refPressure

      double refPressure
    • referenceSpeed

      double referenceSpeed
    • refZ

      double refZ
    • useRealKappa

      private boolean useRealKappa
    • chartConditions

      double[] chartConditions
    • reducedHeadFitter

      final org.apache.commons.math3.fitting.WeightedObservedPoints reducedHeadFitter
    • reducedFlowFitter

      final org.apache.commons.math3.fitting.WeightedObservedPoints reducedFlowFitter
    • fanLawCorrectionFitter

      final org.apache.commons.math3.fitting.WeightedObservedPoints fanLawCorrectionFitter
    • reducedEfficiencyFitter

      final org.apache.commons.math3.fitting.WeightedObservedPoints reducedEfficiencyFitter
    • reducedHeadFitterFunc

      org.apache.commons.math3.analysis.polynomials.PolynomialFunction reducedHeadFitterFunc
    • reducedEfficiencyFunc

      org.apache.commons.math3.analysis.polynomials.PolynomialFunction reducedEfficiencyFunc
    • fanLawCorrectionFunc

      org.apache.commons.math3.analysis.polynomials.PolynomialFunction fanLawCorrectionFunc
    • speed

      double[] speed
    • flow

      double[][] flow
    • efficiency

      double[][] efficiency
    • redflow

      double[][] redflow
    • redhead

      double[][] redhead
    • redEfficiency

      double[][] redEfficiency
    • minFlow

      double minFlow
    • maxFlow

      double maxFlow
    • minReducedFlow

      double minReducedFlow
    • maxReducedFlow

      double maxReducedFlow
    • npsh

      double[][] npsh
    • redNPSH

      double[][] redNPSH
    • reducedNPSHFitter

      final org.apache.commons.math3.fitting.WeightedObservedPoints reducedNPSHFitter
    • reducedNPSHFunc

      org.apache.commons.math3.analysis.polynomials.PolynomialFunction reducedNPSHFunc
    • hasNPSHCurve

      boolean hasNPSHCurve
    • referenceDensity

      private double referenceDensity
    • referenceViscosity

      private double referenceViscosity
    • useViscosityCorrection

      private boolean useViscosityCorrection
    • cQ

      private double cQ
    • cH

      private double cH
    • cEta

      private double cEta
    • lastViscosity

      private double lastViscosity
  • Constructor Details

    • PumpChart

      public PumpChart()

      Constructor for PumpChart.

  • Method Details

    • addCurve

      public void addCurve(double speed, double[] flow, double[] head, double[] efficiency)
      This method is used add a curve to the CompressorChart object.
      Specified by:
      addCurve in interface PumpChartInterface
      Parameters:
      speed - a double
      flow - an array of type double
      head - an array of type double
      efficiency - an array of type double
    • setCurves

      public void setCurves(double[] chartConditions, double[] speed, double[][] flow, double[][] head, double[][] efficiency)
      This method is used add a set of curves to the CompressorChart object.
      Specified by:
      setCurves in interface PumpChartInterface
      Parameters:
      chartConditions - an array of type double
      speed - an array of type double
      flow - an array of type double
      head - an array of type double
      efficiency - an array of type double
    • setNPSHCurve

      public void setNPSHCurve(double[][] npshRequired)
      Set NPSH (Net Positive Suction Head) required curves for the pump.

      NPSH required is the minimum suction head needed to prevent cavitation. It varies with flow rate and follows affinity laws: NPSH ∝ N² (where N is speed).

      The NPSH data should correspond to the same speed and flow points as the performance curves set by setCurves(). If dimensions don't match, an exception is thrown.

      Specified by:
      setNPSHCurve in interface PumpChartInterface
      Parameters:
      npshRequired - 2D array of NPSH required values [speed index][flow index] in meters
      Throws:
      IllegalArgumentException - if dimensions don't match flow/speed arrays
    • fitNPSHCurve

      private void fitNPSHCurve()
      Fit polynomial function to reduced NPSH data.
    • getNPSHRequired

      public double getNPSHRequired(double flow, double speed)
      Get NPSH required at specified flow and speed.

      Uses affinity law scaling: NPSH = NPSH_reduced × N²

      Specified by:
      getNPSHRequired in interface PumpChartInterface
      Parameters:
      flow - flow rate in m³/hr
      speed - pump speed in rpm
      Returns:
      NPSH required in meters, or 0.0 if no NPSH curve is available
    • hasNPSHCurve

      public boolean hasNPSHCurve()
      Check if pump chart has NPSH curve data.
      Specified by:
      hasNPSHCurve in interface PumpChartInterface
      Returns:
      true if NPSH curve is available
    • fitReducedCurve

      public void fitReducedCurve()

      fitReducedCurve.

    • getHead

      public double getHead(double flow, double speed)
      Get method for polytropic head from reference curves.
      Specified by:
      getHead in interface PumpChartInterface
      Parameters:
      flow - [m3/h], speed in [rpm].
      speed - a double
      Returns:
      polytropic head in unit [getHeadUnit]
    • getEfficiency

      public double getEfficiency(double flow, double speed)
      Get method for efficiency from reference curves.
      Specified by:
      getEfficiency in interface PumpChartInterface
      Parameters:
      flow - [m3/h], speed in [rpm].
      speed - a double
      Returns:
      efficiency [%].
    • getSpeed

      public int getSpeed(double flow, double head)

      getSpeed.

      Specified by:
      getSpeed in interface PumpChartInterface
      Parameters:
      flow - a double
      head - a double
      Returns:
      a int
    • efficiency

      public double efficiency(double flow, double speed)

      efficiency.

      Parameters:
      flow - a double
      speed - a double
      Returns:
      a double
    • checkSurge1

      public boolean checkSurge1(double flow, double head)

      checkSurge1.

      Parameters:
      flow - a double
      head - a double
      Returns:
      a boolean
    • checkSurge2

      public boolean checkSurge2(double flow, double speed)

      checkSurge2.

      Parameters:
      flow - a double
      speed - a double
      Returns:
      a boolean
    • checkStoneWall

      public boolean checkStoneWall(double flow, double speed)

      checkStoneWall.

      Parameters:
      flow - a double
      speed - a double
      Returns:
      a boolean
    • getBestEfficiencyFlowRate

      public double getBestEfficiencyFlowRate()
      Get the best efficiency point (BEP) flow rate.
      Specified by:
      getBestEfficiencyFlowRate in interface PumpChartInterface
      Returns:
      flow rate at BEP in m³/hr at reference speed
    • getSpecificSpeed

      public double getSpecificSpeed()
      Calculate pump specific speed at best efficiency point.

      Ns = N·√Q / H^(3/4) where N is in rpm, Q in m³/s, H in m

      Used to classify pump type:

      • Ns < 1000: Radial flow (centrifugal)
      • 1000 < Ns < 4000: Mixed flow
      • Ns > 4000: Axial flow
      Specified by:
      getSpecificSpeed in interface PumpChartInterface
      Returns:
      specific speed (dimensionless)
    • getOperatingStatus

      public String getOperatingStatus(double flow, double speed)
      Check operating status of pump at given flow and speed.
      Specified by:
      getOperatingStatus in interface PumpChartInterface
      Parameters:
      flow - flow rate in m³/hr
      speed - pump speed in rpm
      Returns:
      operating status string
    • setReferenceConditions

      public void setReferenceConditions(double refMW, double refTemperature, double refPressure, double refZ)
      Set method for the reference conditions of the compressor chart.
      Specified by:
      setReferenceConditions in interface PumpChartInterface
      Parameters:
      refMW - a double
      refTemperature - a double
      refPressure - a double
      refZ - a double
    • main

      public static void main(String[] args)

      main.

      Parameters:
      args - an array of String objects
    • isUsePumpChart

      public boolean isUsePumpChart()
      Checks if set to use compressor chart for compressor calculations (chart is set for compressor).
      Specified by:
      isUsePumpChart in interface PumpChartInterface
      Returns:
      a boolean
    • setUsePumpChart

      public void setUsePumpChart(boolean usePumpChart)
      Set compressor calculations to use compressor chart.
      Specified by:
      setUsePumpChart in interface PumpChartInterface
      Parameters:
      usePumpChart - a boolean
    • getHeadUnit

      public String getHeadUnit()
      Get the selected unit of head.
      Specified by:
      getHeadUnit in interface PumpChartInterface
      Returns:
      unit of head
    • getReferenceDensity

      public double getReferenceDensity()
      Get the reference density used for density correction.
      Specified by:
      getReferenceDensity in interface PumpChartInterface
      Returns:
      reference density in kg/m³, or -1.0 if not set
    • setReferenceDensity

      public void setReferenceDensity(double referenceDensity)
      Set the reference density for density correction.

      Pump curves are typically measured with water at standard conditions (~998 kg/m³). When pumping fluids with different densities, the head must be corrected:

      H_actual = H_chart × (ρ_chart / ρ_actual)

      Specified by:
      setReferenceDensity in interface PumpChartInterface
      Parameters:
      referenceDensity - reference fluid density in kg/m³ (use -1.0 to disable correction)
    • hasDensityCorrection

      public boolean hasDensityCorrection()
      Check if density correction is enabled.
      Specified by:
      hasDensityCorrection in interface PumpChartInterface
      Returns:
      true if reference density is set and correction will be applied
    • getCorrectedHead

      public double getCorrectedHead(double flow, double speed, double actualDensity)
      Get density-corrected head for a given flow, speed, and actual fluid density.

      Applies the correction: H_actual = H_chart × (ρ_chart / ρ_actual)

      If no reference density is set, returns the uncorrected head.

      Specified by:
      getCorrectedHead in interface PumpChartInterface
      Parameters:
      flow - flow rate in m³/hr
      speed - pump speed in rpm
      actualDensity - actual fluid density in kg/m³
      Returns:
      corrected head in the unit specified by getHeadUnit()
    • calculateViscosityCorrection

      public void calculateViscosityCorrection(double viscosity, double flowBEP, double headBEP, double speed)
      Calculate viscosity correction factors using the Hydraulic Institute (HI) method.

      The HI method provides correction factors for flow, head, and efficiency when pumping viscous fluids. The method is valid for:

      • Kinematic viscosity: 4 to 4000 cSt
      • Flow rate at BEP: up to ~760 m³/hr
      • Head per stage: up to ~180 m
      • Single-stage and first-stage of multistage pumps

      Reference: ANSI/HI 9.6.7-2021 "Effects of Liquid Viscosity on Rotodynamic Pump Performance"

      Specified by:
      calculateViscosityCorrection in interface PumpChartInterface
      Parameters:
      viscosity - kinematic viscosity in cSt (centistokes)
      flowBEP - flow at best efficiency point in m³/hr
      headBEP - head at best efficiency point in meters
      speed - pump speed in rpm
    • getViscosityCorrectedFlow

      public double getViscosityCorrectedFlow(double flowWater)
      Get the viscosity-corrected flow rate.

      Q_viscous = Q_water × Cq

      Parameters:
      flowWater - flow rate from water test in m³/hr
      Returns:
      corrected flow rate in m³/hr
    • getViscosityCorrectedHead

      public double getViscosityCorrectedHead(double headWater)
      Get the viscosity-corrected head.

      H_viscous = H_water × Ch

      Parameters:
      headWater - head from water test in meters
      Returns:
      corrected head in meters
    • getViscosityCorrectedEfficiency

      public double getViscosityCorrectedEfficiency(double efficiencyWater)
      Get the viscosity-corrected efficiency.

      η_viscous = η_water × Cη

      Parameters:
      efficiencyWater - efficiency from water test in percent
      Returns:
      corrected efficiency in percent
    • getFullyCorrectedHead

      public double getFullyCorrectedHead(double flow, double speed, double actualDensity, double actualViscosity)
      Get head with both viscosity and density corrections applied.
      Specified by:
      getFullyCorrectedHead in interface PumpChartInterface
      Parameters:
      flow - flow rate in m³/hr
      speed - pump speed in rpm
      actualDensity - actual fluid density in kg/m³
      actualViscosity - actual kinematic viscosity in cSt
      Returns:
      fully corrected head
    • getCorrectedEfficiency

      public double getCorrectedEfficiency(double flow, double speed, double actualViscosity)
      Get efficiency with viscosity correction applied.
      Specified by:
      getCorrectedEfficiency in interface PumpChartInterface
      Parameters:
      flow - flow rate in m³/hr
      speed - pump speed in rpm
      actualViscosity - actual kinematic viscosity in cSt
      Returns:
      corrected efficiency in percent
    • setReferenceViscosity

      public void setReferenceViscosity(double referenceViscosity)
      Set the reference viscosity for viscosity correction.
      Specified by:
      setReferenceViscosity in interface PumpChartInterface
      Parameters:
      referenceViscosity - reference kinematic viscosity in cSt (typically 1.0 for water)
    • getReferenceViscosity

      public double getReferenceViscosity()
      Get the reference viscosity.
      Specified by:
      getReferenceViscosity in interface PumpChartInterface
      Returns:
      reference viscosity in cSt
    • setUseViscosityCorrection

      public void setUseViscosityCorrection(boolean useViscosityCorrection)
      Enable or disable viscosity correction.
      Specified by:
      setUseViscosityCorrection in interface PumpChartInterface
      Parameters:
      useViscosityCorrection - true to enable viscosity correction
    • isUseViscosityCorrection

      public boolean isUseViscosityCorrection()
      Check if viscosity correction is enabled.
      Specified by:
      isUseViscosityCorrection in interface PumpChartInterface
      Returns:
      true if viscosity correction is active
    • getFlowCorrectionFactor

      public double getFlowCorrectionFactor()
      Get the current flow correction factor (Cq).
      Specified by:
      getFlowCorrectionFactor in interface PumpChartInterface
      Returns:
      flow correction factor
    • getHeadCorrectionFactor

      public double getHeadCorrectionFactor()
      Get the current head correction factor (Ch).
      Specified by:
      getHeadCorrectionFactor in interface PumpChartInterface
      Returns:
      head correction factor
    • getEfficiencyCorrectionFactor

      public double getEfficiencyCorrectionFactor()
      Get the current efficiency correction factor (Cη).
      Specified by:
      getEfficiencyCorrectionFactor in interface PumpChartInterface
      Returns:
      efficiency correction factor
    • setHeadUnit

      public void setHeadUnit(String headUnit)
      Set unit of head.
      Specified by:
      setHeadUnit in interface PumpChartInterface
      Parameters:
      headUnit - a String object
    • useRealKappa

      public boolean useRealKappa()
      get method for kappa setting. true = real kappa is used, false = ideal kappa is used
      Specified by:
      useRealKappa in interface PumpChartInterface
      Returns:
      true/false flag
    • setUseRealKappa

      public void setUseRealKappa(boolean useRealKappa)
      set method for kappa setting. true = real kappa is used, false = ideal kappa is used
      Specified by:
      setUseRealKappa in interface PumpChartInterface
      Parameters:
      useRealKappa - a boolean
    • plot

      public void plot()

      plot.

      Specified by:
      plot in interface PumpChartInterface