Browsable Linear Programming Grammar

CC-BY

Grammar extracted by Vadim Zaytsev, see the Grammar Zoo entry for details: api/rascal/linear/extracted
Source used for this grammar: Paul Klint, Jurgen J. Vinju, analysis::linearprogramming::LinearProgramming, 2009–2013 [Explore]

Summary

Syntax

Coefficients ::=
	(⟨var⟩:string ⟨coef⟩:integer)*
LinearExpression ::=
	[linearExp]::(⟨coefficients⟩:Coefficients ⟨const⟩:integer)
ObjectiveFun ::=
	LinearExpression
ConstraintType ::=
	[leq]::ε
	[eq]::ε
	[geq]::ε
Constraint ::=
	[constraint]::(⟨coefficients⟩:Coefficients ⟨ctype⟩:ConstraintType ⟨const⟩:integer)
Constraints ::=
	Constraint*
VariableVals ::=
	(⟨var⟩:string ⟨val⟩:integer)*
Solution ::=
	[solution]::(⟨varVals⟩:VariableVals ⟨funVal⟩:integer)

GrammarLabMaintained by Dr. Vadim Zaytsev a.k.a. @grammarware. Last updated in September 2015. [↑]