a pedagogical implementation of the Simplex method