From 4f2818108e5f0b295e91381b730691fcdfb3516e Mon Sep 17 00:00:00 2001 From: Yann Herklotz Date: Sun, 29 Oct 2017 13:13:10 +0000 Subject: Working prototype of simplex --- include/simplex.h | 28 ++++++++++++++++++++++++++++ 1 file changed, 28 insertions(+) (limited to 'include/simplex.h') diff --git a/include/simplex.h b/include/simplex.h index e69de29..22bf1e3 100644 --- a/include/simplex.h +++ b/include/simplex.h @@ -0,0 +1,28 @@ +#ifndef SIMPLEX_H +#define SIMPLEX_H + +#include + +typedef std::vector> BasicRep; + +class Simplex +{ +public: + Simplex(int m, int n); + Simplex(BasicRep basic_rep); + + void initialize(BasicRep basic_rep); + void solve(); + double getMin() const; +private: + BasicRep basic_rep_; + + bool isDone() const; + int inputBasicVar() const; + int outputBasicVar(int column) const; + void rotate(int input, int output); +}; + +extern void printBR(const BasicRep &basic_rep); + +#endif -- cgit