Class LNGRolloverDetector

java.lang.Object
neqsim.process.equipment.lng.LNGRolloverDetector
All Implemented Interfaces:
Serializable

public class LNGRolloverDetector extends Object implements Serializable
Detects rollover risk in stratified LNG tanks.

LNG rollover is a sudden mixing event in a stratified tank where a denser upper layer (formed by preferential evaporation of light components) rapidly exchanges position with a warmer, lighter lower layer (heated by wall ingress). The resulting flash of the superheated lower layer produces a surge of BOG that can exceed the tank's pressure relief capacity.

Detection criteria (based on published LNG rollover incidents and research):

  • Density inversion: Upper layer denser than lower layer by more than a threshold (typically 1-5 kg/m3)
  • Temperature differential: Temperature difference between layers above a threshold (typically 0.5-2.0 K) with lower layer warmer
  • Rayleigh number criterion: Natural convection onset when Ra exceeds critical value (~1700 for horizontal liquid layers)
  • Stability index: Combined density and temperature stratification metric
Version:
1.0
Author:
NeqSim
See Also:
  • Field Details

    • serialVersionUID

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

      private static final org.apache.logging.log4j.Logger logger
      Logger object.
    • densityWarningThreshold

      private double densityWarningThreshold
      Density difference threshold for rollover warning (kg/m3).
    • densityAlarmThreshold

      private double densityAlarmThreshold
      Density difference threshold for rollover alarm (kg/m3).
    • temperatureThreshold

      private double temperatureThreshold
      Temperature difference threshold for rollover concern (K).
    • criticalRayleighNumber

      private double criticalRayleighNumber
      Critical Rayleigh number for convection onset in LNG.
    • thermalExpansionCoeff

      private double thermalExpansionCoeff
      LNG thermal expansion coefficient (1/K). Approximate value for LNG.
    • kinematicViscosity

      private double kinematicViscosity
      LNG kinematic viscosity (m2/s). Approximate for LNG at -160C.
    • thermalDiffusivity

      private double thermalDiffusivity
      LNG thermal diffusivity (m2/s). Approximate for LNG.
    • densityDiffHistory

      private List<Double> densityDiffHistory
      History of density differences for trend extrapolation (most recent last).
    • maxHistoryLength

      private int maxHistoryLength
      Maximum history length for trend analysis.
  • Constructor Details

    • LNGRolloverDetector

      public LNGRolloverDetector()
      Default constructor.
  • Method Details

    • assess

      Assess rollover risk based on current layer state.
      Parameters:
      layers - list of tank layers from bottom to top
      Returns:
      rollover risk assessment
    • calculateRayleighNumber

      public double calculateRayleighNumber(double deltaT, double layerHeight)
      Calculate the Rayleigh number for natural convection onset.

      Ra = g * beta * dT * H^3 / (nu * alpha)

      where g = 9.81 m/s2, beta = thermal expansion coefficient, dT = temperature difference, H = layer height, nu = kinematic viscosity, alpha = thermal diffusivity.

      Parameters:
      deltaT - temperature difference between layers (K)
      layerHeight - height of the layer (m)
      Returns:
      Rayleigh number
    • estimateLayerHeight

      private double estimateLayerHeight(LNGTankLayer layer)
      Estimate the height of a layer based on its volume and tank geometry.

      Assumes a cylindrical tank for simplicity: h = V / (pi * r^2). Default tank diameter 40m gives an approximation.

      Parameters:
      layer - the tank layer
      Returns:
      estimated layer height (m)
    • getDensityWarningThreshold

      public double getDensityWarningThreshold()
      Get density warning threshold.
      Returns:
      threshold (kg/m3)
    • setDensityWarningThreshold

      public void setDensityWarningThreshold(double threshold)
      Set density warning threshold.
      Parameters:
      threshold - threshold (kg/m3)
    • getDensityAlarmThreshold

      public double getDensityAlarmThreshold()
      Get density alarm threshold.
      Returns:
      threshold (kg/m3)
    • setDensityAlarmThreshold

      public void setDensityAlarmThreshold(double threshold)
      Set density alarm threshold.
      Parameters:
      threshold - threshold (kg/m3)
    • getTemperatureThreshold

      public double getTemperatureThreshold()
      Get temperature threshold.
      Returns:
      threshold (K)
    • setTemperatureThreshold

      public void setTemperatureThreshold(double threshold)
      Set temperature threshold.
      Parameters:
      threshold - threshold (K)
    • getCriticalRayleighNumber

      public double getCriticalRayleighNumber()
      Get the critical Rayleigh number.
      Returns:
      critical Rayleigh number
    • setCriticalRayleighNumber

      public void setCriticalRayleighNumber(double criticalRa)
      Set the critical Rayleigh number.
      Parameters:
      criticalRa - critical Rayleigh number
    • setLNGProperties

      public void setLNGProperties(double thermalExpansionCoeff, double kinematicViscosity, double thermalDiffusivity)
      Set LNG physical properties for Rayleigh calculation.
      Parameters:
      thermalExpansionCoeff - thermal expansion coefficient (1/K)
      kinematicViscosity - kinematic viscosity (m2/s)
      thermalDiffusivity - thermal diffusivity (m2/s)
    • estimateTimeToRollover

      private double estimateTimeToRollover(double currentDensityDiff)
      Estimate the time to rollover based on density difference trend.

      Uses linear extrapolation of the density difference history to predict when a density inversion (heavier layer on top) will reach the alarm threshold. Requires at least 3 history points for extrapolation.

      Parameters:
      currentDensityDiff - current density difference (kg/m3)
      Returns:
      estimated hours to rollover, or -1 if no rollover trend detected
    • clearHistory

      public void clearHistory()
      Clear the density difference history.
    • getDensityDiffHistory

      public List<Double> getDensityDiffHistory()
      Get the density difference history for analysis.
      Returns:
      list of historical density differences