Papers
Topics
Authors
Recent
2000 character limit reached

Extended Mathematical Programming (EMP)

Updated 12 January 2026
  • Extended Mathematical Programming (EMP) is a modeling extension that embeds equilibrium constraints into algebraic models with structured annotations to capture equilibrium structures.
  • It enables direct formulation of multi-agent problems such as Nash equilibria, variational inequalities, and MOPECs with minimal alterations to the base model.
  • EMP automatically reformulates equilibrium models into complementarity or variational inequality systems, significantly improving computational efficiency and scalability.

Extended Mathematical Programming (EMP) defines a modeling-language extension for formulating and solving high-level equilibrium and variational problems directly within standard algebraic modeling frameworks. EMP provides structured mechanisms to declare complex equilibrium structures—including generalized Nash equilibrium problems, multiple optimization problems with equilibrium constraints (MOPECs), variational inequalities (VIs), and quasi-variational inequalities (QVIs)—enabling automatic reformulation and solution within established software environments such as GAMS/EMP, without manual derivation of KKT or complementarity systems (Kim et al., 2018).

1. Problem Scope and Structural Representation

EMP is designed to capture the structure of multi-agent equilibrium problems, where multiple independent decision-makers (agents) operate with private variables, possibly shared resources, and equilibrium constraints. Traditional algebraic models are extended by annotating variables and equations in an auxiliary “empinfo” side-file, specifying agent ownership, the nature of variables (decision, equilibrium, or implicit), and shared or private constraints. This schema enables precise expression of problem ownership and resource-sharing structures. It supports direct modeling of:

The high-level description provided by EMP allows the solution concept (Nash vs. variational equilibrium, NEP vs. GNEP vs. QVI) to be specified or switched with minimal changes to the modeling code.

2. Core Constructs and Model Annotation

EMP introduces a series of constructs within the empinfo file to communicate the equilibrium structure to the modeling system:

  • equilibrium: Specifies a list of agent-level optimization problems. Syntax per agent:
    1
    2
    
    min objvar decisionVars... definingEqs...
    max ...
    This encodes, for agent ii, the optimization problem minxiKi(xi)fi(xi,xi)\min_{x_i \in K_i(x_{-i})} f_i(x_i, x_{-i}) (or maximization).
  • vi: Declares a variational inequality; syntax:
    1
    
    vi f1 x1 f2 x2 ... constraints...
    Each fkf_k is paired with xkx_k, producing F(x),yx0\langle F(x), y - x \rangle \ge 0 for yKy \in K.
  • qvi: Declares a quasi-variational inequality with variables yy and parameters xx:
    1
    
    qvi F y x h g
    The variable of interest yy resides in the parameter-dependent feasible set K(x)K(x).
  • implicit: Declares a free variable yy whose values are determined by a defining constraint H(y,x)=0H(y,x)=0:
    1
    
    implicit y H
    This construct enables modeling of implicit or shared variables across agents.
  • visol: Requests a variational equilibrium (as opposed to the default GNEP solution), meaning that shared-constraint multipliers are unified across agents.

EMP’s shared-constraint detection automatically recognizes when a constraint appears in multiple agents’ annotations, controlling its treatment as shared (with either individual or common multipliers).

3. Reformulation into Solution-Ready Systems

EMP automatically translates high-level specifications into standard mathematical programs suitable for solvers. The possible reformulations include:

  • Mixed Complementarity Problem (MCP): Given bounds lxul \le x \le u and map F:RnRnF:\mathbb{R}^n \to \mathbb{R}^n, find xx^* such that

lxuF(x)l \le x^* \le u \quad \perp \quad F(x^*)

That is, 0xiliFi(x)uixi00 \le x_i^* - l_i \perp F_i(x^*) \perp u_i - x_i^* \ge 0 for each ii.

  • Variational Inequality (VI): Find xKRnx^* \in K \subset \mathbb{R}^n closed convex,

F(x),xx0,xK\langle F(x^*), x - x^* \rangle \ge 0, \quad \forall x \in K

  • Quasi-Variational Inequality (QVI): With a point-to-set map K()K(\cdot), find xK(x)x^* \in K(x^*),

F(x),xx0,xK(x)\langle F(x^*), x - x^* \rangle \ge 0, \quad \forall x \in K(x^*)

Algebraic definitions of agent cost, constraint, and feasible set functions (fi,hi,gif_i, h_i, g_i) are specified in the model. EMP then builds the KKT conditions and assembles a single complementarity or inequality system for solution. Crucially, no user-supplied derivatives are required; all reformulation is automatic (Kim et al., 2018).

4. Shared Variables and Constraints

