Gas Model

All methods for constructing gasmodels should be defined on the following type:

which utilizes the following (internal) functions:

GasModels.build_refFunction

Builds the ref dictionary from the data dictionary. Additionally the ref dictionary would contain fields populated by the optional vector of ref_extensions provided as a keyword argument.

source

When using the build_ref for transient problem formulations the following ref extension has to be added to populate the fields necessary for formulate the transient optimization problems.

Network Formulations

Type Hierarchy

We begin with the top of the hierarchy, where we can distinguish between the physics of gas flow models. There are currently five formulations supported in GasModels. Two full non convex formulations and three relaxations.

AbstractWPModel <: AbstractGasModel
AbstractDWPModel <: AbstractGasModel
AbstractMISOCPModel <: AbstractGasModel
AbstractLRDWPModel <: AbstractGasModel
AbstractLRWPModel <: AbstractGasModel

Gas Models

Each of these forms can be used as the type parameter for a GasModel, i.e.:

WPGasModel <: AbstractWPForm
MIDWPGasModel <: AbstractDWPModel
CRDWPGasModel <: AbstractMISOCPModel
LRDWPGasModel <: AbstractLRDWPModel
LRWPGasModel <: AbstractLRWPModel

For details on AbstractGasModel, see the section on Gas Model.

User-Defined Abstractions

The user-defined abstractions begin from a root abstract like the AbstractGasModel abstract type, i.e.

AbstractMyFooModel <: AbstractGasModel

StandardMyFooForm <: AbstractFooModel
FooGasModel = AbstractGasModel{StandardFooForm}

Supported Formulations

All formulation names refer to how underlying physics of a gas network is modeled. For example, the LRWP model uses a linear representation of natural gas physics. If a model includes valves, then the resulting mathematical optimization problems will be mixed integer since valve controls are discrete.

FormulationSteady-StateTransientDescription
WPYYPhysics is modeled using nonlinear equations.
DWPYNPhysics is modeled using nonlinear equations. Directionality of flow is modeled using discrete variables
CRDWPYNPhysics is modeled using convex equations. Directionality of flow is modeled using discrete variables
LRDWPYNPhysics is modeled using linear equations. Directionality of flow is modeled using discrete variables
LRWPYNPhysics is modeled using linear equations.