limp-0.3.2.3: representation of Integer Linear Programs

Safe HaskellNone
LanguageHaskell2010

Numeric.Limp.Canon.Program

Description

Canon representation of linear program

Synopsis

Documentation

data Program z r c Source #

A program represented by objective, constraints and bounds. There is no need for an optimisation direction; the objective is just negated.

Constructors

Program 

Fields

Instances
(Show (Z c), Show (R c), Rep c, Show z, Show r, Ord z, Ord r) => Show (Program z r c) Source # 
Instance details

Defined in Numeric.Limp.Canon.Pretty

Methods

showsPrec :: Int -> Program z r c -> ShowS #

show :: Program z r c -> String #

showList :: [Program z r c] -> ShowS #

varsOfProgram :: (Ord z, Ord r) => Program z r c -> Set (Either z r) Source #

Find set of all variables mentioned in program

mergeBounds :: Rep c => (Maybe (R c), Maybe (R c)) -> (Maybe (R c), Maybe (R c)) -> (Maybe (R c), Maybe (R c)) Source #

Merge some lower and upper bounds

checkProgram :: (Rep c, Ord z, Ord r) => Assignment z r c -> Program z r c -> Bool Source #

Check whether an assignment satisfies the program's constraints and bounds

checkBounds :: (Rep c, Ord z, Ord r) => Assignment z r c -> Map (Either z r) (Maybe (R c), Maybe (R c)) -> Bool Source #