summaryrefslogtreecommitdiff
path: root/glpk-5.0/examples/spxsamp2.c
diff options
context:
space:
mode:
authorPasha <pasha@member.fsf.org>2023-01-27 00:54:07 +0000
committerPasha <pasha@member.fsf.org>2023-01-27 00:54:07 +0000
commitef800d4ffafdbde7d7a172ad73bd984b1695c138 (patch)
tree920cc189130f1e98f252283fce94851443641a6d /glpk-5.0/examples/spxsamp2.c
parentec4ae3c2b5cb0e83fb667f14f832ea94f68ef075 (diff)
downloadoneapi-ef800d4ffafdbde7d7a172ad73bd984b1695c138.tar.gz
oneapi-ef800d4ffafdbde7d7a172ad73bd984b1695c138.tar.bz2
simplex-glpk with modified glpk for fpgaHEADmaster
Diffstat (limited to 'glpk-5.0/examples/spxsamp2.c')
-rw-r--r--glpk-5.0/examples/spxsamp2.c20
1 files changed, 20 insertions, 0 deletions
diff --git a/glpk-5.0/examples/spxsamp2.c b/glpk-5.0/examples/spxsamp2.c
new file mode 100644
index 0000000..f952e74
--- /dev/null
+++ b/glpk-5.0/examples/spxsamp2.c
@@ -0,0 +1,20 @@
+/* spxsamp2.c */
+
+#include <stdio.h>
+#include <stdlib.h>
+#include <glpk.h>
+
+int main(void)
+{ glp_prob *P;
+ glp_smcp parm;
+ P = glp_create_prob();
+ glp_read_mps(P, GLP_MPS_DECK, NULL, "25fv47.mps");
+ glp_init_smcp(&parm);
+ parm.meth = GLP_DUAL;
+ glp_simplex(P, &parm);
+ glp_print_sol(P, "25fv47.txt");
+ glp_delete_prob(P);
+ return 0;
+}
+
+/* eof */