EMP introduces the concept of shared variables: variables yy that are determined by a common defining equation H(y,x)=0H(y, x) = 0 and that are referenced by multiple agents. When such variables appear in multiple agents’ feasible sets, at any equilibrium solution it must hold that all agent instances of yy are equal, i.e., y1=y2==yy_1 = y_2 = \cdots = y.

Primary use cases:

  • Sparsity reformulation: Splitting a dense aggregate function, such as p(qik)p(\sum q_{ik}), into a shared variable z=qikz = \sum q_{ik} for computational efficiency.
  • Equilibrium problems with equilibrium constraints (EPECs): State variables satisfying market-clearing or similar shared constraints are modeled as shared variables across agents.
  • Mixed pricing behavior: Declaring prices as implicit shared variables allows agents to flexibly take on price-maker or price-taker roles by including or excluding ownership of the variable.

Shared constraints can be declared by including the same equation name in multiple agents’ annotations or enforced using the SharedEqu option. The visol keyword controls whether shared constraints induce a single multiplier (variational equilibrium) or replicated multipliers (generalized Nash equilibrium) (Kim et al., 2018).

5. Advanced Modeling Techniques

EMP supports several formulations for shared variables in NN-agent games, each with trade-offs between problem size and sparsity:

Formulation Type MCP Dimension Notes
Replication n+2mNn + 2mN Each agent owns a copy yiy_i and multiplier μi\mu_i
Switching n+mN+mn + mN + m Swap yiy_i with μi\mu_i, introduce central yy
Substitution (implicit) n+nm+mn + nm + m Use total-derivative multipliers Λi\Lambda_i if H(y,x)=0H(y,x)=0 admits implicit-function theorem
Substitution (explicit) n+mn + m If H(y,x)=yh(x)H(y,x)=y-h(x), simply substitute y=h(x)y=h(x)

Here, nn is the number of original variables, mm the dimension of yy. Switching and explicit substitution maintain high sparsity but explicit substitution can reintroduce density if mm is not small.

The implicit/explicit variable constructs and the ability to declare mixed pricing behavior (by controlling agent ownership of shared price variables) facilitate sophisticated agent modeling with minimal algebraic remodeling effort.

6. Solution Procedures and Performance Insights

EMP-generated models are passed to complementarity and variational inequality solvers such as PATH, which require the Jacobian of the MCP/VI. EMP exploits the structure exposed by sharing or switching formulations to create and maintain highly sparse Jacobians, which is critical for scalable performance.

Performance studies illustrate:

  • Dense MCPs for large oligopoly models (e.g., with nn plants) have intractable computational complexity (Jacobian density ≈ 100%).
  • The introduction of a shared variable zz and the switching strategy reduces density to ≈ 0.1%, enabling models with up to 50,000 variables to be solved in minutes.
  • Explicit substitution can further reduce problem size (to n+mn + m), most beneficial when mnm \ll n and for sparse problems.
  • In EPEC models with 23 agents and 253 shared variables, switching outperforms replication by a factor of 6 and substitution by an order of magnitude (Kim et al., 2018).

A plausible implication is that careful use of shared variable formulation and structure-exposing modeling strategies can lead to order-of-magnitude improvements in computational tractability for large-scale equilibrium problems.

7. Implementation in GAMS/EMP and Example

Integration with GAMS/EMP allows the following workflow for a simple two-agent Nash equilibrium:

Algebraic model:

1
2
3
4
5
sets i /1*2/;
variables obj(i), x(i);
equations defobj(i);
defobj(i).. obj(i) =e= x(i)**2 + x(i)*x(j);
model nepm /defobj/;

empinfo file:

1
2
3
equilibrium
min obj('1') x('1') defobj('1')
min obj('2') x('2') defobj('2')

Solve call:

1
2
3
%%%%52%%%%echo "min obj('1') x('1') defobj('1')" >> empinfo
$echo "min obj('2') x('2') defobj('2')" >> empinfo
solve nepm using emp;

Switching to VI or including mixed or implicit structures requires only changes in the empinfo file, maintaining a separation between algebraic model and equilibrium structure specification.

In summary, EMP embeds equilibrium-model semantics in standard modeling languages, automates the derivation of complementarity and variational inequality systems (including all necessary KKT and constraint structure), and interfaces with advanced solvers to facilitate large-scale, structurally rich equilibrium computations (Kim et al., 2018).

Definition Search Book Streamline Icon: https://streamlinehq.com
References (1)

Whiteboard

Topic to Video (Beta)

Follow Topic

Get notified by email when new papers are published related to Extended Mathematical Programming (EMP).