Class BowTieModel

java.lang.Object
neqsim.process.safety.risk.bowtie.BowTieModel
All Implemented Interfaces:
Serializable

public class BowTieModel extends Object implements Serializable
Bow-Tie Model representing hazard, threats, consequences, and barriers.

A bow-tie model visualizes the relationship between causes (threats), a central hazardous event (top event), and potential outcomes (consequences), along with the preventive and mitigating barriers in place.

Version:
1.0
Author:
NeqSim Development Team
See Also:
  • Field Details

    • serialVersionUID

      private static final long serialVersionUID
      See Also:
    • hazardId

      private String hazardId
      Hazard identifier.
    • hazardDescription

      private String hazardDescription
      Hazard description (top event).
    • hazardType

      private String hazardType
      Hazard type.
    • threats

      private List<BowTieModel.Threat> threats
      Threats (causes).
    • consequences

      private List<BowTieModel.Consequence> consequences
      Consequences.
    • barriers

      private List<BowTieModel.Barrier> barriers
      Barriers.
    • unmitigatedFrequency

      private double unmitigatedFrequency
      Calculated unmitigated frequency.
    • mitigatedFrequency

      private double mitigatedFrequency
      Calculated mitigated frequency.
    • maxSeverity

      private int maxSeverity
      Maximum consequence severity.
  • Constructor Details

    • BowTieModel

      public BowTieModel(String hazardId, String hazardDescription)
      Creates a bow-tie model.
      Parameters:
      hazardId - hazard identifier
      hazardDescription - hazard description
  • Method Details

    • addThreat

      public void addThreat(BowTieModel.Threat threat)
      Adds a threat.
      Parameters:
      threat - threat to add
    • addConsequence

      public void addConsequence(BowTieModel.Consequence consequence)
      Adds a consequence.
      Parameters:
      consequence - consequence to add
    • addBarrier

      public void addBarrier(BowTieModel.Barrier barrier)
      Adds a barrier.
      Parameters:
      barrier - barrier to add
    • linkBarrierToThreat

      public void linkBarrierToThreat(String threatId, String barrierId)
      Links a barrier to a threat.
      Parameters:
      threatId - threat ID
      barrierId - barrier ID
    • linkBarrierToConsequence

      public void linkBarrierToConsequence(String consequenceId, String barrierId)
      Links a barrier to a consequence.
      Parameters:
      consequenceId - consequence ID
      barrierId - barrier ID
    • calculateRisk

      public void calculateRisk()
      Calculates risk for this bow-tie.
    • getPreventionBarriers

      public List<BowTieModel.Barrier> getPreventionBarriers()
      Gets prevention barriers.
      Returns:
      list of prevention barriers
    • getMitigationBarriers

      public List<BowTieModel.Barrier> getMitigationBarriers()
      Gets mitigation barriers.
      Returns:
      list of mitigation barriers
    • getTotalRRF

      public double getTotalRRF()
      Gets total risk reduction factor.
      Returns:
      total RRF
    • getHazardId

      public String getHazardId()
    • getHazardDescription

      public String getHazardDescription()
    • getHazardType

      public String getHazardType()
    • setHazardType

      public void setHazardType(String type)
    • getThreats

      public List<BowTieModel.Threat> getThreats()
    • getConsequences

      public List<BowTieModel.Consequence> getConsequences()
    • getBarriers

      public List<BowTieModel.Barrier> getBarriers()
    • getUnmitigatedFrequency

      public double getUnmitigatedFrequency()
    • getMitigatedFrequency

      public double getMitigatedFrequency()
    • getMaxSeverity

      public int getMaxSeverity()
    • toVisualization

      public String toVisualization()
      Generates ASCII visualization of bow-tie.
      Returns:
      ASCII diagram
    • toMap

      public Map<String,Object> toMap()
      Converts to map for JSON serialization.
      Returns:
      map representation
    • toJson

      public String toJson()
      Converts to JSON string.
      Returns:
      JSON representation
    • toString

      public String toString()
      Overrides:
      toString in class Object