Browse Source

bumped version of shipped glpk

main
Tim Quatmann 6 years ago
parent
commit
6008f489e2
  1. BIN
      resources/3rdparty/glpk-4.57/doc/glpk.pdf
  2. BIN
      resources/3rdparty/glpk-4.57/doc/gmpl_es.pdf
  3. BIN
      resources/3rdparty/glpk-4.57/doc/graphs.pdf
  4. BIN
      resources/3rdparty/glpk-4.57/doc/notes/dfeas.pdf
  5. BIN
      resources/3rdparty/glpk-4.57/doc/notes/simplex1.pdf
  6. BIN
      resources/3rdparty/glpk-4.57/doc/notes/simplex2.pdf
  7. 10
      resources/3rdparty/glpk-4.57/examples/glpsol.c
  8. 178
      resources/3rdparty/glpk-4.57/src/Makefile.am
  9. 1235
      resources/3rdparty/glpk-4.57/src/glpapi11.c
  10. 330
      resources/3rdparty/glpk-4.57/src/glpapi16.c
  11. 1269
      resources/3rdparty/glpk-4.57/src/glpapi17.c
  12. 1693
      resources/3rdparty/glpk-4.57/src/glpdmx.c
  13. 190
      resources/3rdparty/glpk-4.57/src/glpgmp.h
  14. 259
      resources/3rdparty/glpk-4.57/src/glpsdf.c
  15. 63
      resources/3rdparty/glpk-4.57/src/glpsdf.h
  16. 222
      resources/3rdparty/glpk-4.57/src/simplex/spychuzc.c
  17. 204
      resources/3rdparty/glpk-4.57/w32/Makefile_VC
  18. 205
      resources/3rdparty/glpk-4.57/w32/Makefile_VC_DLL
  19. 204
      resources/3rdparty/glpk-4.57/w64/makefile_VC
  20. 205
      resources/3rdparty/glpk-4.57/w64/makefile_VC_DLL
  21. 0
      resources/3rdparty/glpk-4.65/AUTHORS
  22. 0
      resources/3rdparty/glpk-4.65/COPYING
  23. 522
      resources/3rdparty/glpk-4.65/ChangeLog
  24. 11
      resources/3rdparty/glpk-4.65/INSTALL
  25. 0
      resources/3rdparty/glpk-4.65/Makefile.am
  26. 1
      resources/3rdparty/glpk-4.65/Makefile.in
  27. 188
      resources/3rdparty/glpk-4.65/NEWS
  28. 20
      resources/3rdparty/glpk-4.65/README
  29. 26
      resources/3rdparty/glpk-4.65/THANKS
  30. 0
      resources/3rdparty/glpk-4.65/aclocal.m4
  31. 27
      resources/3rdparty/glpk-4.65/autogen.sh
  32. 0
      resources/3rdparty/glpk-4.65/config.guess
  33. 3
      resources/3rdparty/glpk-4.65/config.h.in
  34. 0
      resources/3rdparty/glpk-4.65/config.sub
  35. 91
      resources/3rdparty/glpk-4.65/configure
  36. 51
      resources/3rdparty/glpk-4.65/configure.ac
  37. 0
      resources/3rdparty/glpk-4.65/depcomp
  38. 0
      resources/3rdparty/glpk-4.65/doc/cnfsat.pdf
  39. 0
      resources/3rdparty/glpk-4.65/doc/cnfsat.tex
  40. BIN
      resources/3rdparty/glpk-4.65/doc/glpk.pdf
  41. 45
      resources/3rdparty/glpk-4.65/doc/glpk.tex
  42. 31
      resources/3rdparty/glpk-4.65/doc/glpk01.tex
  43. 252
      resources/3rdparty/glpk-4.65/doc/glpk02.tex
  44. 830
      resources/3rdparty/glpk-4.65/doc/glpk03.tex
  45. 37
      resources/3rdparty/glpk-4.65/doc/glpk04.tex
  46. 26
      resources/3rdparty/glpk-4.65/doc/glpk05.tex
  47. 2
      resources/3rdparty/glpk-4.65/doc/glpk06.tex
  48. 0
      resources/3rdparty/glpk-4.65/doc/glpk07.tex
  49. 68
      resources/3rdparty/glpk-4.65/doc/glpk08.tex
  50. 49
      resources/3rdparty/glpk-4.65/doc/glpk09.tex
  51. 5
      resources/3rdparty/glpk-4.65/doc/glpk10.tex
  52. 12
      resources/3rdparty/glpk-4.65/doc/glpk11.tex
  53. 51
      resources/3rdparty/glpk-4.65/doc/glpk12.tex
  54. BIN
      resources/3rdparty/glpk-4.65/doc/gmpl.pdf
  55. 22
      resources/3rdparty/glpk-4.65/doc/gmpl.tex
  56. BIN
      resources/3rdparty/glpk-4.65/doc/gmpl_es.pdf
  57. 22
      resources/3rdparty/glpk-4.65/doc/gmpl_es.tex
  58. BIN
      resources/3rdparty/glpk-4.65/doc/gmpl_pt-BR.pdf
  59. 7893
      resources/3rdparty/glpk-4.65/doc/gmpl_pt-BR.tex
  60. BIN
      resources/3rdparty/glpk-4.65/doc/graphs.pdf
  61. 266
      resources/3rdparty/glpk-4.65/doc/graphs.tex
  62. 0
      resources/3rdparty/glpk-4.65/doc/miplib2.txt
  63. 0
      resources/3rdparty/glpk-4.65/doc/miplib3.txt
  64. 0
      resources/3rdparty/glpk-4.65/doc/netlib.txt
  65. 0
      resources/3rdparty/glpk-4.65/doc/notes/gomory.pdf
  66. 0
      resources/3rdparty/glpk-4.65/doc/notes/keller.pdf
  67. 0
      resources/3rdparty/glpk-4.65/doc/notes/scf.pdf
  68. BIN
      resources/3rdparty/glpk-4.65/doc/notes/simplex1.pdf
  69. BIN
      resources/3rdparty/glpk-4.65/doc/notes/simplex2.pdf
  70. 283
      resources/3rdparty/glpk-4.65/doc/npp.txt
  71. 11
      resources/3rdparty/glpk-4.65/examples/INDEX
  72. 2
      resources/3rdparty/glpk-4.65/examples/Makefile.am
  73. 3
      resources/3rdparty/glpk-4.65/examples/Makefile.in
  74. 0
      resources/3rdparty/glpk-4.65/examples/alloy.mps
  75. 0
      resources/3rdparty/glpk-4.65/examples/assign.mod
  76. 0
      resources/3rdparty/glpk-4.65/examples/bpp.mod
  77. 0
      resources/3rdparty/glpk-4.65/examples/cal.mod
  78. 0
      resources/3rdparty/glpk-4.65/examples/cf12a.mod
  79. 0
      resources/3rdparty/glpk-4.65/examples/cf12b.mod
  80. 0
      resources/3rdparty/glpk-4.65/examples/cflsq.mod
  81. 0
      resources/3rdparty/glpk-4.65/examples/color.mod
  82. 0
      resources/3rdparty/glpk-4.65/examples/cplex/README
  83. 0
      resources/3rdparty/glpk-4.65/examples/cplex/concorde.txt
  84. 0
      resources/3rdparty/glpk-4.65/examples/cplex/cplex.c
  85. 0
      resources/3rdparty/glpk-4.65/examples/cplex/cplex.h
  86. 0
      resources/3rdparty/glpk-4.65/examples/cpp.mod
  87. 0
      resources/3rdparty/glpk-4.65/examples/crypto.mod
  88. 0
      resources/3rdparty/glpk-4.65/examples/csv/distances.csv
  89. 0
      resources/3rdparty/glpk-4.65/examples/csv/markets.csv
  90. 0
      resources/3rdparty/glpk-4.65/examples/csv/parameters.csv
  91. 0
      resources/3rdparty/glpk-4.65/examples/csv/plants.csv
  92. 0
      resources/3rdparty/glpk-4.65/examples/csv/transp_csv.mod
  93. 0
      resources/3rdparty/glpk-4.65/examples/dbf/ForestMgt_Model_I_GIS_dbf.mod
  94. 0
      resources/3rdparty/glpk-4.65/examples/dbf/Forest_Cost.dbf
  95. 0
      resources/3rdparty/glpk-4.65/examples/dbf/NetRev_Table.dbf
  96. 0
      resources/3rdparty/glpk-4.65/examples/dbf/README
  97. 0
      resources/3rdparty/glpk-4.65/examples/dbf/TCost_Table.dbf
  98. 0
      resources/3rdparty/glpk-4.65/examples/dbf/Yield_Table_Vol.dbf
  99. 0
      resources/3rdparty/glpk-4.65/examples/dbf/cultural_pres.dbf
  100. 0
      resources/3rdparty/glpk-4.65/examples/dbf/mgt_year.dbf

BIN
resources/3rdparty/glpk-4.57/doc/glpk.pdf

BIN
resources/3rdparty/glpk-4.57/doc/gmpl_es.pdf

BIN
resources/3rdparty/glpk-4.57/doc/graphs.pdf

BIN
resources/3rdparty/glpk-4.57/doc/notes/dfeas.pdf

BIN
resources/3rdparty/glpk-4.57/doc/notes/simplex1.pdf

BIN
resources/3rdparty/glpk-4.57/doc/notes/simplex2.pdf

10
resources/3rdparty/glpk-4.57/examples/glpsol.c

@ -1,10 +0,0 @@
/* glpsol.c */
#include <glpk.h>
int main(int argc, const char *argv[])
{ /* stand-alone LP/MIP solver */
return glp_main(argc, argv);
}
/* eof */

178
resources/3rdparty/glpk-4.57/src/Makefile.am

@ -1,178 +0,0 @@
## Process this file with automake to produce Makefile.in ##
include_HEADERS = glpk.h
lib_LTLIBRARIES = libglpk.la
libglpk_la_CPPFLAGS = \
-I$(srcdir) \
-I$(srcdir)/amd \
-I$(srcdir)/bflib \
-I$(srcdir)/cglib \
-I$(srcdir)/colamd \
-I$(srcdir)/env \
-I$(srcdir)/minisat \
-I$(srcdir)/misc \
-I$(srcdir)/proxy \
-I$(srcdir)/simplex \
-I$(srcdir)/zlib
libglpk_la_LDFLAGS = \
-version-info 38:0:2 \
-export-symbols-regex '^glp_*'
libglpk_la_SOURCES = \
avl.c \
bfd.c \
bfx.c \
glpapi01.c \
glpapi02.c \
glpapi03.c \
glpapi04.c \
glpapi05.c \
glpapi06.c \
glpapi07.c \
glpapi08.c \
glpapi09.c \
glpapi10.c \
glpapi11.c \
glpapi12.c \
glpapi13.c \
glpapi14.c \
glpapi15.c \
glpapi16.c \
glpapi17.c \
glpapi18.c \
glpapi19.c \
glpapi20.c \
glpapi21.c \
glpcpx.c \
glpdmx.c \
glpgmp.c \
glphbm.c \
glpini01.c \
glpini02.c \
glpios01.c \
glpios02.c \
glpios03.c \
glpios04.c \
glpios05.c \
glpios06.c \
glpios07.c \
glpios08.c \
glpios09.c \
glpios10.c \
glpios11.c \
glpios12.c \
glpipm.c \
glpmat.c \
glpmpl01.c \
glpmpl02.c \
glpmpl03.c \
glpmpl04.c \
glpmpl05.c \
glpmpl06.c \
glpmps.c \
glpnet03.c \
glpnet04.c \
glpnet05.c \
glpnpp01.c \
glpnpp02.c \
glpnpp03.c \
glpnpp04.c \
glpnpp05.c \
glpnpp06.c \
glprgr.c \
glpscl.c \
glpsdf.c \
glpspm.c \
glpsql.c \
glpssx01.c \
glpssx02.c \
lux.c \
amd/amd_1.c \
amd/amd_2.c \
amd/amd_aat.c \
amd/amd_control.c \
amd/amd_defaults.c \
amd/amd_dump.c \
amd/amd_info.c \
amd/amd_order.c \
amd/amd_post_tree.c \
amd/amd_postorder.c \
amd/amd_preprocess.c \
amd/amd_valid.c \
bflib/btf.c \
bflib/btfint.c \
bflib/fhv.c \
bflib/fhvint.c \
bflib/ifu.c \
bflib/luf.c \
bflib/lufint.c \
bflib/scf.c \
bflib/scfint.c \
bflib/sgf.c \
bflib/sva.c \
cglib/cfg.c \
cglib/cfg1.c \
colamd/colamd.c \
env/alloc.c \
env/dlsup.c \
env/env.c \
env/error.c \
env/stdout.c \
env/stream.c \
env/time.c \
env/tls.c \
minisat/minisat.c \
misc/bignum.c \
misc/dmp.c \
misc/ffalg.c \
misc/fp2rat.c \
misc/gcd.c \
misc/jd.c \
misc/keller.c \
misc/mc13d.c \
misc/mc21a.c \
misc/okalg.c \
misc/qmd.c \
misc/relax4.c \
misc/rng.c \
misc/rng1.c \
misc/round2n.c \
misc/str2int.c \
misc/str2num.c \
misc/strspx.c \
misc/strtrim.c \
misc/triang.c \
misc/wclique.c \
misc/wclique1.c \
proxy/proxy.c \
proxy/proxy1.c \
simplex/spxat.c \
simplex/spxchuzc.c \
simplex/spxchuzr.c \
simplex/spxlp.c \
simplex/spxnt.c \
simplex/spxprim.c \
simplex/spxprob.c \
simplex/spychuzc.c \
simplex/spychuzr.c \
simplex/spydual.c \
zlib/adler32.c \
zlib/compress.c \
zlib/crc32.c \
zlib/deflate.c \
zlib/gzclose.c \
zlib/gzlib.c \
zlib/gzread.c \
zlib/gzwrite.c \
zlib/inffast.c \
zlib/inflate.c \
zlib/inftrees.c \
zlib/trees.c \
zlib/uncompr.c \
zlib/zio.c \
zlib/zutil.c
## eof ##

1235
resources/3rdparty/glpk-4.57/src/glpapi11.c
File diff suppressed because it is too large
View File

330
resources/3rdparty/glpk-4.57/src/glpapi16.c

@ -1,330 +0,0 @@
/* glpapi16.c (graph and network analysis routines) */
/***********************************************************************
* This code is part of GLPK (GNU Linear Programming Kit).
*
* Copyright (C) 2000, 2001, 2002, 2003, 2004, 2005, 2006, 2007, 2008,
* 2009, 2010, 2011, 2013 Andrew Makhorin, Department for Applied
* Informatics, Moscow Aviation Institute, Moscow, Russia. All rights
* reserved. E-mail: <mao@gnu.org>.
*
* GLPK is free software: you can redistribute it and/or modify it
* under the terms of the GNU General Public License as published by
* the Free Software Foundation, either version 3 of the License, or
* (at your option) any later version.
*
* GLPK is distributed in the hope that it will be useful, but WITHOUT
* ANY WARRANTY; without even the implied warranty of MERCHANTABILITY
* or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public
* License for more details.
*
* You should have received a copy of the GNU General Public License
* along with GLPK. If not, see <http://www.gnu.org/licenses/>.
***********************************************************************/
#include "env.h"
#include "mc13d.h"
#include "prob.h"
/***********************************************************************
* NAME
*
* glp_weak_comp - find all weakly connected components of graph
*
* SYNOPSIS
*
* int glp_weak_comp(glp_graph *G, int v_num);
*
* DESCRIPTION
*
* The routine glp_weak_comp finds all weakly connected components of
* the specified graph.
*
* The parameter v_num specifies an offset of the field of type int
* in the vertex data block, to which the routine stores the number of
* a (weakly) connected component containing that vertex. If v_num < 0,
* no component numbers are stored.
*
* The components are numbered in arbitrary order from 1 to nc, where
* nc is the total number of components found, 0 <= nc <= |V|.
*
* RETURNS
*
* The routine returns nc, the total number of components found. */
int glp_weak_comp(glp_graph *G, int v_num)
{ glp_vertex *v;
glp_arc *a;
int f, i, j, nc, nv, pos1, pos2, *prev, *next, *list;
if (v_num >= 0 && v_num > G->v_size - (int)sizeof(int))
xerror("glp_weak_comp: v_num = %d; invalid offset\n", v_num);
nv = G->nv;
if (nv == 0)
{ nc = 0;
goto done;
}
/* allocate working arrays */
prev = xcalloc(1+nv, sizeof(int));
next = xcalloc(1+nv, sizeof(int));
list = xcalloc(1+nv, sizeof(int));
/* if vertex i is unlabelled, prev[i] is the index of previous
unlabelled vertex, and next[i] is the index of next unlabelled
vertex; if vertex i is labelled, then prev[i] < 0, and next[i]
is the connected component number */
/* initially all vertices are unlabelled */
f = 1;
for (i = 1; i <= nv; i++)
prev[i] = i - 1, next[i] = i + 1;
next[nv] = 0;
/* main loop (until all vertices have been labelled) */
nc = 0;
while (f != 0)
{ /* take an unlabelled vertex */
i = f;
/* and remove it from the list of unlabelled vertices */
f = next[i];
if (f != 0) prev[f] = 0;
/* label the vertex; it begins a new component */
prev[i] = -1, next[i] = ++nc;
/* breadth first search */
list[1] = i, pos1 = pos2 = 1;
while (pos1 <= pos2)
{ /* dequeue vertex i */
i = list[pos1++];
/* consider all arcs incoming to vertex i */
for (a = G->v[i]->in; a != NULL; a = a->h_next)
{ /* vertex j is adjacent to vertex i */
j = a->tail->i;
if (prev[j] >= 0)
{ /* vertex j is unlabelled */
/* remove it from the list of unlabelled vertices */
if (prev[j] == 0)
f = next[j];
else
next[prev[j]] = next[j];
if (next[j] == 0)
;
else
prev[next[j]] = prev[j];
/* label the vertex */
prev[j] = -1, next[j] = nc;
/* and enqueue it for further consideration */
list[++pos2] = j;
}
}
/* consider all arcs outgoing from vertex i */
for (a = G->v[i]->out; a != NULL; a = a->t_next)
{ /* vertex j is adjacent to vertex i */
j = a->head->i;
if (prev[j] >= 0)
{ /* vertex j is unlabelled */
/* remove it from the list of unlabelled vertices */
if (prev[j] == 0)
f = next[j];
else
next[prev[j]] = next[j];
if (next[j] == 0)
;
else
prev[next[j]] = prev[j];
/* label the vertex */
prev[j] = -1, next[j] = nc;
/* and enqueue it for further consideration */
list[++pos2] = j;
}
}
}
}
/* store component numbers */
if (v_num >= 0)
{ for (i = 1; i <= nv; i++)
{ v = G->v[i];
memcpy((char *)v->data + v_num, &next[i], sizeof(int));
}
}
/* free working arrays */
xfree(prev);
xfree(next);
xfree(list);
done: return nc;
}
/***********************************************************************
* NAME
*
* glp_strong_comp - find all strongly connected components of graph
*
* SYNOPSIS
*
* int glp_strong_comp(glp_graph *G, int v_num);
*
* DESCRIPTION
*
* The routine glp_strong_comp finds all strongly connected components
* of the specified graph.
*
* The parameter v_num specifies an offset of the field of type int
* in the vertex data block, to which the routine stores the number of
* a strongly connected component containing that vertex. If v_num < 0,
* no component numbers are stored.
*
* The components are numbered in arbitrary order from 1 to nc, where
* nc is the total number of components found, 0 <= nc <= |V|. However,
* the component numbering has the property that for every arc (i->j)
* in the graph the condition num(i) >= num(j) holds.
*
* RETURNS
*
* The routine returns nc, the total number of components found. */
int glp_strong_comp(glp_graph *G, int v_num)
{ glp_vertex *v;
glp_arc *a;
int i, k, last, n, na, nc, *icn, *ip, *lenr, *ior, *ib, *lowl,
*numb, *prev;
if (v_num >= 0 && v_num > G->v_size - (int)sizeof(int))
xerror("glp_strong_comp: v_num = %d; invalid offset\n",
v_num);
n = G->nv;
if (n == 0)
{ nc = 0;
goto done;
}
na = G->na;
icn = xcalloc(1+na, sizeof(int));
ip = xcalloc(1+n, sizeof(int));
lenr = xcalloc(1+n, sizeof(int));
ior = xcalloc(1+n, sizeof(int));
ib = xcalloc(1+n, sizeof(int));
lowl = xcalloc(1+n, sizeof(int));
numb = xcalloc(1+n, sizeof(int));
prev = xcalloc(1+n, sizeof(int));
k = 1;
for (i = 1; i <= n; i++)
{ v = G->v[i];
ip[i] = k;
for (a = v->out; a != NULL; a = a->t_next)
icn[k++] = a->head->i;
lenr[i] = k - ip[i];
}
xassert(na == k-1);
nc = mc13d(n, icn, ip, lenr, ior, ib, lowl, numb, prev);
if (v_num >= 0)
{ xassert(ib[1] == 1);
for (k = 1; k <= nc; k++)
{ last = (k < nc ? ib[k+1] : n+1);
xassert(ib[k] < last);
for (i = ib[k]; i < last; i++)
{ v = G->v[ior[i]];
memcpy((char *)v->data + v_num, &k, sizeof(int));
}
}
}
xfree(icn);
xfree(ip);
xfree(lenr);
xfree(ior);
xfree(ib);
xfree(lowl);
xfree(numb);
xfree(prev);
done: return nc;
}
/***********************************************************************
* NAME
*
* glp_top_sort - topological sorting of acyclic digraph
*
* SYNOPSIS
*
* int glp_top_sort(glp_graph *G, int v_num);
*
* DESCRIPTION
*
* The routine glp_top_sort performs topological sorting of vertices of
* the specified acyclic digraph.
*
* The parameter v_num specifies an offset of the field of type int in
* the vertex data block, to which the routine stores the vertex number
* assigned. If v_num < 0, vertex numbers are not stored.
*
* The vertices are numbered from 1 to n, where n is the total number
* of vertices in the graph. The vertex numbering has the property that
* for every arc (i->j) in the graph the condition num(i) < num(j)
* holds. Special case num(i) = 0 means that vertex i is not assigned a
* number, because the graph is *not* acyclic.
*
* RETURNS
*
* If the graph is acyclic and therefore all the vertices have been
* assigned numbers, the routine glp_top_sort returns zero. Otherwise,
* if the graph is not acyclic, the routine returns the number of
* vertices which have not been numbered, i.e. for which num(i) = 0. */
static int top_sort(glp_graph *G, int num[])
{ glp_arc *a;
int i, j, cnt, top, *stack, *indeg;
/* allocate working arrays */
indeg = xcalloc(1+G->nv, sizeof(int));
stack = xcalloc(1+G->nv, sizeof(int));
/* determine initial indegree of each vertex; push into the stack
the vertices having zero indegree */
top = 0;
for (i = 1; i <= G->nv; i++)
{ num[i] = indeg[i] = 0;
for (a = G->v[i]->in; a != NULL; a = a->h_next)
indeg[i]++;
if (indeg[i] == 0)
stack[++top] = i;
}
/* assign numbers to vertices in the sorted order */
cnt = 0;
while (top > 0)
{ /* pull vertex i from the stack */
i = stack[top--];
/* it has zero indegree in the current graph */
xassert(indeg[i] == 0);
/* so assign it a next number */
xassert(num[i] == 0);
num[i] = ++cnt;
/* remove vertex i from the current graph, update indegree of
its adjacent vertices, and push into the stack new vertices
whose indegree becomes zero */
for (a = G->v[i]->out; a != NULL; a = a->t_next)
{ j = a->head->i;
/* there exists arc (i->j) in the graph */
xassert(indeg[j] > 0);
indeg[j]--;
if (indeg[j] == 0)
stack[++top] = j;
}
}
/* free working arrays */
xfree(indeg);
xfree(stack);
return G->nv - cnt;
}
int glp_top_sort(glp_graph *G, int v_num)
{ glp_vertex *v;
int i, cnt, *num;
if (v_num >= 0 && v_num > G->v_size - (int)sizeof(int))
xerror("glp_top_sort: v_num = %d; invalid offset\n", v_num);
if (G->nv == 0)
{ cnt = 0;
goto done;
}
num = xcalloc(1+G->nv, sizeof(int));
cnt = top_sort(G, num);
if (v_num >= 0)
{ for (i = 1; i <= G->nv; i++)
{ v = G->v[i];
memcpy((char *)v->data + v_num, &num[i], sizeof(int));
}
}
xfree(num);
done: return cnt;
}
/* eof */

1269
resources/3rdparty/glpk-4.57/src/glpapi17.c
File diff suppressed because it is too large
View File

1693
resources/3rdparty/glpk-4.57/src/glpdmx.c
File diff suppressed because it is too large
View File

190
resources/3rdparty/glpk-4.57/src/glpgmp.h

@ -1,190 +0,0 @@
/* glpgmp.h (bignum arithmetic) */
/***********************************************************************
* This code is part of GLPK (GNU Linear Programming Kit).
*
* Copyright (C) 2000, 2001, 2002, 2003, 2004, 2005, 2006, 2007, 2008,
* 2009, 2010, 2011, 2013 Andrew Makhorin, Department for Applied
* Informatics, Moscow Aviation Institute, Moscow, Russia. All rights
* reserved. E-mail: <mao@gnu.org>.
*
* GLPK is free software: you can redistribute it and/or modify it
* under the terms of the GNU General Public License as published by
* the Free Software Foundation, either version 3 of the License, or
* (at your option) any later version.
*
* GLPK is distributed in the hope that it will be useful, but WITHOUT
* ANY WARRANTY; without even the implied warranty of MERCHANTABILITY
* or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public
* License for more details.
*
* You should have received a copy of the GNU General Public License
* along with GLPK. If not, see <http://www.gnu.org/licenses/>.
***********************************************************************/
#ifndef GLPGMP_H
#define GLPGMP_H
#ifdef HAVE_CONFIG_H
#include <config.h>
#endif
#ifdef HAVE_GMP /* use GNU MP bignum library */
#include <gmp.h>
#define gmp_pool_count _glp_gmp_pool_count
#define gmp_free_mem _glp_gmp_free_mem
int gmp_pool_count(void);
void gmp_free_mem(void);
#else /* use GLPK bignum module */
/*----------------------------------------------------------------------
// INTEGER NUMBERS
//
// Depending on its magnitude an integer number of arbitrary precision
// is represented either in short format or in long format.
//
// Short format corresponds to the int type and allows representing
// integer numbers in the range [-(2^31-1), +(2^31-1)]. Note that for
// the most negative number of int type the short format is not used.
//
// In long format integer numbers are represented using the positional
// system with the base (radix) 2^16 = 65536:
//
// x = (-1)^s sum{j in 0..n-1} d[j] * 65536^j,
//
// where x is the integer to be represented, s is its sign (+1 or -1),
// d[j] are its digits (0 <= d[j] <= 65535).
//
// RATIONAL NUMBERS
//
// A rational number is represented as an irreducible fraction:
//
// p / q,
//
// where p (numerator) and q (denominator) are integer numbers (q > 0)
// having no common divisors. */
struct mpz
{ /* integer number */
int val;
/* if ptr is a null pointer, the number is in short format, and
val is its value; otherwise, the number is in long format, and
val is its sign (+1 or -1) */
struct mpz_seg *ptr;
/* pointer to the linked list of the number segments ordered in
ascending of powers of the base */
};
struct mpz_seg
{ /* integer number segment */
unsigned short d[6];
/* six digits of the number ordered in ascending of powers of the
base */
struct mpz_seg *next;
/* pointer to the next number segment */
};
struct mpq
{ /* rational number (p / q) */
struct mpz p;
/* numerator */
struct mpz q;
/* denominator */
};
typedef struct mpz *mpz_t;
typedef struct mpq *mpq_t;
#define gmp_get_atom _glp_gmp_get_atom
#define gmp_free_atom _glp_gmp_free_atom
#define gmp_pool_count _glp_gmp_pool_count
#define gmp_get_work _glp_gmp_get_work
#define gmp_free_mem _glp_gmp_free_mem
#define _mpz_init _glp_mpz_init
#define mpz_clear _glp_mpz_clear
#define mpz_set _glp_mpz_set
#define mpz_set_si _glp_mpz_set_si
#define mpz_get_d _glp_mpz_get_d
#define mpz_get_d_2exp _glp_mpz_get_d_2exp
#define mpz_swap _glp_mpz_swap
#define mpz_add _glp_mpz_add
#define mpz_sub _glp_mpz_sub
#define mpz_mul _glp_mpz_mul
#define mpz_neg _glp_mpz_neg
#define mpz_abs _glp_mpz_abs
#define mpz_div _glp_mpz_div
#define mpz_gcd _glp_mpz_gcd
#define mpz_cmp _glp_mpz_cmp
#define mpz_sgn _glp_mpz_sgn
#define mpz_out_str _glp_mpz_out_str
#define _mpq_init _glp_mpq_init
#define mpq_clear _glp_mpq_clear
#define mpq_canonicalize _glp_mpq_canonicalize
#define mpq_set _glp_mpq_set
#define mpq_set_si _glp_mpq_set_si
#define mpq_get_d _glp_mpq_get_d
#define mpq_set_d _glp_mpq_set_d
#define mpq_add _glp_mpq_add
#define mpq_sub _glp_mpq_sub
#define mpq_mul _glp_mpq_mul
#define mpq_div _glp_mpq_div
#define mpq_neg _glp_mpq_neg
#define mpq_abs _glp_mpq_abs
#define mpq_cmp _glp_mpq_cmp
#define mpq_sgn _glp_mpq_sgn
#define mpq_out_str _glp_mpq_out_str
void *gmp_get_atom(int size);
void gmp_free_atom(void *ptr, int size);
int gmp_pool_count(void);
unsigned short *gmp_get_work(int size);
void gmp_free_mem(void);
mpz_t _mpz_init(void);
#define mpz_init(x) (void)((x) = _mpz_init())
void mpz_clear(mpz_t x);
void mpz_set(mpz_t z, mpz_t x);
void mpz_set_si(mpz_t x, int val);
double mpz_get_d(mpz_t x);
double mpz_get_d_2exp(int *exp, mpz_t x);
void mpz_swap(mpz_t x, mpz_t y);
void mpz_add(mpz_t, mpz_t, mpz_t);
void mpz_sub(mpz_t, mpz_t, mpz_t);
void mpz_mul(mpz_t, mpz_t, mpz_t);
void mpz_neg(mpz_t z, mpz_t x);
void mpz_abs(mpz_t z, mpz_t x);
void mpz_div(mpz_t q, mpz_t r, mpz_t x, mpz_t y);
void mpz_gcd(mpz_t z, mpz_t x, mpz_t y);
int mpz_cmp(mpz_t x, mpz_t y);
int mpz_sgn(mpz_t x);
int mpz_out_str(void *fp, int base, mpz_t x);
mpq_t _mpq_init(void);
#define mpq_init(x) (void)((x) = _mpq_init())
void mpq_clear(mpq_t x);
void mpq_canonicalize(mpq_t x);
void mpq_set(mpq_t z, mpq_t x);
void mpq_set_si(mpq_t x, int p, unsigned int q);
double mpq_get_d(mpq_t x);
void mpq_set_d(mpq_t x, double val);
void mpq_add(mpq_t z, mpq_t x, mpq_t y);
void mpq_sub(mpq_t z, mpq_t x, mpq_t y);
void mpq_mul(mpq_t z, mpq_t x, mpq_t y);
void mpq_div(mpq_t z, mpq_t x, mpq_t y);
void mpq_neg(mpq_t z, mpq_t x);
void mpq_abs(mpq_t z, mpq_t x);
int mpq_cmp(mpq_t x, mpq_t y);
int mpq_sgn(mpq_t x);
int mpq_out_str(void *fp, int base, mpq_t x);
#endif
#endif
/* eof */

259
resources/3rdparty/glpk-4.57/src/glpsdf.c

@ -1,259 +0,0 @@
/* glpsdf.c (plain data file reading routines) */
/***********************************************************************
* This code is part of GLPK (GNU Linear Programming Kit).
*
* Copyright (C) 2000, 2001, 2002, 2003, 2004, 2005, 2006, 2007, 2008,
* 2009, 2010, 2011, 2013 Andrew Makhorin, Department for Applied
* Informatics, Moscow Aviation Institute, Moscow, Russia. All rights
* reserved. E-mail: <mao@gnu.org>.
*
* GLPK is free software: you can redistribute it and/or modify it
* under the terms of the GNU General Public License as published by
* the Free Software Foundation, either version 3 of the License, or
* (at your option) any later version.
*
* GLPK is distributed in the hope that it will be useful, but WITHOUT
* ANY WARRANTY; without even the implied warranty of MERCHANTABILITY
* or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public
* License for more details.
*
* You should have received a copy of the GNU General Public License
* along with GLPK. If not, see <http://www.gnu.org/licenses/>.
***********************************************************************/
#include "env.h"
#include "glpsdf.h"
#include "misc.h"
struct glp_data
{ /* plain data file */
char *fname;
/* name of data file */
glp_file *fp;
/* stream assigned to data file */
void *jump; /* jmp_buf jump; */
/* label for go to in case of error */
int count;
/* line count */
int c;
/* current character of EOF */
char item[255+1];
/* current data item */
};
static void next_char(glp_data *data);
glp_data *glp_sdf_open_file(const char *fname)
{ /* open plain data file */
glp_data *data = NULL;
glp_file *fp;
jmp_buf jump;
fp = glp_open(fname, "r");
if (fp == NULL)
{ xprintf("Unable to open '%s' - %s\n", fname, get_err_msg());
goto done;
}
data = xmalloc(sizeof(glp_data));
data->fname = xmalloc(strlen(fname)+1);
strcpy(data->fname, fname);
data->fp = fp;
data->jump = NULL;
data->count = 0;
data->c = '\n';
data->item[0] = '\0';
/* read the very first character */
if (setjmp(jump))
{ glp_sdf_close_file(data);
data = NULL;
goto done;
}
data->jump = jump;
next_char(data);
data->jump = NULL;
done: return data;
}
void glp_sdf_set_jump(glp_data *data, void *jump)
{ /* set up error handling */
data->jump = jump;
return;
}
void glp_sdf_error(glp_data *data, const char *fmt, ...)
{ /* print error message */
va_list arg;
xprintf("%s:%d: ", data->fname, data->count);
va_start(arg, fmt);
xvprintf(fmt, arg);
va_end(arg);
if (data->jump == NULL)
xerror("");
else
longjmp(data->jump, 1);
/* no return */
}
void glp_sdf_warning(glp_data *data, const char *fmt, ...)
{ /* print warning message */
va_list arg;
xprintf("%s:%d: warning: ", data->fname, data->count);
va_start(arg, fmt);
xvprintf(fmt, arg);
va_end(arg);
return;
}
static void next_char(glp_data *data)
{ /* read next character */
int c;
if (data->c == EOF)
glp_sdf_error(data, "unexpected end of file\n");
else if (data->c == '\n')
data->count++;
c = glp_getc(data->fp);
if (c < 0)
{ if (glp_ioerr(data->fp))
glp_sdf_error(data, "read error - %s\n", get_err_msg());
else if (data->c == '\n')
c = EOF;
else
{ glp_sdf_warning(data, "missing final end of line\n");
c = '\n';
}
}
else if (c == '\n')
;
else if (isspace(c))
c = ' ';
else if (iscntrl(c))
glp_sdf_error(data, "invalid control character 0x%02X\n", c);
data->c = c;
return;
}
static void skip_pad(glp_data *data)
{ /* skip uninteresting characters and comments */
loop: while (data->c == ' ' || data->c == '\n')
next_char(data);
if (data->c == '/')
{ next_char(data);
if (data->c != '*')
glp_sdf_error(data, "invalid use of slash\n");
next_char(data);
for (;;)
{ if (data->c == '*')
{ next_char(data);
if (data->c == '/')
{ next_char(data);
break;
}
}
next_char(data);
}
goto loop;
}
return;
}
static void next_item(glp_data *data)
{ /* read next item */
int len;
skip_pad(data);
len = 0;
while (!(data->c == ' ' || data->c == '\n'))
{ data->item[len++] = (char)data->c;
if (len == sizeof(data->item))
glp_sdf_error(data, "data item '%.31s...' too long\n",
data->item);
next_char(data);
}
data->item[len] = '\0';
return;
}
int glp_sdf_read_int(glp_data *data)
{ /* read integer number */
int x;
next_item(data);
switch (str2int(data->item, &x))
{ case 0:
break;
case 1:
glp_sdf_error(data, "integer '%s' out of range\n",
data->item);
case 2:
glp_sdf_error(data, "cannot convert '%s' to integer\n",
data->item);
default:
xassert(data != data);
}
return x;
}
double glp_sdf_read_num(glp_data *data)
{ /* read floating-point number */
double x;
next_item(data);
switch (str2num(data->item, &x))
{ case 0:
break;
case 1:
glp_sdf_error(data, "number '%s' out of range\n",
data->item);
case 2:
glp_sdf_error(data, "cannot convert '%s' to number\n",
data->item);
default:
xassert(data != data);
}
return x;
}
const char *glp_sdf_read_item(glp_data *data)
{ /* read data item */
next_item(data);
return data->item;
}
const char *glp_sdf_read_text(glp_data *data)
{ /* read text until end of line */
int c, len = 0;
for (;;)
{ c = data->c;
next_char(data);
if (c == ' ')
{ /* ignore initial spaces */
if (len == 0) continue;
/* and multiple ones */
if (data->item[len-1] == ' ') continue;
}
else if (c == '\n')
{ /* remove trailing space */
if (len > 0 && data->item[len-1] == ' ') len--;
/* and stop reading */
break;
}
/* add current character to the buffer */
data->item[len++] = (char)c;
if (len == sizeof(data->item))
glp_sdf_error(data, "line too long\n", data->item);
}
data->item[len] = '\0';
return data->item;
}
int glp_sdf_line(glp_data *data)
{ /* determine current line number */
return data->count;
}
void glp_sdf_close_file(glp_data *data)
{ /* close plain data file */
glp_close(data->fp);
xfree(data->fname);
xfree(data);
return;
}
/* eof */

63
resources/3rdparty/glpk-4.57/src/glpsdf.h

@ -1,63 +0,0 @@
/* glpsdf.h */
/***********************************************************************
* This code is part of GLPK (GNU Linear Programming Kit).
*
* Copyright (C) 2000, 2001, 2002, 2003, 2004, 2005, 2006, 2007, 2008,
* 2009, 2010, 2011, 2013 Andrew Makhorin, Department for Applied
* Informatics, Moscow Aviation Institute, Moscow, Russia. All rights
* reserved. E-mail: <mao@gnu.org>.
*
* GLPK is free software: you can redistribute it and/or modify it
* under the terms of the GNU General Public License as published by
* the Free Software Foundation, either version 3 of the License, or
* (at your option) any later version.
*
* GLPK is distributed in the hope that it will be useful, but WITHOUT
* ANY WARRANTY; without even the implied warranty of MERCHANTABILITY
* or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public
* License for more details.
*
* You should have received a copy of the GNU General Public License
* along with GLPK. If not, see <http://www.gnu.org/licenses/>.
***********************************************************************/
#ifndef GLPSDF_H
#define GLPSDF_H
typedef struct glp_data glp_data;
/* plain data file */
glp_data *glp_sdf_open_file(const char *fname);
/* open plain data file */
void glp_sdf_set_jump(glp_data *data, void *jump);
/* set up error handling */
void glp_sdf_error(glp_data *data, const char *fmt, ...);
/* print error message */
void glp_sdf_warning(glp_data *data, const char *fmt, ...);
/* print warning message */
int glp_sdf_read_int(glp_data *data);
/* read integer number */
double glp_sdf_read_num(glp_data *data);
/* read floating-point number */
const char *glp_sdf_read_item(glp_data *data);
/* read data item */
const char *glp_sdf_read_text(glp_data *data);
/* read text until end of line */
int glp_sdf_line(glp_data *data);
/* determine current line number */
void glp_sdf_close_file(glp_data *data);
/* close plain data file */
#endif
/* eof */

222
resources/3rdparty/glpk-4.57/src/simplex/spychuzc.c

@ -1,222 +0,0 @@
/* spychuzc.c */
/***********************************************************************
* This code is part of GLPK (GNU Linear Programming Kit).
*
* Copyright (C) 2015 Andrew Makhorin, Department for Applied
* Informatics, Moscow Aviation Institute, Moscow, Russia. All rights
* reserved. E-mail: <mao@gnu.org>.
*
* GLPK is free software: you can redistribute it and/or modify it
* under the terms of the GNU General Public License as published by
* the Free Software Foundation, either version 3 of the License, or
* (at your option) any later version.
*
* GLPK is distributed in the hope that it will be useful, but WITHOUT
* ANY WARRANTY; without even the implied warranty of MERCHANTABILITY
* or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public
* License for more details.
*
* You should have received a copy of the GNU General Public License
* along with GLPK. If not, see <http://www.gnu.org/licenses/>.
***********************************************************************/
#include "env.h"
#include "spychuzc.h"
/***********************************************************************
* spy_chuzc_std - choose non-basic variable (dual textbook ratio test)
*
* This routine implements an improved dual textbook ratio test to
* choose non-basic variable xN[q].
*
* Current reduced costs of non-basic variables should be placed in the
* array locations d[1], ..., d[n-m]. Note that d[j] is a value of dual
* basic variable lambdaN[j] in the current basis.
*
* The parameter s specifies the sign of bound violation for basic
* variable xB[p] chosen: s = +1.0 means that xB[p] violates its lower
* bound, so dual non-basic variable lambdaB[p] = lambda^+B[p]
* increases, and s = -1.0 means that xB[p] violates its upper bound,
* so dual non-basic variable lambdaB[p] = lambda^-B[p] decreases.
* (Thus, the dual ray parameter theta = s * lambdaB[p] >= 0.)
*
* Elements of p-th simplex table row t[p] = (t[p,j]) corresponding
* to basic variable xB[p] should be placed in the array locations
* trow[1], ..., trow[n-m].
*
* The parameter tol_piv specifies a tolerance for elements of the
* simplex table row t[p]. If |t[p,j]| < tol_piv, dual basic variable
* lambdaN[j] is skipped, i.e. it is assumed that it does not depend on
* the dual ray parameter theta.
*
* The parameters tol and tol1 specify tolerances used to increase the
* choice freedom by simulating an artificial degeneracy as follows.
* If lambdaN[j] = lambda^+N[j] >= 0 and d[j] <= +delta[j], or if
* lambdaN[j] = lambda^-N[j] <= 0 and d[j] >= -delta[j], where
* delta[j] = tol + tol1 * |cN[j]|, cN[j] is objective coefficient at
* xN[j], then it is assumed that reduced cost d[j] is equal to zero.
*
* The routine determines the index 1 <= q <= n-m of non-basic variable
* xN[q], for which corresponding dual basic variable lambda^+N[j] or
* lambda^-N[j] reaches its zero bound first on increasing the dual ray
* parameter theta, and returns p on exit. And if theta may increase
* unlimitedly, the routine returns zero. */
int spy_chuzc_std(SPXLP *lp, const double d[/*1+n-m*/],
double s, const double trow[/*1+n-m*/], double tol_piv,
double tol, double tol1)
{ int m = lp->m;
int n = lp->n;
double *c = lp->c;
double *l = lp->l;
double *u = lp->u;
int *head = lp->head;
char *flag = lp->flag;
int j, k, q;
double alfa, biga, delta, teta, teta_min;
xassert(s == +1.0 || s == -1.0);
/* nothing is chosen so far */
q = 0, teta_min = DBL_MAX, biga = 0.0;
/* walk thru the list of non-basic variables */
for (j = 1; j <= n-m; j++)
{ k = head[m+j]; /* x[k] = xN[j] */
/* if xN[j] is fixed variable, skip it */
if (l[k] == u[k])
continue;
alfa = s * trow[j];
if (alfa >= +tol_piv && !flag[j])
{ /* xN[j] is either free or has its lower bound active, so
* lambdaN[j] = d[j] >= 0 decreases down to zero */
delta = tol + tol1 * (c[k] >= 0.0 ? +c[k] : -c[k]);
/* determine theta on which lambdaN[j] reaches zero */
teta = (d[j] < +delta ? 0.0 : d[j] / alfa);
}
else if (alfa <= -tol_piv && (l[k] == -DBL_MAX || flag[j]))
{ /* xN[j] is either free or has its upper bound active, so
* lambdaN[j] = d[j] <= 0 increases up to zero */
delta = tol + tol1 * (c[k] >= 0.0 ? +c[k] : -c[k]);
/* determine theta on which lambdaN[j] reaches zero */
teta = (d[j] > -delta ? 0.0 : d[j] / alfa);
}
else
{ /* lambdaN[j] cannot reach zero on increasing theta */
continue;
}
/* choose non-basic variable xN[q] by corresponding dual basic
* variable lambdaN[q] for which theta is minimal */
xassert(teta >= 0.0);
alfa = (alfa >= 0.0 ? +alfa : -alfa);
if (teta_min > teta || (teta_min == teta && biga < alfa))
q = j, teta_min = teta, biga = alfa;
}
return q;
}
/***********************************************************************
* spy_chuzc_harris - choose non-basic var. (dual Harris' ratio test)
*
* This routine implements dual Harris' ratio test to choose non-basic
* variable xN[q].
*
* All the parameters, except tol and tol1, as well as the returned
* value have the same meaning as for the routine spx_chuzr_std (see
* above).
*
* The parameters tol and tol1 specify tolerances on zero bound
* violations for reduced costs of non-basic variables. For reduced
* cost d[j] the tolerance is delta[j] = tol + tol1 |cN[j]|, where
* cN[j] is objective coefficient at non-basic variable xN[j]. */
int spy_chuzc_harris(SPXLP *lp, const double d[/*1+n-m*/],
double s, const double trow[/*1+n-m*/], double tol_piv,
double tol, double tol1)
{ int m = lp->m;
int n = lp->n;
double *c = lp->c;
double *l = lp->l;
double *u = lp->u;
int *head = lp->head;
char *flag = lp->flag;
int j, k, q;
double alfa, biga, delta, teta, teta_min;
xassert(s == +1.0 || s == -1.0);
/*--------------------------------------------------------------*/
/* first pass: determine teta_min for relaxed bounds */
/*--------------------------------------------------------------*/
teta_min = DBL_MAX;
/* walk thru the list of non-basic variables */
for (j = 1; j <= n-m; j++)
{ k = head[m+j]; /* x[k] = xN[j] */
/* if xN[j] is fixed variable, skip it */
if (l[k] == u[k])
continue;
alfa = s * trow[j];
if (alfa >= +tol_piv && !flag[j])
{ /* xN[j] is either free or has its lower bound active, so
* lambdaN[j] = d[j] >= 0 decreases down to zero */
delta = tol + tol1 * (c[k] >= 0.0 ? +c[k] : -c[k]);
/* determine theta on which lambdaN[j] reaches -delta */
teta = ((d[j] < 0.0 ? 0.0 : d[j]) + delta) / alfa;
}
else if (alfa <= -tol_piv && (l[k] == -DBL_MAX || flag[j]))
{ /* xN[j] is either free or has its upper bound active, so
* lambdaN[j] = d[j] <= 0 increases up to zero */
delta = tol + tol1 * (c[k] >= 0.0 ? +c[k] : -c[k]);
/* determine theta on which lambdaN[j] reaches +delta */
teta = ((d[j] > 0.0 ? 0.0 : d[j]) - delta) / alfa;
}
else
{ /* lambdaN[j] cannot reach zero on increasing theta */
continue;
}
xassert(teta >= 0.0);
if (teta_min > teta)
teta_min = teta;
}
/*--------------------------------------------------------------*/
/* second pass: choose non-basic variable xN[q] */
/*--------------------------------------------------------------*/
if (teta_min == DBL_MAX)
{ /* theta may increase unlimitedly */
q = 0;
goto done;
}
/* nothing is chosen so far */
q = 0, biga = 0.0;
/* walk thru the list of non-basic variables */
for (j = 1; j <= n-m; j++)
{ k = head[m+j]; /* x[k] = xN[j] */
/* if xN[j] is fixed variable, skip it */
if (l[k] == u[k])
continue;
alfa = s * trow[j];
if (alfa >= +tol_piv && !flag[j])
{ /* xN[j] is either free or has its lower bound active, so
* lambdaN[j] = d[j] >= 0 decreases down to zero */
/* determine theta on which lambdaN[j] reaches zero */
teta = d[j] / alfa;
}
else if (alfa <= -tol_piv && (l[k] == -DBL_MAX || flag[j]))
{ /* xN[j] is either free or has its upper bound active, so
* lambdaN[j] = d[j] <= 0 increases up to zero */
/* determine theta on which lambdaN[j] reaches zero */
teta = d[j] / alfa;
}
else
{ /* lambdaN[j] cannot reach zero on increasing theta */
continue;
}
/* choose non-basic variable for which theta is not greater
* than theta_min determined for relaxed bounds and which has
* best (largest in magnitude) pivot */
alfa = (alfa >= 0.0 ? +alfa : -alfa);
if (teta <= teta_min && biga < alfa)
q = j, biga = alfa;
}
/* something must be chosen */
xassert(1 <= q && q <= n-m);
done: return q;
}
/* eof */

204
resources/3rdparty/glpk-4.57/w32/Makefile_VC

@ -1,204 +0,0 @@
## Build GLPK with Microsoft Visual Studio Express ##
CFLAGS = \
/I. \
/I..\src \
/I..\src\amd \
/I..\src\bflib \
/I..\src\cglib \
/I..\src\colamd \
/I..\src\env \
/I..\src\minisat \
/I..\src\misc \
/I..\src\proxy \
/I..\src\simplex \
/I..\src\zlib \
/DHAVE_CONFIG_H=1 \
/D_CRT_SECURE_NO_WARNINGS=1 \
/nologo \
/W3 \
/O2 \
/Zi
OBJSET = \
..\src\avl.obj \
..\src\bfd.obj \
..\src\bfx.obj \
..\src\glpapi01.obj \
..\src\glpapi02.obj \
..\src\glpapi03.obj \
..\src\glpapi04.obj \
..\src\glpapi05.obj \
..\src\glpapi06.obj \
..\src\glpapi07.obj \
..\src\glpapi08.obj \
..\src\glpapi09.obj \
..\src\glpapi10.obj \
..\src\glpapi11.obj \
..\src\glpapi12.obj \
..\src\glpapi13.obj \
..\src\glpapi14.obj \
..\src\glpapi15.obj \
..\src\glpapi16.obj \
..\src\glpapi17.obj \
..\src\glpapi18.obj \
..\src\glpapi19.obj \
..\src\glpapi20.obj \
..\src\glpapi21.obj \
..\src\glpcpx.obj \
..\src\glpdmx.obj \
..\src\glpgmp.obj \
..\src\glphbm.obj \
..\src\glpini01.obj \
..\src\glpini02.obj \
..\src\glpios01.obj \
..\src\glpios02.obj \
..\src\glpios03.obj \
..\src\glpios04.obj \
..\src\glpios05.obj \
..\src\glpios06.obj \
..\src\glpios07.obj \
..\src\glpios08.obj \
..\src\glpios09.obj \
..\src\glpios10.obj \
..\src\glpios11.obj \
..\src\glpios12.obj \
..\src\glpipm.obj \
..\src\glpmat.obj \
..\src\glpmpl01.obj \
..\src\glpmpl02.obj \
..\src\glpmpl03.obj \
..\src\glpmpl04.obj \
..\src\glpmpl05.obj \
..\src\glpmpl06.obj \
..\src\glpmps.obj \
..\src\glpnet03.obj \
..\src\glpnet04.obj \
..\src\glpnet05.obj \
..\src\glpnpp01.obj \
..\src\glpnpp02.obj \
..\src\glpnpp03.obj \
..\src\glpnpp04.obj \
..\src\glpnpp05.obj \
..\src\glpnpp06.obj \
..\src\glprgr.obj \
..\src\glpscl.obj \
..\src\glpsdf.obj \
..\src\glpspm.obj \
..\src\glpsql.obj \
..\src\glpssx01.obj \
..\src\glpssx02.obj \
..\src\lux.obj \
..\src\amd\amd_1.obj \
..\src\amd\amd_2.obj \
..\src\amd\amd_aat.obj \
..\src\amd\amd_control.obj \
..\src\amd\amd_defaults.obj \
..\src\amd\amd_dump.obj \
..\src\amd\amd_info.obj \
..\src\amd\amd_order.obj \
..\src\amd\amd_post_tree.obj \
..\src\amd\amd_postorder.obj \
..\src\amd\amd_preprocess.obj \
..\src\amd\amd_valid.obj \
..\src\bflib\btf.obj \
..\src\bflib\btfint.obj \
..\src\bflib\fhv.obj \
..\src\bflib\fhvint.obj \
..\src\bflib\ifu.obj \
..\src\bflib\luf.obj \
..\src\bflib\lufint.obj \
..\src\bflib\scf.obj \
..\src\bflib\scfint.obj \
..\src\bflib\sgf.obj \
..\src\bflib\sva.obj \
..\src\cglib\cfg.obj \
..\src\cglib\cfg1.obj \
..\src\colamd\colamd.obj \
..\src\env\alloc.obj \
..\src\env\dlsup.obj \
..\src\env\env.obj \
..\src\env\error.obj \
..\src\env\stdout.obj \
..\src\env\stream.obj \
..\src\env\time.obj \
..\src\env\tls.obj \
..\src\minisat\minisat.obj \
..\src\misc\bignum.obj \
..\src\misc\dmp.obj \
..\src\misc\ffalg.obj \
..\src\misc\fp2rat.obj \
..\src\misc\gcd.obj \
..\src\misc\jd.obj \
..\src\misc\keller.obj \
..\src\misc\mc13d.obj \
..\src\misc\mc21a.obj \
..\src\misc\okalg.obj \
..\src\misc\qmd.obj \
..\src\misc\relax4.obj \
..\src\misc\rng.obj \
..\src\misc\rng1.obj \
..\src\misc\round2n.obj \
..\src\misc\str2int.obj \
..\src\misc\str2num.obj \
..\src\misc\strspx.obj \
..\src\misc\strtrim.obj \
..\src\misc\triang.obj \
..\src\misc\wclique.obj \
..\src\misc\wclique1.obj \
..\src\proxy\proxy.obj \
..\src\proxy\proxy1.obj \
..\src\simplex\spxat.obj \
..\src\simplex\spxchuzc.obj \
..\src\simplex\spxchuzr.obj \
..\src\simplex\spxlp.obj \
..\src\simplex\spxnt.obj \
..\src\simplex\spxprim.obj \
..\src\simplex\spxprob.obj \
..\src\simplex\spychuzc.obj \
..\src\simplex\spychuzr.obj \
..\src\simplex\spydual.obj \
..\src\zlib\adler32.obj \
..\src\zlib\compress.obj \
..\src\zlib\crc32.obj \
..\src\zlib\deflate.obj \
..\src\zlib\gzclose.obj \
..\src\zlib\gzlib.obj \
..\src\zlib\gzread.obj \
..\src\zlib\gzwrite.obj \
..\src\zlib\inffast.obj \
..\src\zlib\inflate.obj \
..\src\zlib\inftrees.obj \
..\src\zlib\trees.obj \
..\src\zlib\uncompr.obj \
..\src\zlib\zio.obj \
..\src\zlib\zutil.obj
.c.obj:
cl.exe $(CFLAGS) /Fo$*.obj /c $*.c
all: glpk.lib glpsol.exe
glpk.lib: $(OBJSET)
lib.exe /out:glpk.lib \
..\src\*.obj \
..\src\amd\*.obj \
..\src\bflib\*.obj \
..\src\cglib\*.obj \
..\src\colamd\*.obj \
..\src\env\*.obj \
..\src\minisat\*.obj \
..\src\misc\*.obj \
..\src\proxy\*.obj \
..\src\simplex\*.obj \
..\src\zlib\*.obj
glpsol.exe: ..\examples\glpsol.obj glpk.lib
cl.exe $(CFLAGS) /Feglpsol.exe \
..\examples\glpsol.obj glpk.lib
check: glpsol.exe
.\glpsol.exe --version
.\glpsol.exe --mps ..\examples\plan.mps
## eof ##

205
resources/3rdparty/glpk-4.57/w32/Makefile_VC_DLL

@ -1,205 +0,0 @@
## Build GLPK DLL with Microsoft Visual Studio Express ##
CFLAGS = \
/I. \
/I..\src \
/I..\src\amd \
/I..\src\bflib \
/I..\src\cglib \
/I..\src\colamd \
/I..\src\env \
/I..\src\minisat \
/I..\src\misc \
/I..\src\proxy \
/I..\src\simplex \
/I..\src\zlib \
/DHAVE_CONFIG_H=1 \
/D_CRT_SECURE_NO_WARNINGS=1 \
/nologo \
/W3 \
/O2 \
/Zi
OBJSET = \
..\src\avl.obj \
..\src\bfd.obj \
..\src\bfx.obj \
..\src\glpapi01.obj \
..\src\glpapi02.obj \
..\src\glpapi03.obj \
..\src\glpapi04.obj \
..\src\glpapi05.obj \
..\src\glpapi06.obj \
..\src\glpapi07.obj \
..\src\glpapi08.obj \
..\src\glpapi09.obj \
..\src\glpapi10.obj \
..\src\glpapi11.obj \
..\src\glpapi12.obj \
..\src\glpapi13.obj \
..\src\glpapi14.obj \
..\src\glpapi15.obj \
..\src\glpapi16.obj \
..\src\glpapi17.obj \
..\src\glpapi18.obj \
..\src\glpapi19.obj \
..\src\glpapi20.obj \
..\src\glpapi21.obj \
..\src\glpcpx.obj \
..\src\glpdmx.obj \
..\src\glpgmp.obj \
..\src\glphbm.obj \
..\src\glpini01.obj \
..\src\glpini02.obj \
..\src\glpios01.obj \
..\src\glpios02.obj \
..\src\glpios03.obj \
..\src\glpios04.obj \
..\src\glpios05.obj \
..\src\glpios06.obj \
..\src\glpios07.obj \
..\src\glpios08.obj \
..\src\glpios09.obj \
..\src\glpios10.obj \
..\src\glpios11.obj \
..\src\glpios12.obj \
..\src\glpipm.obj \
..\src\glpmat.obj \
..\src\glpmpl01.obj \
..\src\glpmpl02.obj \
..\src\glpmpl03.obj \
..\src\glpmpl04.obj \
..\src\glpmpl05.obj \
..\src\glpmpl06.obj \
..\src\glpmps.obj \
..\src\glpnet03.obj \
..\src\glpnet04.obj \
..\src\glpnet05.obj \
..\src\glpnpp01.obj \
..\src\glpnpp02.obj \
..\src\glpnpp03.obj \
..\src\glpnpp04.obj \
..\src\glpnpp05.obj \
..\src\glpnpp06.obj \
..\src\glprgr.obj \
..\src\glpscl.obj \
..\src\glpsdf.obj \
..\src\glpspm.obj \
..\src\glpsql.obj \
..\src\glpssx01.obj \
..\src\glpssx02.obj \
..\src\lux.obj \
..\src\amd\amd_1.obj \
..\src\amd\amd_2.obj \
..\src\amd\amd_aat.obj \
..\src\amd\amd_control.obj \
..\src\amd\amd_defaults.obj \
..\src\amd\amd_dump.obj \
..\src\amd\amd_info.obj \
..\src\amd\amd_order.obj \
..\src\amd\amd_post_tree.obj \
..\src\amd\amd_postorder.obj \
..\src\amd\amd_preprocess.obj \
..\src\amd\amd_valid.obj \
..\src\bflib\btf.obj \
..\src\bflib\btfint.obj \
..\src\bflib\fhv.obj \
..\src\bflib\fhvint.obj \
..\src\bflib\ifu.obj \
..\src\bflib\luf.obj \
..\src\bflib\lufint.obj \
..\src\bflib\scf.obj \
..\src\bflib\scfint.obj \
..\src\bflib\sgf.obj \
..\src\bflib\sva.obj \
..\src\cglib\cfg.obj \
..\src\cglib\cfg1.obj \
..\src\colamd\colamd.obj \
..\src\env\alloc.obj \
..\src\env\dlsup.obj \
..\src\env\env.obj \
..\src\env\error.obj \
..\src\env\stdout.obj \
..\src\env\stream.obj \
..\src\env\time.obj \
..\src\env\tls.obj \
..\src\minisat\minisat.obj \
..\src\misc\bignum.obj \
..\src\misc\dmp.obj \
..\src\misc\ffalg.obj \
..\src\misc\fp2rat.obj \
..\src\misc\gcd.obj \
..\src\misc\jd.obj \
..\src\misc\keller.obj \
..\src\misc\mc13d.obj \
..\src\misc\mc21a.obj \
..\src\misc\okalg.obj \
..\src\misc\qmd.obj \
..\src\misc\relax4.obj \
..\src\misc\rng.obj \
..\src\misc\rng1.obj \
..\src\misc\round2n.obj \
..\src\misc\str2int.obj \
..\src\misc\str2num.obj \
..\src\misc\strspx.obj \
..\src\misc\strtrim.obj \
..\src\misc\triang.obj \
..\src\misc\wclique.obj \
..\src\misc\wclique1.obj \
..\src\proxy\proxy.obj \
..\src\proxy\proxy1.obj \
..\src\simplex\spxat.obj \
..\src\simplex\spxchuzc.obj \
..\src\simplex\spxchuzr.obj \
..\src\simplex\spxlp.obj \
..\src\simplex\spxnt.obj \
..\src\simplex\spxprim.obj \
..\src\simplex\spxprob.obj \
..\src\simplex\spychuzc.obj \
..\src\simplex\spychuzr.obj \
..\src\simplex\spydual.obj \
..\src\zlib\adler32.obj \
..\src\zlib\compress.obj \
..\src\zlib\crc32.obj \
..\src\zlib\deflate.obj \
..\src\zlib\gzclose.obj \
..\src\zlib\gzlib.obj \
..\src\zlib\gzread.obj \
..\src\zlib\gzwrite.obj \
..\src\zlib\inffast.obj \
..\src\zlib\inflate.obj \
..\src\zlib\inftrees.obj \
..\src\zlib\trees.obj \
..\src\zlib\uncompr.obj \
..\src\zlib\zio.obj \
..\src\zlib\zutil.obj
.c.obj:
cl.exe $(CFLAGS) /Fo$*.obj /c $*.c
all: glpk_4_57.dll glpsol.exe
glpk_4_57.dll: $(OBJSET)
cl.exe $(CFLAGS) /LD /Feglpk_4_57.dll \
..\src\*.obj \
..\src\amd\*.obj \
..\src\bflib\*.obj \
..\src\cglib\*.obj \
..\src\colamd\*.obj \
..\src\env\*.obj \
..\src\minisat\*.obj \
..\src\misc\*.obj \
..\src\proxy\*.obj \
..\src\simplex\*.obj \
..\src\zlib\*.obj \
glpk_4_57.def
glpsol.exe: ..\examples\glpsol.obj glpk_4_57.dll
cl.exe $(CFLAGS) /Feglpsol.exe \
..\examples\glpsol.obj glpk_4_57.lib
check: glpsol.exe
.\glpsol.exe --version
.\glpsol.exe --mps ..\examples\plan.mps
## eof ##

204
resources/3rdparty/glpk-4.57/w64/makefile_VC

@ -1,204 +0,0 @@
## Build GLPK with Microsoft Visual Studio Express ##
CFLAGS = \
/I. \
/I..\src \
/I..\src\amd \
/I..\src\bflib \
/I..\src\cglib \
/I..\src\colamd \
/I..\src\env \
/I..\src\minisat \
/I..\src\misc \
/I..\src\proxy \
/I..\src\simplex \
/I..\src\zlib \
/DHAVE_CONFIG_H=1 \
/D_CRT_SECURE_NO_WARNINGS=1 \
/nologo \
/W3 \
/O2 \
/Zi
OBJSET = \
..\src\avl.obj \
..\src\bfd.obj \
..\src\bfx.obj \
..\src\glpapi01.obj \
..\src\glpapi02.obj \
..\src\glpapi03.obj \
..\src\glpapi04.obj \
..\src\glpapi05.obj \
..\src\glpapi06.obj \
..\src\glpapi07.obj \
..\src\glpapi08.obj \
..\src\glpapi09.obj \
..\src\glpapi10.obj \
..\src\glpapi11.obj \
..\src\glpapi12.obj \
..\src\glpapi13.obj \
..\src\glpapi14.obj \
..\src\glpapi15.obj \
..\src\glpapi16.obj \
..\src\glpapi17.obj \
..\src\glpapi18.obj \
..\src\glpapi19.obj \
..\src\glpapi20.obj \
..\src\glpapi21.obj \
..\src\glpcpx.obj \
..\src\glpdmx.obj \
..\src\glpgmp.obj \
..\src\glphbm.obj \
..\src\glpini01.obj \
..\src\glpini02.obj \
..\src\glpios01.obj \
..\src\glpios02.obj \
..\src\glpios03.obj \
..\src\glpios04.obj \
..\src\glpios05.obj \
..\src\glpios06.obj \
..\src\glpios07.obj \
..\src\glpios08.obj \
..\src\glpios09.obj \
..\src\glpios10.obj \
..\src\glpios11.obj \
..\src\glpios12.obj \
..\src\glpipm.obj \
..\src\glpmat.obj \
..\src\glpmpl01.obj \
..\src\glpmpl02.obj \
..\src\glpmpl03.obj \
..\src\glpmpl04.obj \
..\src\glpmpl05.obj \
..\src\glpmpl06.obj \
..\src\glpmps.obj \
..\src\glpnet03.obj \
..\src\glpnet04.obj \
..\src\glpnet05.obj \
..\src\glpnpp01.obj \
..\src\glpnpp02.obj \
..\src\glpnpp03.obj \
..\src\glpnpp04.obj \
..\src\glpnpp05.obj \
..\src\glpnpp06.obj \
..\src\glprgr.obj \
..\src\glpscl.obj \
..\src\glpsdf.obj \
..\src\glpspm.obj \
..\src\glpsql.obj \
..\src\glpssx01.obj \
..\src\glpssx02.obj \
..\src\lux.obj \
..\src\amd\amd_1.obj \
..\src\amd\amd_2.obj \
..\src\amd\amd_aat.obj \
..\src\amd\amd_control.obj \
..\src\amd\amd_defaults.obj \
..\src\amd\amd_dump.obj \
..\src\amd\amd_info.obj \
..\src\amd\amd_order.obj \
..\src\amd\amd_post_tree.obj \
..\src\amd\amd_postorder.obj \
..\src\amd\amd_preprocess.obj \
..\src\amd\amd_valid.obj \
..\src\bflib\btf.obj \
..\src\bflib\btfint.obj \
..\src\bflib\fhv.obj \
..\src\bflib\fhvint.obj \
..\src\bflib\ifu.obj \
..\src\bflib\luf.obj \
..\src\bflib\lufint.obj \
..\src\bflib\scf.obj \
..\src\bflib\scfint.obj \
..\src\bflib\sgf.obj \
..\src\bflib\sva.obj \
..\src\cglib\cfg.obj \
..\src\cglib\cfg1.obj \
..\src\colamd\colamd.obj \
..\src\env\alloc.obj \
..\src\env\dlsup.obj \
..\src\env\env.obj \
..\src\env\error.obj \
..\src\env\stdout.obj \
..\src\env\stream.obj \
..\src\env\time.obj \
..\src\env\tls.obj \
..\src\minisat\minisat.obj \
..\src\misc\bignum.obj \
..\src\misc\dmp.obj \
..\src\misc\ffalg.obj \
..\src\misc\fp2rat.obj \
..\src\misc\gcd.obj \
..\src\misc\jd.obj \
..\src\misc\keller.obj \
..\src\misc\mc13d.obj \
..\src\misc\mc21a.obj \
..\src\misc\okalg.obj \
..\src\misc\qmd.obj \
..\src\misc\relax4.obj \
..\src\misc\rng.obj \
..\src\misc\rng1.obj \
..\src\misc\round2n.obj \
..\src\misc\str2int.obj \
..\src\misc\str2num.obj \
..\src\misc\strspx.obj \
..\src\misc\strtrim.obj \
..\src\misc\triang.obj \
..\src\misc\wclique.obj \
..\src\misc\wclique1.obj \
..\src\proxy\proxy.obj \
..\src\proxy\proxy1.obj \
..\src\simplex\spxat.obj \
..\src\simplex\spxchuzc.obj \
..\src\simplex\spxchuzr.obj \
..\src\simplex\spxlp.obj \
..\src\simplex\spxnt.obj \
..\src\simplex\spxprim.obj \
..\src\simplex\spxprob.obj \
..\src\simplex\spychuzc.obj \
..\src\simplex\spychuzr.obj \
..\src\simplex\spydual.obj \
..\src\zlib\adler32.obj \
..\src\zlib\compress.obj \
..\src\zlib\crc32.obj \
..\src\zlib\deflate.obj \
..\src\zlib\gzclose.obj \
..\src\zlib\gzlib.obj \
..\src\zlib\gzread.obj \
..\src\zlib\gzwrite.obj \
..\src\zlib\inffast.obj \
..\src\zlib\inflate.obj \
..\src\zlib\inftrees.obj \
..\src\zlib\trees.obj \
..\src\zlib\uncompr.obj \
..\src\zlib\zio.obj \
..\src\zlib\zutil.obj
.c.obj:
cl.exe $(CFLAGS) /Fo$*.obj /c $*.c
all: glpk.lib glpsol.exe
glpk.lib: $(OBJSET)
lib.exe /out:glpk.lib \
..\src\*.obj \
..\src\amd\*.obj \
..\src\bflib\*.obj \
..\src\cglib\*.obj \
..\src\colamd\*.obj \
..\src\env\*.obj \
..\src\minisat\*.obj \
..\src\misc\*.obj \
..\src\proxy\*.obj \
..\src\simplex\*.obj \
..\src\zlib\*.obj
glpsol.exe: ..\examples\glpsol.obj glpk.lib
cl.exe $(CFLAGS) /Feglpsol.exe \
..\examples\glpsol.obj glpk.lib
check: glpsol.exe
.\glpsol.exe --version
.\glpsol.exe --mps ..\examples\plan.mps
## eof ##

205
resources/3rdparty/glpk-4.57/w64/makefile_VC_DLL

@ -1,205 +0,0 @@
## Build GLPK DLL with Microsoft Visual Studio Express ##
CFLAGS = \
/I. \
/I..\src \
/I..\src\amd \
/I..\src\bflib \
/I..\src\cglib \
/I..\src\colamd \
/I..\src\env \
/I..\src\minisat \
/I..\src\misc \
/I..\src\proxy \
/I..\src\simplex \
/I..\src\zlib \
/DHAVE_CONFIG_H=1 \
/D_CRT_SECURE_NO_WARNINGS=1 \
/nologo \
/W3 \
/O2 \
/Zi
OBJSET = \
..\src\avl.obj \
..\src\bfd.obj \
..\src\bfx.obj \
..\src\glpapi01.obj \
..\src\glpapi02.obj \
..\src\glpapi03.obj \
..\src\glpapi04.obj \
..\src\glpapi05.obj \
..\src\glpapi06.obj \
..\src\glpapi07.obj \
..\src\glpapi08.obj \
..\src\glpapi09.obj \
..\src\glpapi10.obj \
..\src\glpapi11.obj \
..\src\glpapi12.obj \
..\src\glpapi13.obj \
..\src\glpapi14.obj \
..\src\glpapi15.obj \
..\src\glpapi16.obj \
..\src\glpapi17.obj \
..\src\glpapi18.obj \
..\src\glpapi19.obj \
..\src\glpapi20.obj \
..\src\glpapi21.obj \
..\src\glpcpx.obj \
..\src\glpdmx.obj \
..\src\glpgmp.obj \
..\src\glphbm.obj \
..\src\glpini01.obj \
..\src\glpini02.obj \
..\src\glpios01.obj \
..\src\glpios02.obj \
..\src\glpios03.obj \
..\src\glpios04.obj \
..\src\glpios05.obj \
..\src\glpios06.obj \
..\src\glpios07.obj \
..\src\glpios08.obj \
..\src\glpios09.obj \
..\src\glpios10.obj \
..\src\glpios11.obj \
..\src\glpios12.obj \
..\src\glpipm.obj \
..\src\glpmat.obj \
..\src\glpmpl01.obj \
..\src\glpmpl02.obj \
..\src\glpmpl03.obj \
..\src\glpmpl04.obj \
..\src\glpmpl05.obj \
..\src\glpmpl06.obj \
..\src\glpmps.obj \
..\src\glpnet03.obj \
..\src\glpnet04.obj \
..\src\glpnet05.obj \
..\src\glpnpp01.obj \
..\src\glpnpp02.obj \
..\src\glpnpp03.obj \
..\src\glpnpp04.obj \
..\src\glpnpp05.obj \
..\src\glpnpp06.obj \
..\src\glprgr.obj \
..\src\glpscl.obj \
..\src\glpsdf.obj \
..\src\glpspm.obj \
..\src\glpsql.obj \
..\src\glpssx01.obj \
..\src\glpssx02.obj \
..\src\lux.obj \
..\src\amd\amd_1.obj \
..\src\amd\amd_2.obj \
..\src\amd\amd_aat.obj \
..\src\amd\amd_control.obj \
..\src\amd\amd_defaults.obj \
..\src\amd\amd_dump.obj \
..\src\amd\amd_info.obj \
..\src\amd\amd_order.obj \
..\src\amd\amd_post_tree.obj \
..\src\amd\amd_postorder.obj \
..\src\amd\amd_preprocess.obj \
..\src\amd\amd_valid.obj \
..\src\bflib\btf.obj \
..\src\bflib\btfint.obj \
..\src\bflib\fhv.obj \
..\src\bflib\fhvint.obj \
..\src\bflib\ifu.obj \
..\src\bflib\luf.obj \
..\src\bflib\lufint.obj \
..\src\bflib\scf.obj \
..\src\bflib\scfint.obj \
..\src\bflib\sgf.obj \
..\src\bflib\sva.obj \
..\src\cglib\cfg.obj \
..\src\cglib\cfg1.obj \
..\src\colamd\colamd.obj \
..\src\env\alloc.obj \
..\src\env\dlsup.obj \
..\src\env\env.obj \
..\src\env\error.obj \
..\src\env\stdout.obj \
..\src\env\stream.obj \
..\src\env\time.obj \
..\src\env\tls.obj \
..\src\minisat\minisat.obj \
..\src\misc\bignum.obj \
..\src\misc\dmp.obj \
..\src\misc\ffalg.obj \
..\src\misc\fp2rat.obj \
..\src\misc\gcd.obj \
..\src\misc\jd.obj \
..\src\misc\keller.obj \
..\src\misc\mc13d.obj \
..\src\misc\mc21a.obj \
..\src\misc\okalg.obj \
..\src\misc\qmd.obj \
..\src\misc\relax4.obj \
..\src\misc\rng.obj \
..\src\misc\rng1.obj \
..\src\misc\round2n.obj \
..\src\misc\str2int.obj \
..\src\misc\str2num.obj \
..\src\misc\strspx.obj \
..\src\misc\strtrim.obj \
..\src\misc\triang.obj \
..\src\misc\wclique.obj \
..\src\misc\wclique1.obj \
..\src\proxy\proxy.obj \
..\src\proxy\proxy1.obj \
..\src\simplex\spxat.obj \
..\src\simplex\spxchuzc.obj \
..\src\simplex\spxchuzr.obj \
..\src\simplex\spxlp.obj \
..\src\simplex\spxnt.obj \
..\src\simplex\spxprim.obj \
..\src\simplex\spxprob.obj \
..\src\simplex\spychuzc.obj \
..\src\simplex\spychuzr.obj \
..\src\simplex\spydual.obj \
..\src\zlib\adler32.obj \
..\src\zlib\compress.obj \
..\src\zlib\crc32.obj \
..\src\zlib\deflate.obj \
..\src\zlib\gzclose.obj \
..\src\zlib\gzlib.obj \
..\src\zlib\gzread.obj \
..\src\zlib\gzwrite.obj \
..\src\zlib\inffast.obj \
..\src\zlib\inflate.obj \
..\src\zlib\inftrees.obj \
..\src\zlib\trees.obj \
..\src\zlib\uncompr.obj \
..\src\zlib\zio.obj \
..\src\zlib\zutil.obj
.c.obj:
cl.exe $(CFLAGS) /Fo$*.obj /c $*.c
all: glpk_4_57.dll glpsol.exe
glpk_4_57.dll: $(OBJSET)
cl.exe $(CFLAGS) /LD /Feglpk_4_57.dll \
..\src\*.obj \
..\src\amd\*.obj \
..\src\bflib\*.obj \
..\src\cglib\*.obj \
..\src\colamd\*.obj \
..\src\env\*.obj \
..\src\minisat\*.obj \
..\src\misc\*.obj \
..\src\proxy\*.obj \
..\src\simplex\*.obj \
..\src\zlib\*.obj \
glpk_4_57.def
glpsol.exe: ..\examples\glpsol.obj glpk_4_57.dll
cl.exe $(CFLAGS) /Feglpsol.exe \
..\examples\glpsol.obj glpk_4_57.lib
check: glpsol.exe
.\glpsol.exe --version
.\glpsol.exe --mps ..\examples\plan.mps
## eof ##

0
resources/3rdparty/glpk-4.57/AUTHORS → resources/3rdparty/glpk-4.65/AUTHORS

0
resources/3rdparty/glpk-4.57/COPYING → resources/3rdparty/glpk-4.65/COPYING

522
resources/3rdparty/glpk-4.57/ChangeLog → resources/3rdparty/glpk-4.65/ChangeLog

@ -1,3 +1,525 @@
Thu Feb 16 10:00:00 2018 Andrew Makhorin <mao@gnu.org>
* GLPK 4.65 (43:0:3) has been released.
* src/glpk.h, src/api/npp.c
New API routines for LP/MIP preprocessing were added:
glp_npp_alloc_wksp allocate the preprocessor workspace
glp_npp_load_prob load original problem instance
glp_npp_preprocess1 perform basic LP/MIP preprocessing
glp_npp_build_prob build resultant problem instance
glp_npp_postprocess postprocess solution to resultant problem
glp_npp_obtain_sol obtain solution to original problem
glp_npp_free_wksp free the preprocessor workspace
See doc/npp.txt for detailed description of these API routines.
* examples/nppsamp.c
An example program to demonstrate using of LP/MIP preprocessor
was added.
The following modules were renamed to simplify maintenance.
* src/draft/glpnpp.h RENAMED -> src/npp/npp.h
* src/draft/glpnpp01.c RENAMED -> src/npp/npp1.c
* src/draft/glpnpp02.c RENAMED -> src/npp/npp2.c
* src/draft/glpnpp03.c RENAMED -> src/npp/npp3.c
* src/draft/glpnpp04.c RENAMED -> src/npp/npp4.c
* src/draft/glpnpp05.c RENAMED -> src/npp/npp5.c
* src/draft/glpnpp06.c RENAMED -> src/npp/npp6.c
* src/bflib/fvs.h RENAMED -> src/misc/fvs.h
* src/bflib/fvs.c RENAMED -> src/misc/fvs.c
* src/draft/glpios.h RENAMED -> src/draft/ios.h
* src/cglib/ RENAMED -> src/intopt/
* src/draft/glpios10.c RENAMED -> src/intopt/fpump.c
* src/glpk.h, src/intopt/covgen.c
A new, more robust implementation of locally valid simple cover
cuts was included in the MIP solver.
* src/draft/ios.h, src/draft/glpios01.c, src/draft/glpios03.c
These modules were changed to use the new cover cut generator.
* src/misc/ks.c, src/misc/ks.h
Routines to solve 0-1 knapsack problem (used by the new cover
cut generator) were added.
* src/misc/mt1.c, src/misc/mt1.h, src/misc/mt1.f
Routines to solve 0-1 knapsack problem with Martello & Toth
algorithm (used by the new cover cut generator) were added.
(The original Fortran 77 code mt1.f is included for reference
purposes only.)
* src/draft/glpapi09.c
The API routine glp_init_iocp was changed to enable long-step
dual simplex by default.
* src/api/cplex.c
The internal routine col_name routine was changed to construct
a fake column name depending on the column's attributes.
* examples/glpsol.c
A new option --hide was added. This option removes all symbolic
names from the model being processed.
* src/env/stdc.h
CDECL macro was added. (This macro is defined by config.h only
on building the GLPK DLL with MSVC.)
The following modules affected by this change were changed:
* src/api/cpxbas.c
* src/draft/glpios11.c
* src/intopt/cfg1.c
* src/intopt/fpump.c
* src/intopt/gmigen.c
* src/intopt/mirgen.c
* src/misc/wclique1.c
* src/simplex/spxchuzr.c
* src/simplex/spychuzc.c
Sat Dec 02 12:00:00 2017 Andrew Makhorin <mao@gnu.org>
* GLPK 4.64 (42:3:2) has been released.
* src/simplex/spydual.c
The internal routine play_coef of the dual simplex solver was
changed to perform more aggressive perturbation to prevent dual
degeneracy and avoid stalling even if the current dual basic
solution is strongly feasible (mainly if the objective is zero,
so all reduced costs are always zero). Thanks to David Monniaux
<David.Monniaux@univ-grenoble-alpes.fr> for bug report.
* src/draft/glpssx.h, glpssx02.c, glpapi07.c
The exact simplex solver routines were changed to perform
terminal output according to the verbosity level (specified by
the control parameter smcp.msg_lev). Thanks to Jeroen Demeyer
<jdemeyer@cage.ugent.be> for bug report.
* src/simplex/spxchuzr.c
The directive #include <config.h> was added. Thanks to Heinrich
Schuchardt <xypron.glpk@gmx.de> for bug report.
* examples/graceful.mod
An example model in MathProg was added. Thanks to Mike Appleby
<mike@app.leby.org> for contribution.
* examples/powpl25h.mod powplant.mod wolfra6d.lp wolfra6d.mod
Three example models in MathProg and one in Cplex LP format
were added. Thanks to Peter Naszvadi <vuk@cs.elte.hu> for
contribution.
Tue Jul 25 12:00:00 2017 Andrew Makhorin <mao@gnu.org>
* GLPK 4.63 (42:2:2) has been released.
* src/simplex/spxchuzr.h, src/simplex/spxchuzr.c
An experimental feature (phase I long-step ratio test) was
included in the primal simplex solver.
* src/simplex/spxprim.c, src/simplex/spydual.c
An internal scaling of the objective coefficients was added to
the primal and dual simplex solvers.
* src/simplex/spxprim.c
A minor bug was fixed (correction of flags of fixed non-basic
variables after removing the perturbation).
* src/glpk.h, src/glpapi06.c
New smcp parameters were added (not documented yet):
int excl (default: GLP_ON)
Internal simplex solver option:
GLP_ON - exclude fixed non-basic variables from the working LP;
GLP_OFF - keep original variables in the working LP.
int shift (default: GLP_ON)
Internal simplex solver option:
GLP_ON - shift bounds of variables in the working LP tow. zero;
GLP_OFF - keep original bounds of variables in the working LP.
int aorn (default: GLP_USE_NT)
Internal simplex solver option:
GLP_USE_AT - use A matrix in sparse row-wise format;
GLP_USE_NT - use N matrix in sparse row-wise format.
Parameter out_frq was changed to specify the output frequency
in milliseconds rather than in simplex iterations.
src/env/time.c
The Posix version of glp_time was replaced by new one, which
doesn't use gmtime functions to improve portability. Thanks to
Rob Schroeder <Rob.Schroeder@graphicpkg.com> for bug report.
src/spv.c, src/spv.h
These files were moved to src/cglib/, since they are used only
in the MIR cuts generator.
examples/life_goe.mod, examples/tiling.mod, examples/toto.mod
Three new example models in MathProg were added. Thanks to
Peter Naszvadi <vuk@cs.elte.hu> for contribution.
Wed Jun 14 12:00:00 2017 Andrew Makhorin <mao@gnu.org>
* GLPK 4.62 (42:1:2) has been released.
* src/simplex/spxprim.c
An experimental feature (bound perturbation) to improve
numerical stabilty and avoid cycling was included in the primal
simplex solver. Currently it is enabled by default.
* src/simplex/spxprim.c
Some dense vectors were replaced by sparse ones in full-vector
storage (FVS) format.
* src/simplex/spxprim.c, src/simplex/spydual.c
Assertions trow[q] != 0.0 and tcol[p] != 0.0 were replaced by
setting an error code to prevent abnormal termination. Thanks
to Chris Matrakidis <cmatraki@gmail.com> for patch.
* src/simplex/spydual.c
Removing perturbation was added if the perturbed problem is
dual infeasible while the original one is dual feasible. Thanks
to Chris Matrakidis <cmatraki@gmail.com> for patch.
* src/api/mps.c
A range bug was fixed.
Thanks to Chris Matrakidis <cmatraki@gmail.com> for patch.
* src/minisat/minisat.c
Changes were made to provide 64-bit portability. Thanks to
Chris Matrakidis <cmatraki@gmail.com> for patch.
* src/api/minisat1.c
Changes related to the minisat solver were made. Thanks to
Chris Matrakidis <cmatraki@gmail.com> for patch.
* src/api/intfeas1.c
Changes were made to skip objective integrality check when
no objective bound is specified. Thanks to Chris Matrakidis
<cmatraki@gmail.com> for patch.
* src/glphbm.c, src/glprgr.c, src/env/stream.c, src/env/time.c,
* src/mpl/mpl5.c, src/mpl/mpl6.c, src/mpl/mplsql.c
Calls to non-thread-safe functions gmtime, strerror, and strtok
were replaced by calls to corresponding thread-safe equivalents
(gmtime_r, strerror_r, and strtok_r for GNU/Linux).
* w32/*.def, w64/*.def
glp_config symbol was added. Thanks to Heinrich Schuchardt
<xypron.glpk@gmx.de> for bug report.
* examples/pbn/pbn.mod
A bug was fixed (model didn't work for odd number of rows or
columns). Thanks to Chris Matrakidis <cmatraki@gmail.com> for
bug report and patch provided.
Sun Jan 22 12:00:00 2017 Andrew Makhorin <mao@gnu.org>
* GLPK 4.61 (42:0:2) has been released.
The following modules were renamed to simplify maintenance.
* src/prob.h RENAMED -> src/api/prob.h
* src/glpapi01.c RENAMED -> src/api/prob1.c
* src/glpapi02.c RENAMED -> src/api/prob2.c
* src/glpapi03.c RENAMED -> src/api/prob3.c
* src/glpapi04.c RENAMED -> src/api/prob4.c
* src/glpapi05.c RENAMED -> src/api/prob5.c
* src/env/tls.c
TLS (thread local storage class specifier) option was added;
see comments in tls.c for details.
* configure.ac, config.h.in
Test for TLS was added.
Thanks to David Monniaux <david.monniaux@imag.fr> for
suggestion and Chris Matrakidis <cmatraki@gmail.com> for patch.
* src/env/tls.c
Dll support was added.
Thanks to Heinrich Schuchardt <xypron.glpk@gmx.de> for
contribution.
The following modules were changed to add __cdecl specifier
for functions passed to qsort (this is needed only on compiling
GLPK with MSVC to run under MS Windows).
* src/api/cpxbas.c
* src/cglib/cfg1.c
* src/cglib/gmigen.c
* src/cglib/mirgen.c
* src/misc/wclique1.c
* src/simplex/spychuzc.c
* src/glpios10.c
* src/glpios11.c
* examples/glpsol.c
* src/glpk.h, src/env/env.c
The API routine glp_version was changed to avoid initialization
of the GLPK environment. The new API routine glp_config was
added (but not documented yet). Thanks to Heinrich Schuchardt
<xypron.glpk@gmx.de> for suggestion.
* INSTALL
Description of the configure option '--with-zlib' was removed.
Thanks to Balaco Baco <balacobaco@imap.cc> for bug report.
Fri Apr 01 12:00:00 2016 Andrew Makhorin <mao@gnu.org>
* GLPK 4.60 (41:0:1) has been released.
* src/glpk.h
Declarations of all non-documented API routines were hidden by
#ifdef GLP_UNDOC / #endif.
src/simplex/spydual.c
An experimental feature (objective coefficient perturbation)
to improve numerical stabilty and avoid cycling was included in
the dual simplex solver.
This release also includes all the changes made in 4.59.2 and
4.59.1 non-official test releases (see below).
Fri Mar 18 12:00:00 2016 Andrew Makhorin <mao@gnu.org>
* GLPK 4.59.2 (40:1:0) has been released.
NOTE: THIS IS A NON-OFFICIAL TEST RELEASE.
src/simplex/spxprim.c
Improvements were made in the internal routine choose_pivot to
prevent choosing a too small pivot in the primal simplex.
src/simplex/spydual.c
Improvements were made in the internal routine choose_pivot to
prevent choosing a too small pivot in the dual simplex.
src/simplex/spychuzc.c
The internal routine spy_eval_bp was added to determine break-
points of the dual objective function.
src/simplex/spydual.c
An experimental feature (long-step ratio test) was included in
the dual simplex.
src/glpk.h, src/glpapi06.c
The GLP_RT_FLIP option (long-step ratio test) was added to
the simplex solver. Currently it affects only the dual simplex.
For the primal simplex it is equivalent to GLP_RT_HAR.
src/examples/glpsol.c
The '--flip' command-line option was added to glpsol (long-step
dual ratio test).
src/proxy/proxy1.c
Additional check was added to reject wrong solutions somwtimes
reported by the PROXY heuristic.
src/glpios10.c
A bug (memory leak) was fixed in the FPUMP heuristic routine.
Thanks to <nicolas.derhy@engie.com> for bug report.
Tue Mar 15 12:00:00 2016 Andrew Makhorin <mao@gnu.org>
* GLPK 4.59.1 (40:1:0) has been released.
NOTE: THIS IS A NON-OFFICIAL BUG-FIX RELEASE.
* src/simplex/mpl6.c, src/simplex/sql.c, src/simplex/sql.h
The header sql.h was renamed to avoid conflicts with standard
ODBC headers. Thanks to Noli Sicad <nsicad@gmail.com> for bug
report.
* src/simplex/spychuzc.c, src/simplex/spychuzc.h
Minor changes were made.
Fri Mar 11 12:00:00 2016 Andrew Makhorin <mao@gnu.org>
* GLPK 4.59 (40:0:0) has been released.
* src/sgf.c, src/sgf.h
The routines sgf_reduce_nuc and sgf_factorize were changed to
correctly report structural singularity.
* src/glpios01.c
The routine ios_solve_node was changed to retry solving node
problem in case of the simplex solver failure. Thanks to Chris
Matrakidis <cmatraki@gmail.com> for patch.
* src/glpios03.c
The routine ios_driver was changed to correctly process the
root node. Thanks to Chris Matrakidis <cmatraki@gmail.com> for
patch.
* src/glpios06.c
Some improvements were made in the MIR cut generation routines.
Thanks to Chris Matrakidis <cmatraki@gmail.com> for patch.
The following source modules were splitted/renamed to simplify
maintenance.
* src/glpios04.c RENAMED -> src/spv.c
* src/glpios05.c glp_gmi_cut (new) -> src/cglib/gmicut.c
* src/glpios05.c glp_gmi_gen (new) -> src/cglib/gmigen.c
* src/glpios05.c REMOVED
* src/glpios06.c glp_mir_init (new) -> src/cglib/mirgen.c
* src/glpios06.c glp_mir_gen (new) -> src/cglib/mirgen.c
* src/glpios06.c glp_mir_free (new) -> src/cglib/mirgen.c
* src/glpios06.c REMOVED
* src/glpios08.c glp_cfg_init (new) -> src/cglib/cfg2.c
* src/glpios08.c glp_cfg_free (new) -> src/cglib/cfg2.c
* src/glpios08.c glp_clq_cut (new) -> src/cglib/clqcut.c
* src/glpios08.c REMOVED
* src/glpmpl.h RENAMED -> src/mpl/mpl.h
* src/glpmpl01.c RENAMED -> src/mpl/mpl1.c
* src/glpmpl02.c RENAMED -> src/mpl/mpl2.c
* src/glpmpl03.c RENAMED -> src/mpl/mpl3.c
* src/glpmpl04.c RENAMED -> src/mpl/mpl4.c
* src/glpmpl05.c RENAMED -> src/mpl/mpl5.c
* src/glpmpl06.c RENAMED -> src/mpl/mpl6.c
* src/glpsql.h RENAMED -> src/mpl/sql.h
* src/glpsql.c RENAMED -> src/mpl/sql.c
* src/proxy/proxy.c
Minor bug was fixed in the PROXY heuristic routine. Thanks to
Chris Matrakidis <cmatraki@gmail.com> for bug report.
* src/cglib/gmicut.c, src/glpk.h
New API routine glp_gmi_cut was added (not documented yet).
* src/cglib/gmigen.c, src/glpk.h
New API routine glp_gmi_gen was added (not documented yet).
* src/cglib/mirgen.c, src/glpk.h
New API routines glp_mir_init, glp_mir_gen, and glp_mir_free
were added (not documented yet).
* src/cglib/cfg2.c, src/glpk.h
New API routines glp_cfg_init and glp_cfg_free were added (not
documented yet).
* src/cglib/clqcut.c, src/glpk.h
New API routine glp_clq_cut was added (not documented yet).
* src/api/rdcc.c, src/api/wrcc.c
API routines glp_read_graph and glp_write_graph were changed
due to changes in the data format. For details see the document
"GLPK: Graph and Network Routines".
* src/api/rdgr.c, src/api/wrgr.c, src/glpsdf.c, src/glpsdf.h
Old versions of API routines glp_read_graph and glp_write_graph
were removed.
* doc/gmpl_pt-BR.tex, doc/gmpl_pt-BR.pdf
Translation of the document "Modeling Language GNU MathProg"
to Brazilian Portuguese (pt-BR) was included (in LaTeX and pdf
formats). Thanks to Joao Flavio de Freitas Almeida
<joao.flavio@dep.ufmg.br> for contribution.
Thu Feb 18 12:00:00 2016 Andrew Makhorin <mao@gnu.org>
* GLPK 4.58 (39:0:0) has been released.
* src/misc/dimacs.c, src/misc/dimacs.h
Routines to read data files in DIMACS format were implemented
as a separate module.
The following source modules were splitted/renamed to simplify
maintenance.
* src/glpapi11.c glp_print_sol -> src/api/prsol.c
* src/glpapi11.c glp_read_sol -> src/api/rdsol.c
* src/glpapi11.c glp_write_sol -> src/api/wrsol.c
* src/glpapi11.c glp_print_ipt -> src/api/pript.c
* src/glpapi11.c glp_read_ipt -> src/api/rdipt.c
* src/glpapi11.c glp_write_ipt -> src/api/wript.c
* src/glpapi11.c glp_print_mip -> src/api/prmip.c
* src/glpapi11.c glp_read_mip -> src/api/rdmip.c
* src/glpapi11.c glp_write_mip -> src/api/wrmip.c
* src/glpapi11.c glp_print_ranges -> src/api/prrngs.c
* src/glpapi11.c REMOVED
* src/glpapi14.c RENAMED -> src/api/mpl.c
* src/glpapi15.c glp_read_graph -> src/api/rdgr.c
* src/glpapi15.c glp_write_graph -> src/api/wrgr.c
* src/glpapi15.c REMOVED
* src/glpapi16.c glp_weak_comp -> src/api/weak.c
* src/glpapi16.c glp_strong_comp -> src/api/strong.c
* src/glpapi16.c glp_top_sort -> src/api/topsort.c
* src/glpapi16.c REMOVED
* src/glpapi17.c glp_mincost_lp -> src/api/mcflp.c
* src/glpapi17.c glp_mincost_okalg -> src/api/mcfokalg.c
* src/glpapi17.c glp_mincost_relax4 -> src/api/mcfrelax.c
* src/glpapi17.c glp_maxflow_lp -> src/api/maxflp.c
* src/glpapi17.c glp_maxflow_ffalg -> src/api/maxffalg.c
* src/glpapi17.c glp_check_asnprob -> src/api/ckasn.c
* src/glpapi17.c glp_asnprob_lp -> src/api/asnlp.c
* src/glpapi17.c glp_asnprob_okalg -> src/api/asnokalg.c
* src/glpapi17.c glp_asnprob_hall -> src/api/asnhall.c
* src/glpapi17.c glp_cpp -> src/api/cpp.c
* src/glpapi17.c REMOVED
* src/glpapi18.c glp_wclique_exact -> src/api/wcliqex.c
* src/glpapi18.c REMOVED
* src/glpapi19.c RENAMED -> src/api/minisat1.c
* src/glpapi20.c RENAMED -> src/api/intfeas1.c
* src/glpapi21.c RENAMED -> examples/glpsol.c
* src/glpcpx.c RENAMED -> src/api/cplex.c
* src/glpdmx.c glp_read_mincost -> src/api/rdmcf.c
* src/glpdmx.c glp_write_mincost -> src/api/wrmcf.c
* src/glpdmx.c glp_read_maxflow -> src/api/rdmaxf.c
* src/glpdmx.c glp_write_maxflow -> src/api/wrmaxf.c
* src/glpdmx.c glp_read_asnprob -> src/api/rdasn.c
* src/glpdmx.c glp_write_asnprob -> src/api/wrasn.c
* src/glpdmx.c glp_read_ccdata -> src/api/rdcc.c
* src/glpdmx.c glp_write_ccdata -> src/api/wrcc.c
* src/glpdmx.c glp_read_prob -> src/api/rdprob.c
* src/glpdmx.c glp_write_prob -> src/api/wrprob.c
* src/glpdmx.c glp_read_cnfsat -> src/api/rdcnf.c
* src/glpdmx.c glp_write_cnfsat -> src/api/wrcnf.c
* src/glpdmx.c glp_check_cnfsat -> src/api/ckcnf.c
* src/glpdmx.c REMOVED
* src/glpgmp.c RENAMED -> src/misc/mygmp.c
* src/glpini01.c RENAMED -> src/api/advbas.c
* src/glpini02.c RENAMED -> src/api/cpxbas.c
* src/glpmps.c RENAMED -> src/api/mps.c
* src/glpnet03.c RENAMED -> src/api/netgen.c
* src/glpnet04.c RENAMED -> src/api/gridgen.c
* src/glpnet05.c RENAMED -> src/api/rmfgen.c
The following source modules were changed due to changes in the
data formats:
* src/api/rdsol.c
* src/api/wrsol.c
* src/api/rdipt.c
* src/api/wript.c
* src/api/rdmip.c
* src/api/wrmip.c
* src/glpk.h
New API routines were added: glp_mpl_init_rand (not documented
yet), glp_time, glp_difftime. The API routine glp_main (glpsol
main routine) was removed.
* src/glpmpl.h, src/glpmpl01.c, src/glpmpl03.c
The function tan (trigonometric tangent) was added to MathProg.
Thanks to Chris Matrakidis <cmatraki@gmail.com> for patch.
* src/simplex/spydual.c
A minor typo in dual simplex (GLP_EITLIM instead of GLP_ETMLIM)
was fixed. Thanks to Chris Matrakidis <cmatraki@gmail.com> for
patch.
* src/glpapi09.c, src/glpios01.c, src/glpios03.c
A time limit problem was fixed. Thanks to Chris Matrakidis
<cmatraki@gmail.com> for patch.
* doc/gmpl_es.tex, doc/gmpl_es.pdf
A new version of the document "Modeling Language GNU MathProg"
in Spanish was included (in LaTeX and pdf formats). Thanks to
Pablo Yapura <ypf@agro.unlp.edu.ar> for contribution.
* configure.ac
A check to determine if libtool needs '-no-undefined' flag to
build shared libraries on some platforms was added.
Thanks to Marco Atzeri <marco.atzeri@gmail.com> and Heinrich
Schuchardt <xypron.glpk@gmx.de> for suggestion.
* autogen.sh
A script to regenerate the configure script and the Makefiles
was added. Thanks to Heinrich Schuchardt <xypron.glpk@gmx.de>.
* w32/glpk.def, w64/glpk.def
'glp_at_error' symbol was added to the export list. Thanks to
Heinrich Schuchardt <xypron.glpk@gmx.de> for bug report.
Sun Nov 08 12:00:00 2015 Andrew Makhorin <mao@gnu.org>
* GLPK 4.57 (38:0:2) has been released.

11
resources/3rdparty/glpk-4.57/INSTALL → resources/3rdparty/glpk-4.65/INSTALL

@ -74,17 +74,6 @@ option should be passed to the configure script.
For details about the GNU MP bignum library see its web page at
<http://gmplib.org/>.
--with-zlib Enable using the zlib data compression library
This feature allows GLPK API routines and the stand-alone solver to
read and write compressed data files performing compression and
decompression "on the fly" (compressed data files are recognized by
suffix `.gz' in the file name). It may be useful in case of large
MPS files to save the disk space.
For details about the zlib compression library see its web page at
<http://www.zlib.net/>.
--enable-dl The same as --enable-dl=ltdl
--enable-dl=ltdl Enable shared library support (GNU)
--enable-dl=dlfcn Enable shared library support (POSIX)

0
resources/3rdparty/glpk-4.57/Makefile.am → resources/3rdparty/glpk-4.65/Makefile.am

1
resources/3rdparty/glpk-4.57/Makefile.in → resources/3rdparty/glpk-4.65/Makefile.in

@ -175,6 +175,7 @@ MANIFEST_TOOL = @MANIFEST_TOOL@
MKDIR_P = @MKDIR_P@
NM = @NM@
NMEDIT = @NMEDIT@
NOUNDEFINED = @NOUNDEFINED@
OBJDUMP = @OBJDUMP@
OBJEXT = @OBJEXT@
OTOOL = @OTOOL@

188
resources/3rdparty/glpk-4.57/NEWS → resources/3rdparty/glpk-4.65/NEWS

@ -1,3 +1,191 @@
GLPK 4.65 (release date: Feb 16, 2018)
The following new API routines for LP/MIP preprocessing were
added:
glp_npp_alloc_wksp allocate the preprocessor workspace
glp_npp_load_prob load original problem instance
glp_npp_preprocess1 perform basic LP/MIP preprocessing
glp_npp_build_prob build resultant problem instance
glp_npp_postprocess postprocess solution to resultant problem
glp_npp_obtain_sol obtain solution to original problem
glp_npp_free_wksp free the preprocessor workspace
See doc/npp.txt for detailed description of these API routines.
A new, more robust implementation of locally valid simple cover
cuts was included in the MIP solver.
The API routine glp_init_iocp was changed to enable long-step
option of the dual simplex by default.
GLPK 4.64 (release date: Dec 02, 2017)
The dual simplex solver routine was changed to perform more
aggressive perturbation to prevent dual degeneracy and avoid
stalling even if the current dual basic solution is strongly
feasible (mainly if the objective is zero). Thanks to David
Monniaux <David.Monniaux@univ-grenoble-alpes.fr> for bug report
and example model.
The exact simplex solver routine was changed to perform
terminal output according to the verbosity level (specified by
the control parameter smcp.msg_lev). Thanks to Jeroen Demeyer
<jdemeyer@cage.ugent.be> for bug report.
A minor bug (related to MS Windows version) was fixed. Thanks
to Heinrich Schuchardt <xypron.glpk@gmx.de> for bug report.
An example model (Graceful Tree Labeling Problem) in MathProg
was added. Thanks to Mike Appleby <mike@app.leby.org> for
contribution.
Three example models (Power plant LP scheduler, Neumann CA
grid emulator generator) in MathProg and one in Cplex LP format
were added. Thanks to Peter Naszvadi <vuk@cs.elte.hu> for
contribution.
GLPK 4.63 (release date: Jul 25, 2017)
A "smart" LP perturbation was implemented in the primal and
dual simplex solvers. Now LP is perturbed only if it is
necessary, and by default perturbation is not activated.
The sum of primal infeasibilites that appears in the terminal
output of the primal simplex solver (as "inf = ...") now
corresponds to the original bounds of variables. This allows to
see how much perturbed solution violates the original bounds.
The long-step technique was implemented for phase I of the
primal simplex solver. This feature can be enabled by
specifying --flip option for glpsol or by specifying
glp_smcp.r_test = GLP_RT_FLIP on api level. For many LP
instances the long-step technique allows reducing the number
of simplex iterations to 30-70%. Please note that unlike the
dual simplex, where this technique can be used on both phase I
and II, for the primal simplex it can be used only on phase I,
where the sum of primal infeasibilities (which is a convex
piecewise linear function) is minimized.
An internal objective scaling was included in both primal and
dual simplex solvers. For many LP/MIP instances this feature
improves numerical stability (for the dual solver) and prevents
cycling near the optimum (for the primal solver).
The Posix version of glp_time (glpk/src/env/time.c) was changed
to resolve time_t issue on msys2. Thanks to Rob Schroeder
<Rob.Schroeder@graphicpkg.com> for bug report.
Three new example models in MathProg were added:
life_goe.mod (Conway's Game of Life garden of eden checker);
tiling.mod (Rectifiable polyomino tilings generator);
toto.mod (Covering code generator).
Thanks to Peter Naszvadi <vuk@cs.elte.hu> for contribution.
GLPK 4.62 (release date: Jun 14, 2017)
The bound perturbation technique was included in the primal
simplex solver to improve numerical stability and avoid cycling.
Currently this feature is enabled by default.
A range bug was fixed in the MPS reading routine. Thanks to
Chris Matrakidis <cmatraki@gmail.com> for bug report and patch.
Changes were made to provide 64-bit portability of the Minisat
solver. Thanks to Chris Matrakidis <cmatraki@gmail.com> for
patch.
Calls to non-thread-safe functions gmtime, strerror, and strtok
were replaced by calls to corresponding thread-safe equivalents
(gmtime_r, strerror_r, and strtok_r for GNU/Linux).
GLPK 4.61 (release date: Jan 22, 2017)
An option was added to build a re-entrant version of the
package suitable for running in a multi-threaded environment.
This option is enabled by default on configuring the package
if the compiler used supports the thread local storage class
specifier (e.g. _Thread_local or __thread). Thanks to
David Monniaux <david.monniaux@imag.fr> for suggestion and
Chris Matrakidis <cmatraki@gmail.com> for configure.ac patch.
A re-entrant version of the package allows running multiple
independent instances of glpk in different threads of a multi-
threaded application. Note that glpk is not thread-safe by
design, so if the application calls glpk routines from multiple
threads, no thread may access glpk program objects (glp_prob,
glp_tree, etc.) created by other threads; besides, each thread
before termination should call the API routine glp_free_env to
prevent memory leak.
A DLL support was added. Thanks to Heinrich Schuchardt
<xypron.glpk@gmx.de> for contribution.
Some changes were made to allow compiling the package using
stdcall calling convention (this is needed only on compiling
GLPK with MSVC to run under MS Windows).
GLPK 4.60 (release date: Apr 01, 2016)
Some improvements were made in the primal and dual simplex
solvers to make the solution process more numerically stable.
An experimental long-step ratio test feature was added to the
dual simplex. On API level this feature is available thru the
GLP_RT_FLIP option. For glpsol it is available thru the options
--flip (for MIP) or --flip and --dual (for LP). This feature is
not documented yet.
Additional check was added to reject wrong solutions sometimes
reported by the PROXY heuristic.
A bug (memory leak) was fixed in the FPUMP heuristic routine.
Thanks to <nicolas.derhy@engie.com> for bug report.
The header sql.h was renamed to avoid conflicts with standard
ODBC headers. Thanks to Noli Sicad <nsicad@gmail.com> for bug
report.
GLPK 4.59 (release date: Mar 11, 2016)
This is a maintainer release.
Some bugs were fixed and some improvements were made in the MIP
solver. Thanks to Chris Matrakidis <cmatraki@gmail.com> for bug
reports and patches.
The data file format used by API routines glp_read_graph and
glp_write_graph was changed. For more details please see the
document "GLPK: Graph and Network Routines" included in the
distribution.
Translation of the document "Modeling Language GNU MathProg"
to Brazilian Portuguese (pt-BR) was included (in LaTeX and pdf
formats). Thanks to Joao Flavio de Freitas Almeida
<joao.flavio@dep.ufmg.br> for contribution.
GLPK 4.58 (release date: Feb 18, 2016)
The solution file format used by API routines glp_read_sol,
glp_write_sol, glp_read_ipt, glp_write_ipt, glp_read_mip, and
glp_write_mip was changed. For more details please see the GLPK
reference manual included in the distribution.
The tan function (trigonometric tangent) was added to
GNU MathProg modeling language. Thanks to Chris Matrakidis
<cmatraki@gmail.com> for contribution.
A new version of the document "Modeling Language GNU MathProg"
in Spanish was included (in LaTeX and pdf formats). Thanks to
Pablo Yapura <ypf@agro.unlp.edu.ar> for contribution.
A check to determine if libtool needs '-no-undefined' flag to
build shared libraries on some platforms was added.
Thanks to Marco Atzeri <marco.atzeri@gmail.com> and Heinrich
Schuchardt <xypron.glpk@gmx.de> for suggestion.
A script to regenerate the configure script and the Makefiles
was added. Thanks to Heinrich Schuchardt <xypron.glpk@gmx.de>.
GLPK 4.57 (release date: Nov 08, 2015)
A new, more efficient implementation of the dual simplex method

20
resources/3rdparty/glpk-4.57/README → resources/3rdparty/glpk-4.65/README

@ -1,11 +1,11 @@
Olga K. gewidmet
GLPK (GNU Linear Programming Kit) Version 4.57
GLPK (GNU Linear Programming Kit) Version 4.65
Copyright (C) 2000, 2001, 2002, 2003, 2004, 2005, 2006, 2007, 2008,
2009, 2010, 2011, 2013, 2014, 2015 Andrew Makhorin, Department for
Applied Informatics, Moscow Aviation Institute, Moscow, Russia. All
rights reserved. E-mail: <mao@gnu.org>.
2009, 2010, 2011, 2013, 2014, 2015, 2016, 2017, 2018 Andrew Makhorin,
Department for Applied Informatics, Moscow Aviation Institute, Moscow,
Russia. All rights reserved. E-mail: <mao@gnu.org>.
GLPK is part of the GNU Project released under the aegis of GNU.
@ -25,14 +25,14 @@ large-scale linear programming (LP), mixed integer linear programming
The GLPK package includes the following main components:
* implementation of the simplex method;
* implementation of the exact simplex method based on bignum (rational)
arithmetic;
* implementation of the primal-dual interior-point method;
* implementation of the branch-and-cut method;
* primal simplex method;
* dual simplex method;
* exact simplex method based on rational arithmetic;
* primal-dual interior-point method;
* branch-and-cut method;
* application program interface (API);
* GNU MathProg modeling language (a subset of AMPL);
* GLPSOL, a stand-alone LP/MIP solver.
* GLPSOL (stand-alone LP/MIP solver).
See GLPK webpage <http://www.gnu.org/software/glpk/glpk.html>.

26
resources/3rdparty/glpk-4.57/THANKS → resources/3rdparty/glpk-4.65/THANKS

@ -15,6 +15,8 @@ Anton Voropaev <anton.n.voropaev@gmail.com> for bug and typo report.
Axel Simon <Axel.Simon@ens.fr> for bug report.
Balaco Baco <balacobaco@imap.cc> for bug report.
Bernhard Schmidt <schmidt@math.uni-augsburg.de> for bug report.
Boris Wirtz <Boris.Wirtz@uni-oldenburg.de> for bug report.
@ -35,13 +37,21 @@ Cedric[FR] <fox2113@wanadoo.fr> for bug report.
Charles Brixko <charles.brixko@voo.be> for bug report.
Chris Matrakidis <cmatraki@gmail.com> for suggestion.
Chris Matrakidis <cmatraki@gmail.com> for contribution of a patch that
implements the tan function in MathProg.
Chris Matrakidis <cmatraki@gmail.com> for numerous useful suggestions,
contributions, and patches.
Chris Rosebrugh <cpr@pobox.com> for contribution of a new version of
GLPK JNI (Java Native Interface).
Christophe Caron <caron@diamant.jouy.inra.fr> for bug report.
David Monniaux <david.monniaux@imag.fr> for some suggestions.
David Monniaux <David.Monniaux@univ-grenoble-alpes.fr> for bug report.
David T. Price <dtprice@speakeasy.net> for bug report.
Dennis Schridde <devurandom@gmx.net> for bug report.
@ -90,8 +100,14 @@ language reference.
Jeroen Demeyer <jdemeyer@cage.ugent.be> for suggestion.
Jeroen Demeyer <jdemeyer@cage.ugent.be> for bug report.
Jiri Spitz <jiri.spitz@telecom.cz> for bug report.
Joao Flavio de Freitas Almeida <joao.flavio@dep.ufmg.br> for
translation of the document "Modeling Language GNU MathProg" to
Brazilian Portuguese (pt-BR).
Joey Rios <joeylrios@hotmail.com> for some suggestions.
Jonathan Senning <Jonathan.Senning@gordon.edu> for bug report.
@ -119,6 +135,8 @@ Markus Pilz <pilz@cs.uni-bonn.de> for bug report.
Martin Jacob <mj@bahntechnik.de> for bug report.
Mike Appleby <mike@app.leby.org> for example model in MathProg.
Minh Ha Duong <haduong@centre-cired.fr> for fixing doc typos.
Morten Welinder <terra@diku.dk> for bug report.
@ -152,7 +170,7 @@ Olivier <odwl@skynet.be> for bug report.
Oscar Gustafsson <oscarg@isy.liu.se> for contribution of a routine to
write data in OPB (pseudo boolean) format.
Pablo Yapura <ypf@agro.unlp.edu.ar> for translation the document
Pablo Yapura <ypf@agro.unlp.edu.ar> for translation of the document
"Modeling Language GNU MathProg" to Spanish.
Pedro P. Wong <d00604@taipower.com.tw> for bug report.
@ -165,6 +183,8 @@ Peter Ingerfeld <peter.ingerfeld@mops-optimizer.com> for bug report.
Peter Lee <plee@kinggee.com.au> for example LP model and bug report.
Peter Naszvadi <vuk@cs.elte.hu> for example models in MathProg.
Pietro Scionti <pietro.scionti@archinet.it> for report typos found in
the reference manual.
@ -175,6 +195,8 @@ Raniere Gaia Costa da Silva for bug report.
Remy Roy <remyroyster@gmail.com> for bug report.
Rob Schroeder <Rob.Schroeder@graphicpkg.com> for bug report.
Robbie Morrison <robbie@actrix.co.nz> for correcting the glpk manual.
Robert Wood <rgwood01@cox.net> for example model in MathProg.

0
resources/3rdparty/glpk-4.57/aclocal.m4 → resources/3rdparty/glpk-4.65/aclocal.m4

27
resources/3rdparty/glpk-4.65/autogen.sh

@ -0,0 +1,27 @@
#!/bin/sh
########################################################################
# Run this script on the top level of GLPK directory to regenerate the
# configure script and the Makefiles from templates.
#
# NOTE: You need to have GNU autotools installed.
########################################################################
set -e
test -f configure.ac || {
echo "You should run this script on the top level of GLPK directory."
exit
}
echo "Executing libtoolize..."
libtoolize -c -f
echo "Executing aclocal..."
aclocal -I m4
echo "Executing autoconf..."
autoconf
echo "Executing automake..."
automake -c -a
echo "Done."
echo "See file INSTALL for installation instructions."

0
resources/3rdparty/glpk-4.57/config.guess → resources/3rdparty/glpk-4.65/config.guess

3
resources/3rdparty/glpk-4.57/config.h.in → resources/3rdparty/glpk-4.65/config.h.in

@ -24,4 +24,7 @@
#undef MYSQL_DLNAME
/* MySQL shared library name if this feature is enabled */
#undef TLS
/* thread local storage-class specifier for re-entrancy (if any) */
/* eof */

0
resources/3rdparty/glpk-4.57/config.sub → resources/3rdparty/glpk-4.65/config.sub

91
resources/3rdparty/glpk-4.57/configure → resources/3rdparty/glpk-4.65/configure

@ -1,6 +1,6 @@
#! /bin/sh
# Guess values for system-dependent variables and create Makefiles.
# Generated by GNU Autoconf 2.69 for GLPK 4.57.
# Generated by GNU Autoconf 2.69 for GLPK 4.65.
#
# Report bugs to <bug-glpk@gnu.org>.
#
@ -590,8 +590,8 @@ MAKEFLAGS=
# Identity of this package.
PACKAGE_NAME='GLPK'
PACKAGE_TARNAME='glpk'
PACKAGE_VERSION='4.57'
PACKAGE_STRING='GLPK 4.57'
PACKAGE_VERSION='4.65'
PACKAGE_STRING='GLPK 4.65'
PACKAGE_BUGREPORT='bug-glpk@gnu.org'
PACKAGE_URL=''
@ -636,6 +636,7 @@ ac_subst_vars='am__EXEEXT_FALSE
am__EXEEXT_TRUE
LTLIBOBJS
LIBOBJS
NOUNDEFINED
CPP
OTOOL64
OTOOL
@ -751,6 +752,7 @@ with_gmp
enable_dl
enable_odbc
enable_mysql
enable_reentrant
enable_dependency_tracking
enable_shared
enable_static
@ -1309,7 +1311,7 @@ if test "$ac_init_help" = "long"; then
# Omit some internal or obsolete options to make the list less imposing.
# This message is too long to be a string in the A/UX 3.1 sh.
cat <<_ACEOF
\`configure' configures GLPK 4.57 to adapt to many kinds of systems.
\`configure' configures GLPK 4.65 to adapt to many kinds of systems.
Usage: $0 [OPTION]... [VAR=VALUE]...
@ -1379,7 +1381,7 @@ fi
if test -n "$ac_init_help"; then
case $ac_init_help in
short | recursive ) echo "Configuration of GLPK 4.57:";;
short | recursive ) echo "Configuration of GLPK 4.65:";;
esac
cat <<\_ACEOF
@ -1390,6 +1392,7 @@ Optional Features:
--enable-dl enable shared library support [[default=no]]
--enable-odbc enable MathProg ODBC support [[default=no]]
--enable-mysql enable MathProg MySQL support [[default=no]]
--enable-reentrant enable reentrancy support [[default=yes]]
--enable-dependency-tracking
do not reject slow dependency extractors
--disable-dependency-tracking
@ -1486,7 +1489,7 @@ fi
test -n "$ac_init_help" && exit $ac_status
if $ac_init_version; then
cat <<\_ACEOF
GLPK configure 4.57
GLPK configure 4.65
generated by GNU Autoconf 2.69
Copyright (C) 2012 Free Software Foundation, Inc.
@ -1855,7 +1858,7 @@ cat >config.log <<_ACEOF
This file contains any messages produced by compilers while
running configure, to aid debugging if configure makes a mistake.
It was created by GLPK $as_me 4.57, which was
It was created by GLPK $as_me 4.65, which was
generated by GNU Autoconf 2.69. Invocation command line was
$ $0 $@
@ -2684,7 +2687,7 @@ fi
# Define the identity of the package.
PACKAGE='glpk'
VERSION='4.57'
VERSION='4.65'
cat >>confdefs.h <<_ACEOF
@ -2779,6 +2782,17 @@ else
fi
# Check whether --enable-reentrant was given.
if test "${enable_reentrant+set}" = set; then :
enableval=$enable_reentrant; case $enableval in
yes | no) ;;
*) as_fn_error $? "invalid value \`$enableval' for --enable-reentrant" "$LINENO" 5;;
esac
else
enable_reentrant=yes
fi
@ -11470,6 +11484,63 @@ else
$as_echo "no" >&6; }
fi
{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether to enable reentrancy support" >&5
$as_echo_n "checking whether to enable reentrancy support... " >&6; }
if test "$enable_reentrant" = "yes"; then
{ $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
$as_echo "yes" >&6; }
{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for thread local storage (TLS) class specifier" >&5
$as_echo_n "checking for thread local storage (TLS) class specifier... " >&6; }
keywords="_Thread_local __thread __declspec(thread)"
tls=none
for tls_keyword in $keywords; do
cat confdefs.h - <<_ACEOF >conftest.$ac_ext
/* end confdefs.h. */
#include <stdlib.h>
static void foo(void)
{ static $tls_keyword int bar;
exit(1);
}
_ACEOF
if ac_fn_c_try_compile "$LINENO"; then :
tls=$tls_keyword; break
fi
rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
done
{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $tls" >&5
$as_echo "$tls" >&6; }
if test "$tls" != "none"; then
cat >>confdefs.h <<_ACEOF
#define TLS $tls
_ACEOF
else
as_fn_error $? "Reentrancy needs complier support for TLS" "$LINENO" 5
fi
else
{ $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
$as_echo "no" >&6; }
fi
{ $as_echo "$as_me:${as_lineno-$LINENO}: checking if libtool needs -no-undefined flag to build shared libraries" >&5
$as_echo_n "checking if libtool needs -no-undefined flag to build shared libraries... " >&6; }
case "${host}" in
*-*-cygwin* | *-*-mingw* | *-*-aix*)
## Add in the -no-undefined flag to LDFLAGS for libtool.
{ $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
$as_echo "yes" >&6; }
NOUNDEFINED=" -no-undefined"
;;
*)
## Don't add in anything.
{ $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
$as_echo "no" >&6; }
;;
esac
ac_config_files="$ac_config_files src/Makefile examples/Makefile Makefile"
cat >confcache <<\_ACEOF
@ -12002,7 +12073,7 @@ cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
# report actual input values of CONFIG_FILES etc. instead of their
# values after options handling.
ac_log="
This file was extended by GLPK $as_me 4.57, which was
This file was extended by GLPK $as_me 4.65, which was
generated by GNU Autoconf 2.69. Invocation command line was
CONFIG_FILES = $CONFIG_FILES
@ -12068,7 +12139,7 @@ _ACEOF
cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
ac_cs_config="`$as_echo "$ac_configure_args" | sed 's/^ //; s/[\\""\`\$]/\\\\&/g'`"
ac_cs_version="\\
GLPK config.status 4.57
GLPK config.status 4.65
configured by $0, generated by GNU Autoconf 2.69,
with options \\"\$ac_cs_config\\"

51
resources/3rdparty/glpk-4.57/configure.ac → resources/3rdparty/glpk-4.65/configure.ac

@ -1,6 +1,6 @@
dnl Process this file with autoconf to produce a configure script
AC_INIT([GLPK], [4.57], [bug-glpk@gnu.org])
AC_INIT([GLPK], [4.65], [bug-glpk@gnu.org])
AC_CONFIG_SRCDIR([src/glpk.h])
@ -46,6 +46,16 @@ AC_HELP_STRING([--enable-mysql],
esac],
[enable_mysql=no])
AC_ARG_ENABLE(reentrant,
AC_HELP_STRING([--enable-reentrant],
[enable reentrancy support [[default=yes]]]),
[case $enableval in
yes | no) ;;
*) AC_MSG_ERROR(
[invalid value `$enableval' for --enable-reentrant]);;
esac],
[enable_reentrant=yes])
dnl Disable unnecessary libtool tests
define([AC_LIBTOOL_LANG_CXX_CONFIG], [:])
define([AC_LIBTOOL_LANG_F77_CONFIG], [:])
@ -141,6 +151,45 @@ else
AC_MSG_RESULT([no])
fi
AC_MSG_CHECKING([whether to enable reentrancy support])
if test "$enable_reentrant" = "yes"; then
AC_MSG_RESULT([yes])
AC_MSG_CHECKING([for thread local storage (TLS) class specifier])
keywords="_Thread_local __thread __declspec(thread)"
tls=none
for tls_keyword in $keywords; do
AC_COMPILE_IFELSE([AC_LANG_SOURCE([
#include <stdlib.h>
static void foo(void)
{ static ] $tls_keyword [ int bar;
exit(1);
}])], [tls=$tls_keyword; break], [])
done
AC_MSG_RESULT($tls)
if test "$tls" != "none"; then
AC_DEFINE_UNQUOTED([TLS], $tls, [N/A])
else
AC_MSG_ERROR([Reentrancy needs complier support for TLS])
fi
else
AC_MSG_RESULT([no])
fi
AC_MSG_CHECKING(
[if libtool needs -no-undefined flag to build shared libraries])
case "${host}" in
*-*-cygwin* | *-*-mingw* | *-*-aix*)
## Add in the -no-undefined flag to LDFLAGS for libtool.
AC_MSG_RESULT([yes])
NOUNDEFINED=" -no-undefined"
;;
*)
## Don't add in anything.
AC_MSG_RESULT([no])
;;
esac
AC_SUBST([NOUNDEFINED])
AC_CONFIG_FILES(
[src/Makefile examples/Makefile Makefile])
AC_OUTPUT

0
resources/3rdparty/glpk-4.57/depcomp → resources/3rdparty/glpk-4.65/depcomp

0
resources/3rdparty/glpk-4.57/doc/cnfsat.pdf → resources/3rdparty/glpk-4.65/doc/cnfsat.pdf

0
resources/3rdparty/glpk-4.57/doc/cnfsat.tex → resources/3rdparty/glpk-4.65/doc/cnfsat.tex

BIN
resources/3rdparty/glpk-4.65/doc/glpk.pdf

45
resources/3rdparty/glpk-4.57/doc/glpk.tex → resources/3rdparty/glpk-4.65/doc/glpk.tex

@ -4,9 +4,9 @@
% This code is part of GLPK (GNU Linear Programming Kit).
%
% Copyright (C) 2000, 2001, 2002, 2003, 2004, 2005, 2006, 2007, 2008,
% 2009, 2010, 2011, 2013, 2014, 2015 Andrew Makhorin, Department for
% Applied Informatics, Moscow Aviation Institute, Moscow, Russia. All
% rights reserved. E-mail: <mao@gnu.org>.
% 2009, 2010, 2011, 2013, 2014, 2015, 2016, 2017 Andrew Makhorin,
% Department for Applied Informatics, Moscow Aviation Institute,
% Moscow, Russia. All rights reserved. E-mail: <mao@gnu.org>.
%
% GLPK is free software: you can redistribute it and/or modify it
% under the terms of the GNU General Public License as published by
@ -22,30 +22,38 @@
% along with GLPK. If not, see <http://www.gnu.org/licenses/>.
%***********************************************************************
% To produce glpk.pdf from glpk.tex run the following two commands:
% latex glpk.tex
% dvipdfm -p letter glpk.dvi
% Note: You need TeX Live 2010 or later version.
\documentclass[11pt]{report}
\usepackage{amssymb}
\usepackage[dvipdfm,linktocpage,colorlinks,linkcolor=blue,
urlcolor=blue]{hyperref}
\usepackage{indentfirst}
\usepackage{lscape}
\usepackage{niceframe}
\usepackage[all]{xy}
% US Letter = 8.5 x 11 in
\setlength{\textwidth}{6.5in}
\setlength{\textheight}{8.5in}
\setlength{\textheight}{9in}
\setlength{\oddsidemargin}{0in}
\setlength{\topmargin}{0in}
\setlength{\headheight}{0in}
\setlength{\headsep}{0in}
\setlength{\footskip}{0.5in}
%\setlength{\footskip}{0.5in}
\setlength{\parindent}{16pt}
\setlength{\parskip}{5pt}
\setlength{\topsep}{0pt}
\setlength{\partopsep}{0pt}
\setlength{\itemsep}{\parskip}
\setlength{\parsep}{0pt}
\setlength{\leftmargini}{\parindent}
\renewcommand{\labelitemi}{---}
%\setlength{\itemsep}{\parskip}
%\setlength{\parsep}{0pt}
%\setlength{\leftmargini}{\parindent}
%\renewcommand{\labelitemi}{---}
\newcommand{\Item}[1]{\parbox[t]{\parindent}{#1}}
\def\para#1{\noindent{\bf#1}}
\def\synopsis{\para{Synopsis}}
\def\description{\para{Description}}
@ -67,6 +75,8 @@ urlcolor=blue]{hyperref}
\thispagestyle{empty}
\artdecoframe{
\begin{center}
\vspace*{1.5in}
@ -84,15 +94,18 @@ urlcolor=blue]{hyperref}
\vspace{0.5in}
\begin{LARGE}
\sf for GLPK Version 4.57
\sf for GLPK Version 4.64
\end{LARGE}
\vspace{0.5in}
\begin{Large}
\sf (DRAFT, November 2015)
\sf (DRAFT, November 2017)
\end{Large}
\end{center}
\vspace*{3.8in}
}
\newpage
\vspace*{1in}
@ -105,9 +118,9 @@ GNU.
\noindent
Copyright \copyright{} 2000, 2001, 2002, 2003, 2004, 2005, 2006, 2007,
2008, 2009, 2010, 2011, 2013, 2014, 2015 Andrew Makhorin, Department
for Applied Informatics, Moscow Aviation Institute, Moscow, Russia. All
rights reserved.
2008, 2009, 2010, 2011, 2013, 2014, 2015, 2016, 2017 Andrew Makhorin,
Department for Applied Informatics, Moscow Aviation Institute, Moscow,
Russia. All rights reserved.
\noindent
Free Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
@ -133,9 +146,7 @@ versions.
\newpage
{\setlength{\parskip}{0pt}
\tableofcontents
}
{\setlength{\parskip}{0pt}\tableofcontents}
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%

31
resources/3rdparty/glpk-4.57/doc/glpk01.tex → resources/3rdparty/glpk-4.65/doc/glpk01.tex

@ -11,10 +11,10 @@ intended for solving linear programming (LP), mixed integer programming
\section{LP problem}
\label{seclp}
GLPK assumes the following formulation of {\it linear programming (LP)}
problem:
GLPK assumes the following formulation of the {\it linear programming
(LP)} problem:
\medskip\noindent
\noindent
\hspace{.5in} minimize (or maximize)
$$z = c_1x_{m+1} + c_2x_{m+2} + \dots + c_nx_{m+n} + c_0 \eqno (1.1)$$
\hspace{.5in} subject to linear constraints
@ -36,8 +36,6 @@ l_2&\leq&x_2&\leq&u_2 \\
l_{m+n}&\leq&x_{m+n}&\leq&u_{m+n} \\
\end{array} \eqno (1.3)
$$
\medskip\noindent
where: $x_1, x_2, \dots, x_m$ are auxiliary variables;
$x_{m+1}, x_{m+2}, \dots, x_{m+n}$ are structural variables;
$z$ is the objective function;
@ -76,16 +74,16 @@ structural as well as to auxiliary variables.
To solve the LP problem (1.1)---(1.3) is to find such values of all
structural and auxiliary variables, which:
\vspace*{-10pt}
%\vspace*{-10pt}
\begin{itemize}\setlength{\itemsep}{0pt}
\item satisfy to all the linear constraints (1.2), and
%\begin{itemize}\setlength{\itemsep}{0pt}
\Item{---}satisfy to all the linear constraints (1.2), and
\item are within their bounds (1.3), and
\Item{---}are within their bounds (1.3), and
\item provide smallest (in case of minimization) or largest (in case of
maximization) value of the objective function (1.1).
\end{itemize}
\Item{---}provide smallest (in case of minimization) or largest (in
case of maximization) value of the objective function (1.1).
%\end{itemize}
\section{MIP problem}
@ -107,8 +105,6 @@ structural variables to be of integer kind.)
In order to understand what GLPK is from the user's standpoint,
consider the following simple LP problem:
\medskip
\noindent
\hspace{.5in} maximize
$$z = 10 x_1 + 6 x_2 + 4 x_3$$
@ -128,8 +124,6 @@ At first, this LP problem should be transformed to the standard form
variables, by one for each original inequality constraint. Thus, the
problem can be reformulated as follows:
\medskip
\noindent
\hspace{.5in} maximize
$$z = 10 x_1 + 6 x_2 + 4 x_3$$
@ -149,9 +143,6 @@ $$
\nonumber -\infty < r \leq 300 && 0 \leq x_3 < +\infty \\
\end{array}
$$
\medskip
where $p, q, r$ are auxiliary variables (rows), and $x_1, x_2, x_3$ are
structural variables (columns).
@ -268,6 +259,8 @@ optimal basic solution found by the solver.
The statement \verb|s36| writes the optimal solution to the standard
output. The printout may look like follows:
\newpage
\begin{footnotesize}
\begin{verbatim}
* 0: objval = 0.000000000e+00 infeas = 0.000000000e+00 (0)

252
resources/3rdparty/glpk-4.57/doc/glpk02.tex → resources/3rdparty/glpk-4.65/doc/glpk02.tex

@ -87,17 +87,17 @@ structure directly and should deal only with pointers to these objects
The problem object consists of the following segments:
\vspace*{-8pt}
%\vspace*{-8pt}
\begin{itemize}\setlength{\itemsep}{0pt}
\item problem segment,
%\begin{itemize}\setlength{\itemsep}{0pt}
\Item{---}problem segment,
\item basis segment,
\Item{---}basis segment,
\item interior-point segment, and
\Item{---}interior-point segment, and
\item MIP segment.
\end{itemize}
\Item{---}MIP segment.
%\end{itemize}
\subsection{Problem segment}
@ -106,37 +106,37 @@ corresponds to the problem formulation (1.1)---(1.3) (see Section
\ref{seclp}, page \pageref{seclp}). This segment includes the following
components:
\vspace*{-8pt}
%\vspace*{-8pt}
\begin{itemize}\setlength{\itemsep}{0pt}
\item rows (auxiliary variables),
%\begin{itemize}\setlength{\itemsep}{0pt}
\Item{---}rows (auxiliary variables),
\item columns (structural variables),
\Item{---}columns (structural variables),
\item objective function, and
\Item{---}objective function, and
\item constraint matrix.
\end{itemize}
\Item{---}constraint matrix.
%\end{itemize}
\vspace*{-7pt}
%\vspace*{-7pt}
Rows and columns have the same set of the following attributes:
\vspace*{-7pt}
%\vspace*{-7pt}
\begin{itemize}\setlength{\itemsep}{0pt}
\item ordinal number,
%\begin{itemize}\setlength{\itemsep}{0pt}
\Item{---}ordinal number,
\item symbolic name (1 up to 255 arbitrary graphic characters),
\Item{---}symbolic name (1 up to 255 arbitrary graphic characters),
\item type (free, lower bound, upper bound, double bound, fixed),
\Item{---}type (free, lower bound, upper bound, double bound, fixed),
\item numerical values of lower and upper bounds,
\Item{---}numerical values of lower and upper bounds,
\item scale factor.
\end{itemize}
\Item{---}scale factor.
%\end{itemize}
\vspace*{-7pt}
%\vspace*{-7pt}
{\it Ordinal numbers} are intended for referencing rows and columns.
Row ordinal numbers are integers $1, 2, \dots, m$, and column ordinal
@ -173,19 +173,19 @@ order.
The {\it basis segment} of the problem object keeps information related
to the current basic solution. It includes:
\vspace*{-8pt}
%\vspace*{-8pt}
\begin{itemize}\setlength{\itemsep}{0pt}
\item row and column statuses,
%\begin{itemize}\setlength{\itemsep}{0pt}
\Item{---}row and column statuses,
\item basic solution statuses,
\Item{---}basic solution statuses,
\item factorization of the current basis matrix, and
\Item{---}factorization of the current basis matrix, and
\item basic solution components.
\end{itemize}
\Item{---}basic solution components.
%\end{itemize}
\vspace*{-8pt}
%\vspace*{-8pt}
The {\it row and column statuses} define which rows and columns are
basic and which are non-basic. These statuses may be assigned either by
@ -223,17 +223,17 @@ values of all auxiliary and structural variables.
The {\it MIP segment} is used only for MIP problems. This segment
includes:
\vspace*{-8pt}
%\vspace*{-8pt}
\begin{itemize}\setlength{\itemsep}{0pt}
\item column kinds,
%\begin{itemize}\setlength{\itemsep}{0pt}
\Item{---}column kinds,
\item MIP solution status, and
\Item{---}MIP solution status, and
\item MIP solution components.
\end{itemize}
\Item{---}MIP solution components.
%\end{itemize}
\vspace*{-8pt}
%\vspace*{-8pt}
The {\it column kinds} define which columns (i.e. structural variables)
are integer and which are continuous.
@ -332,8 +332,7 @@ by the parameter \verb|dir|:
\verb|GLP_MAX| means maximization.
\noindent
(Note that by default the problem is minimization.)
Note that by default the problem is minimization.
\subsection{glp\_add\_rows --- add new rows to problem object}
@ -513,7 +512,7 @@ while the parameter \verb|ub| is ignored.
Being added to the problem object each column is initially fixed at
zero, i.e. its type is \verb|GLP_FX| and both bounds are 0.
\newpage
%\newpage
\subsection{glp\_set\_obj\_coef --- set (change) objective coefficient
or constant term}
@ -533,6 +532,8 @@ the objective coefficient is specified by the parameter \verb|coef|.
If the parameter \verb|j| is 0, the routine sets (changes) the constant
term (``shift'') of the objective function.
\newpage
\subsection{glp\_set\_mat\_row --- set (replace) row of the constraint
matrix}
@ -597,6 +598,8 @@ If the parameter \verb|len| is 0, the parameters \verb|ind| and/or
If the basis factorization exists, changing the column corresponding
to a basic structural variable invalidates it.
\newpage
\subsection{glp\_load\_matrix --- load (replace) the whole constraint
matrix}
@ -710,7 +713,7 @@ remaining rows $a$, $c$, $e$ are assigned new oridinal numbers 1, 2, 3.
If the basis factorization exists, deleting active (binding) rows,
i.e. whose auxiliary variables are marked as non-basic, invalidates it.
\newpage
%\newpage
\subsection{glp\_del\_cols --- delete columns from problem object}
@ -772,7 +775,7 @@ problem object would be deleted with the routine \verb|glp_delete_prob|
and then created anew with the routine \verb|glp_create_prob|, with the
only exception that the pointer to the problem object remains valid.
\newpage
%\newpage
\subsection{glp\_delete\_prob --- delete problem object}
@ -854,6 +857,8 @@ flag (i.e. ``sense'' of the objective function):
The routine \verb|glp_get_num_rows| returns the current number of rows
in the specified problem object.
\newpage
\subsection{glp\_get\_num\_cols --- retrieve number of columns}
\synopsis
@ -1061,7 +1066,7 @@ number of elements in $i$-th row, $n$ is the number of columns.
The parameter \verb|ind| and/or \verb|val| can be specified as
\verb|NULL|, in which case corresponding information is not stored.
\newpage
%\newpage
\returns
@ -1116,28 +1121,28 @@ object.
It is important to note that:
1. On creating the problem object with the routine
\Item{1.}On creating the problem object with the routine
\verb|glp_create_prob| the name index is {\it not} created.
2. The name index can be created (destroyed) at any time with the
\Item{2.}The name index can be created (destroyed) at any time with the
routine \verb|glp_create_index| (\verb|glp_delete_index|). Having been
created the name index becomes part of the corresponding problem
object.
3. The time taken to create the name index is $O[(m+n)\log_2(m+n)]$,
so it is recommended to create the index only once, for example, just
after the problem object was created.
\Item{3.}The time taken to create the name index is
$O[(m+n)\log_2(m+n)]$, so it is recommended to create the index only
once, for example, just after the problem object was created.
4. If the name index exists, it is automatically updated every time
the name of a row/column is assigned/changed. The update operation
\Item{4.}If the name index exists, it is automatically updated every
time the name of a row/column is assigned/changed. The update operation
takes logarithmic time.
5. If the name index does not exist, the application should not call
the routines \verb|glp_find_row| and \verb|glp_find_col|. Otherwise,
an error message will be issued and abnormal program termination will
occur.
\Item{5.}If the name index does not exist, the application should not
call the routines \verb|glp_find_row| and \verb|glp_find_col|.
Otherwise, an error message will be issued and abnormal program
termination will occur.
6. On destroying the problem object with the routine
\Item{6.}On destroying the problem object with the routine
\verb|glp_delete_prob|, the name index, if exists, is automatically
destroyed.
@ -1267,6 +1272,8 @@ for $i$-th row of the specified problem object.
The routine \verb|glp_set_sjj| sets (changes) the scale factor $s_{jj}$
for $j$-th column of the specified problem object.
\newpage
\subsection{glp\_get\_rii --- retrieve row scale factor}
\synopsis
@ -1385,7 +1392,7 @@ Another way to construct an initial basis is to use API routines like
{\it crashing}.\footnote{This term is from early linear programming
systems and means a heuristic to construct a valid initial basis.} Note
that on normal exit the simplex solver remains the basis valid, so in
case of reoptimization there is no need to construct an initial basis
case of re-optimization there is no need to construct an initial basis
from scratch.
\subsection{glp\_set\_row\_stat --- set (change) row status}
@ -1653,9 +1660,7 @@ solver failure.\\
\verb|GLP_EOBJLL| & The search was prematurely terminated, because the
objective function being maximized has reached its lower limit and
continues decreasing (the dual simplex only).\\
\end{retlist}
\begin{retlist}
\verb|GLP_EOBJUL| & The search was prematurely terminated, because the
objective function being minimized has reached its upper limit and
continues increasing (the dual simplex only).\\
@ -1665,7 +1670,9 @@ simplex iteration limit has been exceeded.\\
\verb|GLP_ETMLIM| & The search was prematurely terminated, because the
time limit has been exceeded.\\
\end{retlist}
\begin{retlist}
\verb|GLP_ENOPFS| & The LP problem instance has no primal feasible
solution (only if the LP presolver is used).\\
@ -1710,7 +1717,7 @@ reports some information about the current basic solution, which is
sent to the terminal. This information has the following format:
\begin{verbatim}
nnn: obj = xxx infeas = yyy (ddd)
nnn: obj = xxx infeas = yyy (num) cnt
\end{verbatim}
\noindent
@ -1718,8 +1725,9 @@ where: `\verb|nnn|' is the iteration number, `\verb|xxx|' is the
current value of the objective function (it is unscaled and has correct
sign); `\verb|yyy|' is the current sum of primal or dual
infeasibilities (it is scaled and therefore may be used only for visual
estimating), `\verb|ddd|' is the current number of fixed basic
variables.
estimating), `\verb|num|' is the current number of primal or dual
infeasibilities (phase I) or non-optimalities (phase II), `\verb|cnt|'
is the number of basis factorizations since the last terminal output.
The symbol preceding the iteration number indicates which phase of the
simplex method is in effect:
@ -1731,8 +1739,10 @@ the dual simplex;
{\it Asterisk} (\verb|*|) means that the solver is searching for
optimal solution using the primal simplex;
{\it Vertical dash} (\verb/|/) means that the solver is searching for
optimal solution using the dual simplex.
{\it Hash} (\verb|#|) means that the solver is searching for optimal
solution using the dual simplex.
\newpage
\para{Control parameters}
@ -1795,7 +1805,8 @@ Tolerance used to check if the basic solution is primal feasible.
(Do not change this parameter without detailed understanding its
purpose.)
\newpage
%\newpage
\bigskip
{\tt double tol\_dj} (default: {\tt 1e-7})
@ -1811,7 +1822,8 @@ Tolerance used to choose eligble pivotal elements of the simplex table.
(Do not change this parameter without detailed understanding its
purpose.)
\bigskip
%\bigskip
\newpage
{\tt double obj\_ll} (default: {\tt -DBL\_MAX})
@ -1903,28 +1915,25 @@ Below here is shown the terminal output from this example program.
\begin{footnotesize}
\begin{verbatim}
Reading problem data from `25fv47.mps'...
Reading problem data from '25fv47.mps'...
Problem: 25FV47
Objective: R0000
822 rows, 1571 columns, 11127 non-zeros
6919 records were read
Crashing...
Size of triangular part = 799
0: obj = 1.627307307e+04 infeas = 5.194e+04 (23)
200: obj = 1.474901610e+04 infeas = 1.233e+04 (19)
400: obj = 1.343909995e+04 infeas = 3.648e+03 (13)
600: obj = 1.756052217e+04 infeas = 4.179e+02 (7)
* 775: obj = 1.789251591e+04 infeas = 4.982e-14 (1)
* 800: obj = 1.663354510e+04 infeas = 2.857e-14 (1)
* 1000: obj = 1.024935068e+04 infeas = 1.958e-12 (1)
* 1200: obj = 7.860174791e+03 infeas = 2.810e-29 (1)
* 1400: obj = 6.642378184e+03 infeas = 2.036e-16 (1)
* 1600: obj = 6.037014568e+03 infeas = 0.000e+00 (1)
* 1800: obj = 5.662171307e+03 infeas = 6.447e-15 (1)
* 2000: obj = 5.528146165e+03 infeas = 9.764e-13 (1)
* 2125: obj = 5.501845888e+03 infeas = 0.000e+00 (1)
OPTIMAL SOLUTION FOUND
Writing basic solution to `25fv47.txt'...
One free row was removed
Constructing initial basis...
Size of triangular part is 812
GLPK Simplex Optimizer, v4.57
821 rows, 1571 columns, 10400 non-zeros
0: obj = 7.131703290e+03 inf = 2.145e+05 (204)
500: obj = 1.886711682e+04 inf = 8.273e+02 (36) 4
741: obj = 1.846047936e+04 inf = 5.575e-14 (0) 2
* 1000: obj = 9.220063473e+03 inf = 2.423e-14 (432) 2
* 1500: obj = 6.187659664e+03 inf = 1.019e-13 (368) 4
* 2000: obj = 5.503442062e+03 inf = 0.000e+00 (33) 5
* 2052: obj = 5.501845888e+03 inf = 0.000e+00 (0)
OPTIMAL LP SOLUTION FOUND
Writing basic solution to '25fv47.txt'...
\end{verbatim}
\end{footnotesize}
@ -1965,31 +1974,24 @@ Below here is shown the terminal output from this example program.
\begin{footnotesize}
\begin{verbatim}
Reading problem data from `25fv47.mps'...
Reading problem data from '25fv47.mps'...
Problem: 25FV47
Objective: R0000
822 rows, 1571 columns, 11127 non-zeros
6919 records were read
0: infeas = 1.223e+03 (516)
200: infeas = 7.000e+00 (471)
240: infeas = 1.106e-14 (461)
| 400: obj = -5.394267152e+03 infeas = 5.571e-16 (391)
| 600: obj = -4.586395752e+03 infeas = 1.389e-15 (340)
| 800: obj = -4.158268146e+03 infeas = 1.640e-15 (264)
| 1000: obj = -3.725320045e+03 infeas = 5.181e-15 (245)
| 1200: obj = -3.104802163e+03 infeas = 1.019e-14 (210)
| 1400: obj = -2.584190499e+03 infeas = 8.865e-15 (178)
| 1600: obj = -2.073852927e+03 infeas = 7.867e-15 (142)
| 1800: obj = -1.164037407e+03 infeas = 8.792e-15 (109)
| 2000: obj = -4.370590250e+02 infeas = 2.591e-14 (85)
| 2200: obj = 1.068240144e+03 infeas = 1.025e-13 (70)
| 2400: obj = 1.607481126e+03 infeas = 3.272e-14 (67)
| 2600: obj = 3.038230551e+03 infeas = 4.850e-14 (52)
| 2800: obj = 4.316238187e+03 infeas = 2.622e-14 (36)
| 3000: obj = 5.443842629e+03 infeas = 3.976e-15 (11)
| 3060: obj = 5.501845888e+03 infeas = 8.806e-15 (2)
OPTIMAL SOLUTION FOUND
Writing basic solution to `25fv47.txt'...
One free row was removed
GLPK Simplex Optimizer, v4.57
821 rows, 1571 columns, 10400 non-zeros
0: inf = 1.223e+02 (41)
258: inf = 3.091e-16 (0) 2
# 500: obj = -5.071287080e+03 inf = 2.947e-15 (292) 2
# 1000: obj = -1.352843873e+03 inf = 8.452e-15 (302) 5
# 1500: obj = 7.985859737e+02 inf = 1.127e-14 (263) 5
# 2000: obj = 3.059023029e+03 inf = 6.290e-11 (197) 4
# 2500: obj = 5.354770966e+03 inf = 7.172e-13 (130) 5
# 2673: obj = 5.501845888e+03 inf = 3.802e-16 (0) 2
OPTIMAL LP SOLUTION FOUND
Writing basic solution to '25fv47.txt'...
\end{verbatim}
\end{footnotesize}
@ -2012,9 +2014,9 @@ internal computations it uses arithmetic of rational numbers, which is
exact in mathematical sense, i.e. free of round-off errors unlike
floating-point arithmetic.
Note that the routine \verb|glp_exact| uses only two control parameters
passed in the structure \verb|glp_smcp|, namely, \verb|it_lim| and
\verb|tm_lim|.
Note that the routine \verb|glp_exact| uses only three control
parameters passed in the structure \verb|glp_smcp|, namely,
\verb|msg_lev|, \verb|it_lim|, and \verb|tm_lim|.
\returns
@ -2182,7 +2184,7 @@ the auxiliary variable associated with \verb|i|-th row as follows:
\verb|GLP_NS| --- non-basic fixed variable.
\newpage
%\newpage
\subsection{glp\_get\_row\_prim --- retrieve row primal value}
@ -2246,7 +2248,7 @@ the structural variable associated with \verb|j|-th column as follows:
The routine \verb|glp_get_col_prim| returns primal value of the
structural variable associated with \verb|j|-th column.
\newpage
%\newpage
\subsection{glp\_get\_col\_dual --- retrieve column dual value}
@ -2261,6 +2263,8 @@ structural variable associated with \verb|j|-th column.
The routine \verb|glp_get_col_dual| returns dual value (i.e. reduced
cost) of the structural variable associated with \verb|j|-th column.
\newpage
\subsection{glp\_get\_unbnd\_ray --- determine variable causing
unboundedness}
@ -2433,22 +2437,22 @@ interior point method. SIAM J. on Optim., 2(4), pp. 575-601, 1992.}
Note that currently the GLPK interior-point solver does not include
many important features, in particular:
\vspace*{-8pt}
%\vspace*{-8pt}
\begin{itemize}
\item it is not able to process dense columns. Thus, if the constraint
matrix of the LP problem has dense columns, the solving process may be
inefficient;
%\begin{itemize}
\Item{---}it is not able to process dense columns. Thus, if the
constraint matrix of the LP problem has dense columns, the solving
process may be inefficient;
\item it has no features against numerical instability. For some LP
\Item{---}it has no features against numerical instability. For some LP
problems premature termination may happen if the matrix $ADA^T$ becomes
singular or ill-conditioned;
\item it is not able to identify the optimal basis, which corresponds
to the interior-point solution found.
\end{itemize}
\Item{---}it is not able to identify the optimal basis, which
corresponds to the interior-point solution found.
%\end{itemize}
\vspace*{-8pt}
%\vspace*{-8pt}
\para{Terminal output}
@ -3207,6 +3211,8 @@ by the solver).
The routine \verb|glp_mip_obj_val| returns value of the objective
function for MIP solution.
\newpage
\subsection{glp\_mip\_row\_val --- retrieve row value}
\synopsis
@ -3305,6 +3311,8 @@ and variables with numbers $m+1$ to $m+n$ correspond to columns. If
the error reported is exact zero, corresponding row, column or variable
number is set to zero.
\newpage
\para{Background}
\def\arraystretch{1.5}
@ -3359,6 +3367,8 @@ correspond to largest absolute and relative errors:
$${\tt ae\_max}=\max_{1\leq k \leq m+n}|h_k|,$$
$${\tt re\_max}=\max_{1\leq k \leq m+n}\frac{|h_k|}{1+|x_k|}.$$
\newpage
The third condition checked by the routine is:
$${\rm grad}\;Z = c = (\tilde{A})^T \pi + d,$$
where $Z$ is the objective function, $c$ is the vector of objective

830
resources/3rdparty/glpk-4.65/doc/glpk03.tex
File diff suppressed because it is too large
View File

37
resources/3rdparty/glpk-4.57/doc/glpk04.tex → resources/3rdparty/glpk-4.65/doc/glpk04.tex

@ -51,6 +51,8 @@ auxiliary and structural variables. This allows combining all these
variables into one vector that leads to the following problem
statement:
\newpage
\noindent
\hspace{.5in} minimize (or maximize)
$$z=(0\ |\ c)^Tx+c_0\eqno(3.4)$$
@ -113,7 +115,7 @@ $$(I\ |-\!A)\Pi^T\Pi x=0\ \ \ \Rightarrow\ \ \ (B\ |\ N)
where
$$(B\ |\ N)=(I\ |-\!A)\Pi^T.\eqno(3.9)$$
\newpage
%\newpage
Matrix $B$ is a square non-singular $m\times m$-matrix, which is
composed from columns of the augmented constraint matrix corresponding
@ -166,14 +168,17 @@ $$\lambda_l\leq 0,\ \ \lambda_u\geq 0\ \ \mbox{(maximization)}
$$(\lambda_l)_k(x_k-l_k)=0,\ \ (\lambda_u)_k(x_k-u_k)=0,\ \ k=1,2,\dots,
m+n\eqno(3.19)$$
where:
$\pi=(\pi_1,\pi_2,\dots,\pi_m)$ is a $m$-vector of Lagrange
$\pi=(\pi_1,\dots,\pi_m)$ is a $m$-vector of Lagrange
multipliers for equality constraints (3.5);
$\lambda_l=[(\lambda_l)_1,(\lambda_l)_2,\dots,(\lambda_l)_n]$ is a
$n$-vector of Lagrange multipliers for lower bound constraints (3.6);
$\lambda_u=[(\lambda_u)_1,(\lambda_u)_2,\dots,(\lambda_u)_n]$ is a
$n$-vector of Lagrange multipliers for upper bound constraints (3.6).
\newpage
$\lambda_l=[(\lambda_l)_1,\dots,(\lambda_l)_n]$ is a $n$-vector of
Lagrange multipliers for lower bound constraints (3.6);
$\lambda_u=[(\lambda_u)_1,\dots,(\lambda_u)_n]$ is a $n$-vector of
Lagrange multipliers for upper bound constraints (3.6).
%\newpage
Condition (3.14) is the {\it primal} (original) system of equality
constraints (3.5).
@ -196,11 +201,11 @@ the corresponding Lagrange multiplier ($(\lambda_l)_k$ or
$(\lambda_u)_k$) must be active.
In GLPK two multipliers $(\lambda_l)_k$ and $(\lambda_u)_k$ for each
primal (original) variable $x_k$, $k=1,2,\dots,\linebreak m+n$, are
combined into one multiplier:
primal variable $x_k$, $k=1,\dots,m+n$, are combined into one
multiplier:
$$\lambda_k=(\lambda_l)_k+(\lambda_u)_k,\eqno(3.20)$$
which is called a {\it dual variable} for $x_k$. This {\it cannot} lead
to the ambiguity, because both lower and upper bounds of $x_k$ cannot be
to an ambiguity, because both lower and upper bounds of $x_k$ cannot be
active at the same time,\footnote{If $x_k$ is a fixed variable, we can
think it as double-bounded variable $l_k\leq x_k\leq u_k$, where
$l_k=u_k.$} so at least one of $(\lambda_l)_k$ and $(\lambda_u)_k$ must
@ -258,10 +263,6 @@ any basic solution $\lambda_B=0$. Corresponding values of dual variables
$\lambda_N$ for non-basic variables $x_N$ can be determined in the
following way. From the dual system (3.15) we have:
$$(I\ |-\!A)^T\pi+\lambda=(0\ |\ c)^T,\eqno(3.22)$$
\newpage
\noindent
so multiplying both sides of (3.22) by matrix $\Pi$ gives:
$$\Pi(I\ |-\!A)^T\pi+\Pi\lambda=\Pi(0\ |\ c)^T.\eqno(3.23)$$
From (3.9) it follows that
@ -402,7 +403,7 @@ routine, which uses the basis factorization, the application program
must make sure (using the routine \verb|glp_bf_exists|) that the
factorization exists and therefore available for computations.
\newpage
%\newpage
\subsection{glp\_factorize --- compute the basis factorization}
@ -560,6 +561,8 @@ glp_set_bfcp(lp, &parm);
\end{verbatim}
\end{footnotesize}
\newpage
\para{Control parameters}
This paragraph describes all basis factorization control parameters
@ -622,7 +625,7 @@ on choosing a pivot element, \verb|piv_lim| $\geq$ 1. If \verb|piv_lim|
candidates have been considered, the pivoting routine prematurely
terminates the search with the best candidate found.
\newpage
\medskip
{\tt int suhl} (default: {\tt GLP\_ON})
@ -1014,6 +1017,8 @@ simplex table column $\Xi_j=(\xi_{ij})$ and uses the permutation matrix
$\Pi$ to convert row indices $i$ to original ordinal numbers of
auxiliary and structural variables.
\newpage
\subsection{glp\_transform\_row --- transform explicitly specified row}
\synopsis

26
resources/3rdparty/glpk-4.57/doc/glpk05.tex → resources/3rdparty/glpk-4.65/doc/glpk05.tex

@ -103,7 +103,7 @@ If $L=\varnothing$ then GO TO 9.
Select $P\in L$, i.e. make active subproblem $P$ current.
\newpage
%\newpage
{\it 3. Solving LP relaxation}
@ -231,23 +231,23 @@ Fig. 1. An example of the search tree.
In GLPK each node may have one of the following four statuses:
\vspace*{-8pt}
%\vspace*{-8pt}
\begin{itemize}
\item {\it current node} is the active node currently being
%\begin{itemize}
\Item{---}{\it current node} is the active node currently being
processed;
\item {\it active node} is a leaf node, which still has to be
\Item{---}{\it active node} is a leaf node, which still has to be
processed;
\item {\it non-active node} is a node, which has been processed,
\Item{---}{\it non-active node} is a node, which has been processed,
but not fathomed;
\item {\it fathomed node} is a node, which has been processed and
\Item{---}{\it fathomed node} is a node, which has been processed and
fathomed.
\end{itemize}
%\end{itemize}
\vspace*{-8pt}
%\vspace*{-8pt}
In the data structure representing the search tree GLPK keeps only
current, active, and non-active nodes. Once a node has been fathomed,
@ -571,6 +571,8 @@ where \verb|best_mip| is the best integer feasible solution found so
far, \verb|best_bnd| is the best (global) bound. If no integer feasible
solution has been found yet, \verb|gap| is set to \verb|DBL_MAX|.
\newpage
\returns
The routine \verb|glp_ios_mip_gap| returns the relative MIP gap.
@ -713,6 +715,8 @@ The parameter \verb|sel| is a flag that indicates which branch
\verb|GLP_NO_BRNCH| --- use general selection technique.
\newpage
\para{Comments}
On branching the solver removes the current active subproblem from the
@ -885,6 +889,8 @@ subproblem is the level of its parent plus one.)
The routine \verb|glp_ios_node_bound| returns the local bound for
(active or inactive) subproblem, whose reference number is $p$.
\newpage
\para{Comments}
The local bound for subproblem $p$ is an lower (minimization) or upper
@ -992,6 +998,8 @@ The parameter \verb|type| specifies the constraint type as follows:
\verb|GLP_UP| means inequality constraint $\Sigma a_jx_j\leq b$;
\newpage
The parameter \verb|rhs| specifies the right-hand side $b$.
All cutting plane constraints in the cut pool are identified by their

2
resources/3rdparty/glpk-4.57/doc/glpk06.tex → resources/3rdparty/glpk-4.65/doc/glpk06.tex

@ -388,6 +388,8 @@ The routine \verb|glp_realloc| returns a pointer to the memory block
reallocated. To free this block the routine \verb|glp_free| (not the
standard C function \verb|free|!) should be used.
\newpage
\subsection{glp\_free --- free memory block}
\synopsis

0
resources/3rdparty/glpk-4.57/doc/glpk07.tex → resources/3rdparty/glpk-4.65/doc/glpk07.tex

68
resources/3rdparty/glpk-4.57/doc/glpk08.tex → resources/3rdparty/glpk-4.65/doc/glpk08.tex

@ -28,7 +28,7 @@ fixed fields:
\begin{center}
\begin{tabular}{lcccccc}
& Field 1 & Field 2 & Field 3 & Field 4 & Field 5 & Feld 6 \\
& Field 1 & Field 2 & Field 3 & Field 4 & Field 5 & Field 6 \\
\hline
Columns & 2---3 & 5---12 & 15---22 & 25---36 & 40---47 & 50---61 \\
Contents & Code & Name & Name & Number & Name & Number \\
@ -55,7 +55,7 @@ characters. If the sign $s$ is omitted, the plus sign is assumed. The
exponent part is optional. If a number contains spaces, the spaces are
ignored.
\newpage
%\newpage
If a card has the asterisk `\verb|*|' in the column 1, this card is
considered as a comment and ignored. Besides, if the first character in
@ -64,37 +64,37 @@ dollar sign to the end of card are considered as a comment and ignored.
MPS file should contain cards in the following order:
\vspace*{-8pt}
%\vspace*{-8pt}
\begin{itemize}
\item NAME indicator card;
%\begin{itemize}
\Item{---}NAME indicator card;
\item ROWS indicator card;
\Item{---}ROWS indicator card;
\item data cards specifying rows (constraints);
\Item{---}data cards specifying rows (constraints);
\item COLUMNS indicator card;
\Item{---}COLUMNS indicator card;
\item data cards specifying columns (structural variables) and
\Item{---}data cards specifying columns (structural variables) and
constraint coefficients;
\item RHS indicator card;
\Item{---}RHS indicator card;
\item data cards specifying right-hand sides of constraints;
\Item{---}data cards specifying right-hand sides of constraints;
\item RANGES indicator card;
\Item{---}RANGES indicator card;
\item data cards specifying ranges for double-bounded constraints;
\Item{---}data cards specifying ranges for double-bounded constraints;
\item BOUNDS indicator card;
\Item{---}BOUNDS indicator card;
\item data cards specifying types and bounds of structural
\Item{---}data cards specifying types and bounds of structural
variables;
\item ENDATA indicator card.
\end{itemize}
\Item{---}ENDATA indicator card.
%\end{itemize}
\vspace*{-8pt}
%\vspace*{-8pt}
{\it Section} is a group of cards consisting of an indicator card and
data cards succeeding this indicator card. For example, the ROWS section
@ -120,7 +120,7 @@ position, except position 1, which must be blank, and must be separated
from each other by one or more blanks. However, the fields must appear
in the same order as in fixed MPS format.
\newpage
%\newpage
Symbolic names in fields 2, 3, and 5 may be longer than 8
characters\footnote{GLPK allows symbolic names having up to 255
@ -136,6 +136,8 @@ If the first character of any field (not necessarily fields 3 and 5)
is the dollar sign (\$), all characters from the dollar sign to the end
of record are considered as a comment and ignored.
\newpage
\section{NAME indicator card}
The NAME indicator card should be the first card in the MPS file
@ -178,7 +180,7 @@ can be considered as bounds of such auxiliary variable.
The filed 2 specifies a row name (which is considered as the name of
the corresponding auxiliary variable).
\newpage
%\newpage
The fields 3, 4, 5, and 6 are not used and should be empty.
@ -236,7 +238,7 @@ vectors in the same MPS file. However, before solving the problem a
particular RHS vector should be chosen.}. If this field is empty, the
RHS vector name from the immediately preceeding data card is assumed.
\newpage
%\newpage
The field 3 specifies a row name defined in the ROWS section.
@ -260,6 +262,8 @@ Right-hand sides not specified in the RHS section are considered as
zeros. Therefore zero right-hand sides may be omitted, although it is
allowed to explicitly specify them.
\newpage
\section{RANGES section}
The RANGES section should start with the indicator card, which contains
@ -297,7 +301,7 @@ section.
For each double-side constraint specified in the RANGES section its
lower and upper bounds are determined as follows:
\newpage
%\newpage
\begin{center}
\begin{tabular}{cccc}
@ -366,7 +370,7 @@ have zero lower bound and no upper bound. Lower ($l_j$) and upper
following way, where $s_j$ is a corresponding bound value explicitly
specified in the BOUNDS section:
\newpage
%\newpage
\verb|LO| sets $l_j$ to $s_j$;
@ -430,9 +434,6 @@ SI &= .02\ bin_1 + .06\ bin_2 + .08\ bin_3 + .12\ bin_4 + .02\ bin_5
+ .01\ al + .97\ si \\
\end{array}
$$
\newpage
\noindent\hspace{.5in}and bounds of (auxiliary and structural)
variables
$$
@ -452,7 +453,7 @@ $$
A complete MPS file which specifies data for this example is shown
below (the first two comment lines show card positions).
\bigskip
\newpage
\begin{footnotesize}
\begin{verbatim}
@ -513,11 +514,11 @@ ENDATA
\end{verbatim}
\end{footnotesize}
\vspace*{-6pt}
%\vspace*{-6pt}
\section{MIP features}
\vspace*{-4pt}
%\vspace*{-4pt}
The MPS format provides two ways for introducing integer variables into
the problem.
@ -590,9 +591,9 @@ $$
\end{array}
$$
The corresponding MPS file may look like the following:
The corresponding MPS file may look like follows:
\medskip
\newpage
\begin{footnotesize}
\begin{verbatim}
@ -628,13 +629,14 @@ ENDATA
\end{verbatim}
\end{footnotesize}
\newpage
%\newpage
\vspace{-3pt}
The same example may be coded without INTORG/INTEND markers using the
bound type UI for the variable $x_2$ and the bound type BV for the
variable $x_3$:
\medskip
%\medskip
\begin{footnotesize}
\begin{verbatim}

49
resources/3rdparty/glpk-4.57/doc/glpk09.tex → resources/3rdparty/glpk-4.65/doc/glpk09.tex

@ -93,24 +93,24 @@ improve readability of the LP file. Besides, blanks should be used to
separate elements from each other if there is no other way to do that
(for example, to separate a keyword from a following symbolic name).
The order of an LP file is:
The order of an LP file is the following:
\vspace*{-8pt}
%\vspace*{-8pt}
\begin{itemize}
\item objective function definition;
%\begin{itemize}
\Item{---}objective function definition;
\item constraints section;
\Item{---}constraints section;
\item bounds section;
\Item{---}bounds section;
\item general, integer, and binary sections (can appear in arbitrary
order);
\Item{---}general, integer, and binary sections (can appear in
arbitrary order);
\item end keyword.
\end{itemize}
\Item{---}end keyword.
%\end{itemize}
\vspace*{-8pt}
%\vspace*{-8pt}
These components are discussed in following sections.
@ -126,7 +126,7 @@ $$
\begin{array}{@{}c@{}}
{\tt minimize} \\ {\tt maximize}
\end{array}
\right\}\ f\ {\tt :}\ s\ c\ x\ s\ c\ x\ \dots\ s\ c\ x
\right\}\ f\ {\tt :}\ s\ c\ x\ \dots\ s\ c\ x
$$
where $f$ is a symbolic name of the objective function, $s$ is a sign
\verb|+| or \verb|-|, $c$ is a numeric constant that denotes an
@ -165,7 +165,6 @@ The constraint section has the following form:
\begin{tabular}{l}
\verb|subject to| \\
{\it constraint}$_1$ \\
{\it constraint}$_2$ \\
\hspace{20pt}\dots \\
{\it constraint}$_m$ \\
\end{tabular}
@ -181,7 +180,7 @@ line as the keyword `\verb|subject to|'.
Constraint definitions have the following form:
$$
r\ {\tt:}\ s\ c\ x\ s\ c\ x\ \dots\ s\ c\ x
r\ {\tt:}\ s\ c\ x\ \dots\ s\ c\ x
\ \left\{
\begin{array}{@{}c@{}}
\mbox{\tt<=} \\ \mbox{\tt>=} \\ \mbox{\tt=}
@ -194,13 +193,13 @@ coefficient, $x$ is a symbolic name of a variable, $b$ is a right-hand
side.
The name $r$ of a constraint (which is the name of the corresponding
auxiliary variable) is optional and may be omitted (together with the
semicolon that follows it). In this case the default names like
auxiliary variable) is optional and may be omitted together with the
semicolon that follows it. In the latter case the default names like
`\verb|r.nnn|' are assigned to unnamed constraints.
The linear form $s\ c\ x\ s\ c\ x\ \dots\ s\ c\ x$ in the left-hand
side of a constraint definition has exactly the same meaning as in the
case of the objective function definition (see above).
The linear form $s\ c\ x\ \dots\ s\ c\ x$ in the left-hand side of
a constraint definition has exactly the same meaning as in the case of
the objective function definition (see above).
After the linear form one of the following delimiters that indicates
the constraint sense must be specified:
@ -251,7 +250,6 @@ The bounds section has the following form:
\begin{tabular}{l}
\verb|bounds| \\
{\it definition}$_1$ \\
{\it definition}$_2$ \\
\hspace{20pt}\dots \\
{\it definition}$_p$ \\
\end{tabular}
@ -266,7 +264,7 @@ implementation allows several bound definitions to be placed on the
same line.} except the very first bound definition which can begin on
the same line as the keyword `\verb|bounds|'.
\newpage
%\newpage
Syntactically constraint definitions can have one of the following six
forms:
@ -285,8 +283,8 @@ $x$ \verb|free| &specifies free variable
\noindent
where $x$ is a symbolic name of a variable, $l$ is a numeric constant
with an optional sign that defines a lower bound of the variable or
\verb|-inf| that means that the variable has no lower bound, $u$ is a
numeric constant with an optional sign that defines an upper bound of
\verb|-inf| that means that the variable has no lower bound, $u$ is
a~numeric constant with an optional sign that defines an upper bound of
the variable or \verb|+inf| that means that the variable has no upper
bound, $t$ is a numeric constant with an optional sign that defines a
fixed value of the variable.
@ -329,7 +327,6 @@ $
\right\}
$ \\
\hspace{10pt}$x_1$ \\
\hspace{10pt}$x_2$ \\
\hspace{10pt}\dots \\
\hspace{10pt}$x_q$ \\
\end{tabular}
@ -344,7 +341,7 @@ line.} except the very first symbolic name which can begin on the same
line as the keyword `\verb|general|', `\verb|integer|', or
`\verb|binary|'.
\newpage
%\newpage
If a variable appears in the general or the integer section, it is
assumed to be general integer variable. If a variable appears in the
@ -363,6 +360,8 @@ Here is an example of the integer section:
z35
\end{verbatim}
\newpage
\section{End keyword}
The keyword `\verb|end|' is intended to end the LP file. It must begin

5
resources/3rdparty/glpk-4.57/doc/glpk10.tex → resources/3rdparty/glpk-4.65/doc/glpk10.tex

@ -138,11 +138,6 @@ the problem, and write its solution to an output text file.
--mipgap tol set relative mip gap tolerance to tol
--minisat translate integer feasibility problem to CNF-SAT
and solve it with MiniSat solver
\end{verbatim}
\newpage
\begin{verbatim}
--objbnd bound add inequality obj <= bound (minimization) or
obj >= bound (maximization) to integer feasibility
problem (assumes --minisat)

12
resources/3rdparty/glpk-4.57/doc/glpk11.tex → resources/3rdparty/glpk-4.65/doc/glpk11.tex

@ -1,10 +1,10 @@
%* glpk11.tex *%
\chapter{External Software Modules Used In GLPK}
\chapter{External Software Used In GLPK}
In the GLPK package there are used some external software modules
listed in this Appendix. Note that these modules are {\it not} part of
GLPK, but are used with GLPK and included in the distribution.
In the GLPK package there are used some external software listed in
this Appendix. Note that these software are {\it not} part of GLPK, but
are used with GLPK and included in the distribution.
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
@ -117,6 +117,8 @@ details.
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
%\newpage
\section{MiniSat}
\noindent
@ -128,6 +130,8 @@ MiniSat is a minimalistic implementation of a Chaff-like SAT solver
based on the two-literal watch scheme for fast BCP and clause learning
by conflict analysis.
\newpage
\para{License}
Permission is hereby granted, free of charge, to any person obtaining a

51
resources/3rdparty/glpk-4.57/doc/glpk12.tex → resources/3rdparty/glpk-4.65/doc/glpk12.tex

@ -21,7 +21,7 @@ Everyone is permitted to copy and distribute verbatim copies
of this license document, but changing it is not allowed.
\end{quotation}
\section*{Preamble}
\medskip\para{\normalsize Preamble}
The GNU General Public License is a free, copyleft license for
software and other kinds of works.
@ -84,9 +84,11 @@ patents cannot be used to render the program non-free.
The precise terms and conditions for copying, distribution and
modification follow.
\section*{TERMS AND CONDITIONS}
\newpage
\medskip\para{\normalsize TERMS AND CONDITIONS}
\subsubsection*{0. Definitions.}
\medskip\para{\normalsize 0. Definitions.}
``This License'' refers to version 3 of the GNU General Public
License.
@ -126,7 +128,7 @@ work under this License, and how to view a copy of this License. If
the interface presents a list of user commands or options, such as a
menu, a prominent item in the list meets this criterion.
\subsubsection*{1. Source Code.}
\medskip\para{\normalsize 1. Source Code.}
The ``source code'' for a work means the preferred form of the work
for making modifications to it. ``Object code'' means any non-source
@ -168,7 +170,7 @@ Source.
The Corresponding Source for a work in source code form is that
same work.
\subsubsection*{2. Basic Permissions.}
\medskip\para{\normalsize 2. Basic Permissions.}
All rights granted under this License are granted for the term of
copyright on the Program, and are irrevocable provided the stated
@ -193,7 +195,7 @@ your copyrighted material outside their relationship with you.
the conditions stated below. Sublicensing is not allowed; section 10
makes it unnecessary.
\subsubsection*{3. Protecting Users' Legal Rights From
\medskip\para{\normalsize 3. Protecting Users' Legal Rights From
Anti-Circumvention Law.}
No covered work shall be deemed part of an effective technological
@ -210,7 +212,7 @@ modification of the work as a means of enforcing, against the work's
users, your or third parties' legal rights to forbid circumvention of
technological measures.
\subsubsection*{4. Conveying Verbatim Copies.}
\medskip\para{\normalsize 4. Conveying Verbatim Copies.}
You may convey verbatim copies of the Program's source code as you
receive it, in any medium, provided that you conspicuously and
@ -223,7 +225,7 @@ recipients a copy of this License along with the Program.
You may charge any price or no price for each copy that you convey,
and you may offer support or warranty protection for a fee.
\subsubsection*{5. Conveying Modified Source Versions.}
\medskip\para{\normalsize 5. Conveying Modified Source Versions.}
You may convey a work based on the Program, or the modifications to
produce it from the Program, in the form of source code under the
@ -260,7 +262,7 @@ beyond what the individual works permit. Inclusion of a covered work
in an aggregate does not cause this License to apply to the other
parts of the aggregate.
\subsubsection*{6. Conveying Non-Source Forms.}
\medskip\para{\normalsize 6. Conveying Non-Source Forms.}
You may convey a covered work in object code form under the terms
of sections 4 and 5, provided that you also convey the
@ -359,10 +361,10 @@ documented (and with an implementation available to the public in
source code form), and must require no special password or key for
unpacking, reading or copying.
\subsubsection*{7. Additional Terms.}
\medskip\para{\normalsize 7. Additional Terms.}
``Additional permissions'' are terms that supplement the terms of this
License by making exceptions from one or more of its conditions.
``Additional permissions'' are terms that supplement the terms of
this License by making exceptions from one or more of its conditions.
Additional permissions that are applicable to the entire Program shall
be treated as though they were included in this License, to the extent
that they are valid under applicable law. If additional permissions
@ -423,7 +425,7 @@ where to find the applicable terms.
form of a separately written license, or stated as exceptions;
the above requirements apply either way.
\subsubsection*{8. Termination.}
\medskip\para{\normalsize 8. Termination.}
You may not propagate or modify a covered work except as expressly
provided under this License. Any attempt otherwise to propagate or
@ -451,7 +453,7 @@ this License. If your rights have been terminated and not permanently
reinstated, you do not qualify to receive new licenses for the same
material under section 10.
\subsubsection*{9. Acceptance Not Required for Having Copies.}
\medskip\para{\normalsize 9. Acceptance Not Required for Having Copies.}
You are not required to accept this License in order to receive or
run a copy of the Program. Ancillary propagation of a covered work
@ -462,7 +464,7 @@ modify any covered work. These actions infringe copyright if you do
not accept this License. Therefore, by modifying or propagating a
covered work, you indicate your acceptance of this License to do so.
\subsubsection*{10. Automatic Licensing of Downstream Recipients.}
\medskip\para{\normalsize 10. Automatic Licensing of Downstream Recipients.}
Each time you convey a covered work, the recipient automatically
receives a license from the original licensors, to run, modify and
@ -487,7 +489,7 @@ rights granted under this License, and you may not initiate litigation
any patent claim is infringed by making, using, selling, offering for
sale, or importing the Program or any portion of it.
\subsubsection*{11. Patents.}
\medskip\para{\normalsize 11. Patents.}
A ``contributor'' is a copyright holder who authorizes use under this
License of the Program or a work on which the Program is based. The
@ -556,7 +558,7 @@ or that patent license was granted, prior to 28 March 2007.
any implied license or other defenses to infringement that may
otherwise be available to you under applicable patent law.
\subsubsection*{12. No Surrender of Others' Freedom.}
\medskip\para{\normalsize 12. No Surrender of Others' Freedom.}
If conditions are imposed on you (whether by court order, agreement or
otherwise) that contradict the conditions of this License, they do not
@ -569,7 +571,8 @@ whom you convey the Program, the only way you could satisfy both those
terms and this License would be to refrain entirely from conveying the
Program.
\subsubsection*{13. Use with the GNU Affero General Public License.}
\medskip\para{\normalsize 13. Use with the GNU Affero General Public
License.}
Notwithstanding any other provision of this License, you have
permission to link or combine any covered work with a work licensed
@ -580,7 +583,7 @@ but the special requirements of the GNU Affero General Public License,
section 13, concerning interaction through a network will apply to the
combination as such.
\subsubsection*{14. Revised Versions of this License.}
\medskip\para{\normalsize 14. Revised Versions of this License.}
The Free Software Foundation may publish revised and/or new versions
of the GNU General Public License from time to time. Such new versions
@ -606,7 +609,7 @@ permissions. However, no additional obligations are imposed on any
author or copyright holder as a result of your choosing to follow a
later version.
\subsubsection*{15. Disclaimer of Warranty.}
\medskip\para{\normalsize 15. Disclaimer of Warranty.}
THERE IS NO WARRANTY FOR THE PROGRAM, TO THE EXTENT PERMITTED BY
APPLICABLE LAW. EXCEPT WHEN OTHERWISE STATED IN WRITING THE COPYRIGHT
@ -617,7 +620,7 @@ PARTICULAR PURPOSE. THE ENTIRE RISK AS TO THE QUALITY AND PERFORMANCE
OF THE PROGRAM IS WITH YOU. SHOULD THE PROGRAM PROVE DEFECTIVE, YOU
ASSUME THE COST OF ALL NECESSARY SERVICING, REPAIR OR CORRECTION.
\subsubsection*{16. Limitation of Liability.}
\medskip\para{\normalsize 16. Limitation of Liability.}
IN NO EVENT UNLESS REQUIRED BY APPLICABLE LAW OR AGREED TO IN WRITING
WILL ANY COPYRIGHT HOLDER, OR ANY OTHER PARTY WHO MODIFIES AND/OR
@ -629,7 +632,7 @@ SUSTAINED BY YOU OR THIRD PARTIES OR A FAILURE OF THE PROGRAM TO OPERATE
WITH ANY OTHER PROGRAMS), EVEN IF SUCH HOLDER OR OTHER PARTY HAS BEEN
ADVISED OF THE POSSIBILITY OF SUCH DAMAGES.
\subsubsection*{17. Interpretation of Sections 15 and 16.}
\medskip\para{\normalsize 17. Interpretation of Sections 15 and 16.}
If the disclaimer of warranty and limitation of liability provided
above cannot be given local legal effect according to their terms,
@ -638,11 +641,11 @@ an absolute waiver of all civil liability in connection with the
Program, unless a warranty or assumption of liability accompanies a
copy of the Program in return for a fee.
\section*{END OF TERMS AND CONDITIONS}
\medskip\para{\normalsize END OF TERMS AND CONDITIONS}
\newpage
\section*{How to Apply These Terms to Your New Programs}
\medskip\para{\normalsize How to Apply These Terms to Your New Programs}
If you develop a new program, and you want it to be of the greatest
possible use to the public, the best way to achieve this is to make it

BIN
resources/3rdparty/glpk-4.57/doc/gmpl.pdf → resources/3rdparty/glpk-4.65/doc/gmpl.pdf

22
resources/3rdparty/glpk-4.57/doc/gmpl.tex → resources/3rdparty/glpk-4.65/doc/gmpl.tex

@ -4,9 +4,9 @@
% This code is part of GLPK (GNU Linear Programming Kit).
%
% Copyright (C) 2000, 2001, 2002, 2003, 2004, 2005, 2006, 2007, 2008,
% 2009, 2010, 2011, 2013, 2014, 2015 Andrew Makhorin, Department for
% Applied Informatics, Moscow Aviation Institute, Moscow, Russia. All
% rights reserved. E-mail: <mao@gnu.org>.
% 2009, 2010, 2011, 2013, 2014, 2015, 2016 Andrew Makhorin, Department
% for Applied Informatics, Moscow Aviation Institute, Moscow, Russia.
% All rights reserved. E-mail: <mao@gnu.org>.
%
% GLPK is free software: you can redistribute it and/or modify it
% under the terms of the GNU General Public License as published by
@ -22,6 +22,11 @@
% along with GLPK. If not, see <http://www.gnu.org/licenses/>.
%***********************************************************************
% To produce gmpl.pdf from gmpl.tex run the following two commands:
% latex gmpl.tex
% dvipdfm -p letter gmpl.dvi
% Note: You need TeX Live 2010 or later version.
\documentclass[11pt]{report}
\usepackage{amssymb}
\usepackage[dvipdfm,linktocpage,colorlinks,linkcolor=blue,
@ -71,12 +76,12 @@ urlcolor=blue]{hyperref}
\vspace{0.5in}
\begin{LARGE}
\sf for GLPK Version 4.57
\sf for GLPK Version 4.58
\end{LARGE}
\vspace{0.5in}
\begin{Large}
\sf (DRAFT, October 2015)
\sf (DRAFT, February 2016)
\end{Large}
\end{center}
@ -93,9 +98,9 @@ GNU.
\noindent
Copyright \copyright{} 2000, 2001, 2002, 2003, 2004, 2005, 2006, 2007,
2008, 2009, 2010, 2011, 2013, 2014, 2015 Andrew Makhorin, Department
for Applied Informatics, Moscow Aviation Institute, Moscow, Russia. All
rights reserved.
2008, 2009, 2010, 2011, 2013, 2014, 2015, 2016 Andrew Makhorin,
Department for Applied Informatics, Moscow Aviation Institute, Moscow,
Russia. All rights reserved.
\noindent
Free Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston,
@ -614,6 +619,7 @@ digits\\
{\tt str2time(}$s${\tt,} $f${\tt)}&converting character string $s$ to
calendar time (for details see Section \ref{str2time}, page
\pageref{str2time})\\
{\tt tan(}$x${\tt)}&$\tan x$, tangent of $x$ (in radians)\\
{\tt trunc(}$x${\tt)}&truncating $x$ to nearest integer\\
{\tt trunc(}$x${\tt,} $n${\tt)}&truncating $x$ to $n$ fractional
decimal digits\\

BIN
resources/3rdparty/glpk-4.65/doc/gmpl_es.pdf

22
resources/3rdparty/glpk-4.57/doc/gmpl_es.tex → resources/3rdparty/glpk-4.65/doc/gmpl_es.tex

@ -4,9 +4,9 @@
% This code is part of GLPK (GNU Linear Programming Kit).
%
% Copyright (C) 2000, 2001, 2002, 2003, 2004, 2005, 2006, 2007, 2008,
% 2009, 2010, 2011, 2013 Andrew Makhorin, Department for Applied
% Informatics, Moscow Aviation Institute, Moscow, Russia. All rights
% reserved. E-mail: <mao@gnu.org>.
% 2009, 2010, 2011, 2013, 2014, 2015 Andrew Makhorin, Department for
% Applied Informatics, Moscow Aviation Institute, Moscow, Russia. All
% rights reserved. E-mail: <mao@gnu.org>.
%
% GLPK is free software: you can redistribute it and/or modify it
% under the terms of the GNU General Public License as published by
@ -25,6 +25,7 @@
\documentclass[11pt,spanish]{report}
\usepackage[utf8]{inputenc}
\usepackage[T1]{fontenc}
\usepackage{lmodern}
\usepackage{amssymb}
\usepackage[dvipdfm,linktocpage,colorlinks,linkcolor=blue,
urlcolor=blue]{hyperref}
@ -73,12 +74,12 @@ urlcolor=blue]{hyperref}
\vspace{0.5in}
\begin{LARGE}
\sf para GLPK Versión 4.50
\sf para GLPK Versión 4.57
\end{LARGE}
\vspace{0.5in}
\begin{Large}
\sf (BORRADOR, Mayo del 2013)
\sf (BORRADOR, octubre del 2015)
\end{Large}
\end{center}
@ -93,10 +94,7 @@ urlcolor=blue]{hyperref}
El paquete GLPK es parte del Proyecto GNU distribuido bajo la égida de GNU
\noindent
Copyright \copyright{} 2000, 2001, 2002, 2003, 2004, 2005, 2006, 2007,
2008, 2009, 2010, 2011, 2013 Andrew Makhorin, Department for Applied
Informatics, Moscow Aviation Institute, Moscow, Russia. Todos los derechos
reservados.
Copyright \copyright{} 2000, 2001, 2002, 2003, 2004, 2005, 2006, 2007, 2008, 2009, 2010, 2011, 2013, 2014, 2015 Andrew Makhorin, Department for Applied Informatics, Moscow Aviation Institute, Moscow, Russia. Todos los derechos reservados.
\noindent
Título original en inglés: Modeling Language GNU MathProg - Language Reference for GLPK Version 4.50
@ -105,7 +103,7 @@ Título original en inglés: Modeling Language GNU MathProg - Language Reference
Traducción: Pablo Yapura, Facultad de Ciencias Agrarias y Forestales, Universidad Nacional de La Plata, La Plata, Argentina.
\noindent
Copyright \copyright{} 2013 Pablo Yapura, para esta traducción. Todos los derechos reservados.
Copyright \copyright{} 2013, 2014, 2015 Pablo Yapura, para esta traducción. Todos los derechos reservados.
\noindent
Free Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston,
@ -1534,7 +1532,7 @@ El atributo de valor fijo ({\tt=}) especifica una expresión numérica para calc
s.t. r: x + y + z, >= 0, <= 1;
limite{t in 1..T}: sum{j in producto} elaborar[j,t] <= max_producto;
subject to balance{i in insumo, t in 1..T}:
almacenar[i,t+1] - almacenar[i,t] -
almacenar[i,t+1] = almacenar[i,t] -
sum{j in producto} unidades[i,j] * elaborar[j,t];
subject to ltn 'limite tiempo normal' {t in tiempo}:
sum{p in producto} pt[p] * rprd[p,t] <= 1.3 * dpp[t] * brigadas[t];
@ -3075,7 +3073,7 @@ Abajo hay un ejemplo completo de la descripción de un modelo escrito en el leng
\begin{verbatim}
# UN PROBLEMA DE TRANSPORTE
#
# Este problema encuentra la logística de costo mínimo de flete
# Este problema determina la logística de costo mínimo de flete
# que cumple los requerimientos en los mercados y en las fábricas
# de suministro.
#

BIN
resources/3rdparty/glpk-4.65/doc/gmpl_pt-BR.pdf

7893
resources/3rdparty/glpk-4.65/doc/gmpl_pt-BR.tex
File diff suppressed because it is too large
View File

BIN
resources/3rdparty/glpk-4.65/doc/graphs.pdf

266
resources/3rdparty/glpk-4.57/doc/graphs.tex → resources/3rdparty/glpk-4.65/doc/graphs.tex

@ -4,7 +4,7 @@
% This code is part of GLPK (GNU Linear Programming Kit).
%
% Copyright (C) 2000, 2001, 2002, 2003, 2004, 2005, 2006, 2007, 2008,
% 2009, 2010, 2011, 2013 Andrew Makhorin, Department for Applied
% 2009, 2010, 2011, 2013, 2016 Andrew Makhorin, Department for Applied
% Informatics, Moscow Aviation Institute, Moscow, Russia. All rights
% reserved. E-mail: <mao@gnu.org>.
%
@ -22,32 +22,41 @@
% along with GLPK. If not, see <http://www.gnu.org/licenses/>.
%***********************************************************************
% To make graphs.pdf from graphs.tex run the following two commands:
% latex graphs.tex
% dvipdfm -p letter graphs.dvi
% Note: You need TeX Live 2010 or later version.
\documentclass[11pt]{report}
\usepackage{amssymb}
\usepackage[dvipdfm,linktocpage,colorlinks,linkcolor=blue,
urlcolor=blue]{hyperref}
\usepackage{indentfirst}
\usepackage{niceframe}
\usepackage[all]{xy}
% US Letter = 8.5 x 11 in
\setlength{\textwidth}{6.5in}
\setlength{\textheight}{8.5in}
\setlength{\textheight}{9in}
\setlength{\oddsidemargin}{0in}
\setlength{\topmargin}{0in}
\setlength{\headheight}{0in}
\setlength{\headsep}{0in}
\setlength{\footskip}{0.5in}
%\setlength{\footskip}{0.5in}
\setlength{\parindent}{16pt}
\setlength{\parskip}{5pt}
\setlength{\topsep}{0pt}
\setlength{\partopsep}{0pt}
\setlength{\itemsep}{\parskip}
\setlength{\parsep}{0pt}
\setlength{\leftmargini}{\parindent}
\renewcommand{\labelitemi}{---}
%\setlength{\itemsep}{\parskip}
%\setlength{\parsep}{0pt}
%\setlength{\leftmargini}{\parindent}
%\renewcommand{\labelitemi}{---}
\newcommand{\Item}[1]{\parbox[t]{\parindent}{#1}}
\def\para#1{\noindent{\bf#1}}
\def\synopsis{\para{Synopsis}}
\def\description{\para{Description}}
\def\note{\para{Note}}
\def\returns{\para{Returns}}
\renewcommand\contentsname{\sf\bfseries Contents}
@ -65,6 +74,8 @@ urlcolor=blue]{hyperref}
\thispagestyle{empty}
\curlyframe{
\begin{center}
\vspace*{1.5in}
@ -82,15 +93,18 @@ urlcolor=blue]{hyperref}
\vspace{0.5in}
\begin{LARGE}
\sf for GLPK Version 4.49
\sf for GLPK Version 4.59
\end{LARGE}
\vspace{0.5in}
\begin{Large}
\sf (DRAFT, April 2013)
\sf (DRAFT, March 2016)
\end{Large}
\end{center}
\vspace*{4.1in}
}
\newpage
\vspace*{1in}
@ -103,9 +117,9 @@ GNU.
\noindent
Copyright \copyright{} 2000, 2001, 2002, 2003, 2004, 2005, 2006, 2007,
2008, 2009, 2010, 2011, 2013 Andrew Makhorin, Department for Applied
Informatics, Moscow Aviation Institute, Moscow, Russia. All rights
reserved.
2008, 2009, 2010, 2011, 2013, 2016\linebreak
Andrew Makhorin, Department for Applied Informatics, Moscow Aviation
Institute, Moscow, Russia. All rights reserved.
\noindent
Free Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
@ -130,9 +144,7 @@ into another language, under the above conditions for modified versions.
\newpage
{\setlength{\parskip}{0pt}
\tableofcontents
}
{\setlength{\parskip}{0pt}\tableofcontents}
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
@ -152,17 +164,17 @@ vertex} of arc $a$, and $y\in V$ is called its {\it head vertex}.
Representation of a graph in the program includes three structs defined
by typedef in the header \verb|glpk.h|:
\vspace*{-8pt}
%\vspace*{-8pt}
\begin{itemize}
\item \verb|glp_graph|, which represents the graph in a whole,
%\begin{itemize}
\Item{---}\verb|glp_graph|, which represents the graph in a whole,
\item \verb|glp_vertex|, which represents a vertex of the graph, and
\Item{---}\verb|glp_vertex|, which represents a vertex of the graph, and
\item \verb|glp_arc|, which represents an arc of the graph.
\end{itemize}
\Item{---}\verb|glp_arc|, which represents an arc of the graph.
%\end{itemize}
\vspace*{-8pt}
%\vspace*{-8pt}
All these three structs are ``semi-opaque'', i.e. the application
program can directly access their fields through pointers, however,
@ -173,8 +185,11 @@ performed only with appropriate GLPK API routines.
{\addtolength{\leftskip}{16pt}\noindent}
{\par\addtolength{\leftskip}{-16pt}}
\para{\bf glp\_graph.} The struct \verb|glp_graph| has the following
fields available to the application program:
\subsection{Structure glp\_graph}
%\para{\bf glp\_graph.}
The struct \verb|glp_graph| has the following fields available to the
application program.
\noindent
\verb|char *name;|
@ -225,8 +240,11 @@ $0\leq v\_size\leq 256$. (See also the field \verb|data| in the struct
\verb|glp_arc|.)
\end{comment}
\para{\bf glp\_vertex.} The struct \verb|glp_vertex| has the following
fields available to the application program:
\subsection{Structure glp\_vertex}
%\para{\bf glp\_vertex.}
The struct \verb|glp_vertex| has the following fields available to the
application program.
\noindent
\verb|int i;|
@ -274,8 +292,11 @@ vertex has no incoming arcs, this field contains \verb|NULL|.
vertex has no outgoing arcs, this field contains \verb|NULL|.
\end{comment}
\para{\bf glp\_arc.} The struct \verb|glp_arc| has the following fields
available to the application program:
\subsection{Structure glp\_arc}
%\para{\bf glp\_arc.}
The struct \verb|glp_arc| has the following fields available to the
application program.
\noindent
\verb|glp_vertex *tail;|
@ -283,13 +304,15 @@ available to the application program:
\begin{comment}Pointer to a vertex, which is tail endpoint of the arc.
\end{comment}
\newpage
\noindent
\verb|glp_vertex *head;|
\begin{comment}Pointer to a vertex, which is head endpoint of the arc.
\end{comment}
\newpage
%\newpage
\noindent
\verb|void *data;|
@ -327,6 +350,8 @@ incoming arcs.
\newpage
\setlength{\parskip}{4.6pt}
\section{Graph creating and modifying routines}
\subsection{glp\_create\_graph --- create graph}
@ -398,6 +423,10 @@ Otherwise, if the block size is zero, the field \verb|data| is set to
The routine \verb|glp_add_vertices| returns the ordinal number of the
first new vertex added to the graph.
\setlength{\parskip}{5pt}
\newpage
\subsection{glp\_set\_vertex\_name --- assign (change) vertex name}
\synopsis
@ -456,7 +485,7 @@ vertices remaining in the graph. New ordinal numbers of the remaining
vertices are assigned under the assumption that the original order of
vertices is not changed.
\newpage
%\newpage
\subsection{glp\_del\_arc --- delete arc from graph}
@ -565,7 +594,7 @@ exist, the routine does nothing.
\section{Graph reading/writing routines}
\subsection{glp\_read\_graph --- read graph from plain text file}
\subsection{glp\_read\_graph --- read graph from text file}
\synopsis
@ -575,20 +604,22 @@ exist, the routine does nothing.
\description
The routine \verb|glp_read_graph| reads a graph from a plain text file,
whose name is specified by the parameter \verb|fname|. Note that before
reading data the current content of the graph object is completely
erased with the routine \verb|glp_erase_graph|.
The routine \verb|glp_read_graph| reads a graph from a text file, whose
name is specified by the parameter \verb|fname|. It is equivalent to
For the file format see description of the routine
\verb|glp_write_graph|.
\begin{verbatim}
glp_read_ccdata(G, -1, fname);
\end{verbatim}
Note that before reading data the current content of the graph object
is completely erased with the routine \verb|glp_erase_graph|.
\returns
If the operation was successful, the routine returns zero. Otherwise
it prints an error message and returns non-zero.
\subsection{glp\_write\_graph --- write graph to plain text file}
\subsection{glp\_write\_graph --- write graph to text file}
\synopsis
@ -598,34 +629,18 @@ it prints an error message and returns non-zero.
\description
The routine \verb|glp_write_graph| writes the graph to a plain text
file, whose name is specified by the parameter \verb|fname|.
\returns
If the operation was successful, the routine returns zero. Otherwise
it prints an error message and returns non-zero.
\para{File format}
The file created by the routine \verb|glp_write_graph| is a plain text
file, which contains the following information:
The routine \verb|glp_write_graph| writes the graph to a text file,
whose name is specified by the parameter \verb|fname|.
It is equivalent to
\begin{verbatim}
nv na
i[1] j[1]
i[2] j[2]
. . .
i[na] j[na]
glp_write_ccdata(G, -1, fname);
\end{verbatim}
\noindent
where: \verb|nv| is the number of vertices (nodes); \verb|na| is the
number of arcs; \verb|i[k]|, $k=1,\dots,na$, is the index of tail
vertex of arc $k$; \verb|j[k]|, $k=1,\dots,na$, is the index of head
vertex of arc $k$.
\returns
\newpage
If the operation was successful, the routine returns zero. Otherwise
it prints an error message and returns non-zero.
\subsection{glp\_read\_ccdata --- read graph from text file in DIMACS
clique/coloring\\format}
@ -646,6 +661,8 @@ directed graphs, because the routine allows reading self-loops and
multiple edges/arcs keeping the order of vertices specified for each
edge/arc of the graph.)
\newpage
The parameter {\tt G} specifies the graph object to be read in. Note
that before reading data the current content of the graph object is
completely erased with the routine {\tt glp\_erase\_graph}.
@ -666,7 +683,7 @@ it prints an error message and returns non-zero.
\para{DIMACS clique/coloring format\footnote{This material is
based on the paper ``Clique and Coloring Problems Graph Format'', which
is publically available at \url{http://dimacs.rutgers.edu/Challenges}.}}
is publicly available at \url{http://dimacs.rutgers.edu/Challenges}.}}
The DIMACS input file is a plain ASCII text file. It contains
{\it lines} of several types described below. A line is terminated with
@ -731,7 +748,9 @@ The lower-case character \verb|e| signifies that this is an edge
descriptor line. For an edge (arc) $(i,j)$ the fields \verb|I| and
\verb|J| specify its endpoints.
\para{Example.} The following example of an undirected graph:
\newpage
\para{Example.} The following undirected graph
\bigskip
@ -749,7 +768,7 @@ descriptor line. For an edge (arc) $(i,j)$ the fields \verb|I| and
\bigskip
\noindent
might be coded in DIMACS clique/coloring format as follows:
might be coded in DIMACS clique/coloring format as follows.
\begin{footnotesize}
\begin{verbatim}
@ -786,6 +805,8 @@ c eof
\end{verbatim}
\end{footnotesize}
\newpage
\subsection{glp\_write\_ccdata --- write graph to text file in DIMACS
clique/coloring\\format}
@ -1025,6 +1046,8 @@ int main(void)
\end{verbatim}
\end{footnotesize}
\newpage
\noindent
If the file `\verb|graph.txt|' contains the following graph:
@ -1255,7 +1278,7 @@ int main(void)
\para{DIMACS minimum cost flow problem format\footnote{This
material is based on the paper ``The First DIMACS International
Algorithm Implementation Challenge: Problem Definitions and
Specifications'', which is publically available at
Specifications'', which is publicly available at
\url{http://dimacs.rutgers.edu/Challenges}.}}
\label{subsecmincost}
@ -1278,7 +1301,7 @@ character \verb|c|.
c This is a comment line
\end{verbatim}
\newpage
%\newpage
\para{Problem line.} There is one problem line per data file. The
problem line must appear before any node or arc descriptor lines. It
@ -1288,6 +1311,8 @@ has the following format:
p min NODES ARCS
\end{verbatim}
\newpage
\noindent
The lower-case character \verb|p| signifies that this is a problem line.
The three-character problem designator \verb|min| identifies the file as
@ -1366,6 +1391,8 @@ c eof
\end{verbatim}
\end{footnotesize}
\newpage
\subsection{glp\_write\_mincost --- write minimum cost flow problem
data in DIMACS\\format}
@ -1416,7 +1443,7 @@ automatic compression on writing it.)
If the operation was successful, the routine returns zero. Otherwise,
it prints an error message and returns non-zero.
\newpage
%\newpage
\subsection{glp\_mincost\_lp --- convert minimum cost flow problem
to LP}
@ -1542,7 +1569,7 @@ End
\end{verbatim}
\end{footnotesize}
\newpage
%\newpage
\subsection{glp\_mincost\_okalg --- solve minimum cost flow problem
with out-of-kilter\\algorithm}
@ -1585,6 +1612,8 @@ bound to the arc flow (the arc capacity). This bound must be integer in
the range [$l_{ij}$, \verb|INT_MAX|]. If \verb|a_cap| $<0$, it is
assumed that $u_{ij}=1$ for all arcs.
\newpage
The parameter \verb|a_cost| specifies an offset of the field of type
\verb|double| in the arc data block, which contains $c_{ij}$, the
per-unit cost of the arc flow. This value must be integer in the range
@ -1611,7 +1640,7 @@ bound constraints (see (3) ibid.), using the following formula:
$$\lambda_{ij}=c_{ij}-(\pi_i-\pi_j),$$
where $c_{ij}$ is the per-unit cost for arc $(i,j)$.
\newpage
%\newpage
Note that all solution components (the objective value, arc flows, and
node potentials) computed by the routine are always integer-valued.
@ -1661,6 +1690,8 @@ flow $x_{ts}$ through which is also costless ($c_{ts}=0$) and fixed to
$F$ ($l_{ts}=u_{ts}=F$), where $\displaystyle F=\sum_{b_i>0}b_i$ is the
total supply.
\newpage
\para{Example}
The example program below reads the minimum cost problem instance in
@ -1797,7 +1828,10 @@ per-unit cost of the arc flow. This value must be integer in the range
[$-$\verb|INT_MAX|/4, $+$\verb|INT_MAX|/4]. If \verb|a_cost| $<0$, it
is assumed that $c_{ij}=0$ for all arcs.
The parameter \verb|crash| is option specifying initialization method:
\newpage
The parameter \verb|crash| is an option that specifies initialization
method:
0 --- default initialization is used;
@ -1813,8 +1847,6 @@ The parameter \verb|sol| specifies a location, to which the routine
stores the objective value (that is, the total cost) found. If
\verb|sol| is NULL, the objective value is not stored.
\newpage
The parameter \verb|a_x| specifies an offset of the field of type
\verb|double| in the arc data block, to which the routine stores
$x_{ij}$, the arc flow found. If \verb|a_x| $<0$, the arc flow value is
@ -1940,6 +1972,8 @@ The parameter \verb|G| specifies the graph object, to which the
generated problem data have to be stored. Note that on entry the graph
object is erased with the routine \verb|glp_erase_graph|.
\newpage
The parameter \verb|v_rhs| specifies an offset of the field of type
\verb|double| in the vertex data block, to which the routine stores the
supply or demand value. If \verb|v_rhs| $<0$, the value is not stored.
@ -1948,8 +1982,6 @@ The parameter \verb|a_cap| specifies an offset of the field of type
\verb|double| in the arc data block, to which the routine stores the
arc capacity. If \verb|a_cap| $<0$, the capacity is not stored.
\newpage
The parameter \verb|a_cost| specifies an offset of the field of type
\verb|double| in the arc data block, to which the routine stores the
per-unit cost if the arc flow. If \verb|a_cost| $<0$, the cost is not
@ -2002,6 +2034,8 @@ connected, the routine generates a few remaining arcs to ensure
connectedness. Thus, the actual number of arcs generated by the routine
may be greater than the requested number of arcs.
\newpage
\subsection{glp\_netgen\_prob --- Klingman's standard network problem
instance}
@ -2090,6 +2124,8 @@ $$
\end{array}
$$
\newpage
\subsection{glp\_gridgen --- grid-like network problem generator}
\synopsis
@ -2104,14 +2140,12 @@ $$
The routine \verb|glp_gridgen| is a GLPK version of the grid-like
network problem generator developed by Yusin Lee and Jim
Orlin.\footnote{Y.~Lee and J.~Orlin. GRIDGEN generator., 1991. The
original code is publically available from
original code is publicly available from
\url{ftp://dimacs.rutgers.edu/pub/netflow/generators/network/gridgen}.}
\newpage
The parameter \verb|G| specifies the graph object, to which the
generated problem data have to be stored. Note that on entry the graph
object is erased with the routine \verb|glp_erase_graph|.
generated problem data have to be stored. Note that on entry the graph
object is erased with the routine \verb|glp_erase_graph|.
The parameter \verb|v_rhs| specifies an offset of the field of type
\verb|double| in the vertex data block, to which the routine stores the
@ -2162,6 +2196,8 @@ If the instance was successfully generated, the routine
\verb|glp_gridgen| returns zero; otherwise, if specified parameters are
inconsistent, the routine returns a non-zero error code.
\newpage
\para{Comments\footnote{This material is based on comments
to the original version of GRIDGEN.}}
@ -2290,6 +2326,8 @@ $$
$$0\leq x_{ij}\leq u_{ij}\ \ \ \hbox{for all}\ (i,j)\in A
\eqno(9)$$
\newpage
\subsection{glp\_read\_maxflow --- read maximum flow problem data in
DIMACS\\format}
@ -2361,7 +2399,7 @@ int main(void)
\para{DIMACS maximum flow problem format\footnote{This material is
based on the paper ``The First DIMACS International Algorithm
Implementation Challenge: Problem Definitions and Specifications'',
which is publically available at
which is publicly available at
\url{http://dimacs.rutgers.edu/Challenges/}.}}
\label{subsecmaxflow}
@ -2637,10 +2675,10 @@ specifies the maximum flow problem instance to be solved.
The parameter $s$ specifies the ordinal number of the source node.
\newpage
The parameter $t$ specifies the ordinal number of the sink node.
\newpage
The parameter \verb|a_cap| specifies an offset of the field of type
\verb|double| in the arc data block, which contains $u_{ij}$, the upper
bound to the arc flow (the arc capacity). This bound must be integer in
@ -2768,23 +2806,23 @@ pp.~83-123.}$^{,}$\footnote{U.~Derigs and W.~Meier, ``Implementing
Goldberg's max-flow algorithm: A computational investigation.''
Zeitschrift f\"ur Operations Research 33 (1989),
pp.~383-403.}$^{,}$\footnote{The original code of RMFGEN implemented by
Tamas Badics is publically available from
Tamas Badics is publicly available from
\url{ftp://dimacs.rutgers.edu/pub/netflow/generators/network/genrmf}.}
The parameter \verb|G| specifies the graph object, to which the
generated problem data have to be stored. Note that on entry the graph
object is erased with the routine \verb|glp_erase_graph|.
\newpage
The pointers \verb|s| and \verb|t| specify locations, to which the
routine stores the source and sink node numbers, respectively. If
\verb|s| or \verb|t| is \verb|NULL|, corresponding node number is not
stored.
The parameter \verb|a_cap| specifies an offset of the field of type
\verb|double| in the arc data block, to which the routine stores the arc
capacity. If \verb|a_cap| $<0$, the capacity is not stored.
\verb|double| in the arc data block, to which the routine stores the
arc capacity. If \verb|a_cap| $<0$, the capacity is not stored.
\newpage
The array \verb|parm| contains description of the network to be
generated:
@ -2936,6 +2974,10 @@ directed graph $\overline{G}=(V,A)$, where $V=R\cup S$ and
$A=\{(i,j):(i,j)\in E\}$, i.e. every edge $(i,j)\in E$ in $G$
corresponds to arc $(i\rightarrow j)\in A$ in $\overline{G}$.
\newpage
\setlength{\parskip}{4.4pt}
\subsection{glp\_read\_asnprob --- read assignment problem data in
DIMACS format}
@ -3012,10 +3054,14 @@ int main(void)
\end{verbatim}
\end{footnotesize}
\setlength{\parskip}{5pt}
\newpage
\para{DIMACS assignment problem format\footnote{This material is based
on the paper ``The First DIMACS International Algorithm Implementation
Challenge: Problem Definitions and Specifications'', which is
publically available at \url{http://dimacs.rutgers.edu/Challenges/}.}}
publicly available at \url{http://dimacs.rutgers.edu/Challenges/}.}}
\label{subsecasnprob}
The DIMACS input file is a plain ASCII text file. It contains
@ -3132,8 +3178,6 @@ c eof
\end{verbatim}
\end{footnotesize}
\newpage
\subsection{glp\_write\_asnprob --- write assignment problem data in
DIMACS format}
@ -3168,6 +3212,8 @@ The parameter \verb|a_cost| specifies an offset of the field of type
cost. If \verb|a_cost| $<0$, it is assumed that $c_{ij}=1$ for all
edges.
\newpage
The character string \verb|fname| specifies a name of the text file to
be written out. (If the file name ends with suffix `\verb|.gz|', the
file is assumed to be compressed, in which case the routine performs
@ -3240,6 +3286,8 @@ or more outgoing arcs;
The routine \verb|glp_asnprob_lp| builds LP problem, which corresponds
to the specified assignment problem.
\newpage
The parameter \verb|P| is the resultant LP problem object to be built.
Note that on entry its current content is erased with the routine
\verb|glp_erase_prob|.
@ -3277,8 +3325,6 @@ The parameter \verb|a_cost| specifies an offset of the field of type
cost. If \verb|a_cost| $<0$, it is assumed that $c_{ij}=1$ for all
edges.
\newpage
\returns
If the LP problem has been successfully built, the routine
@ -3317,6 +3363,8 @@ int main(void)
\end{verbatim}
\end{footnotesize}
\newpage
If `\verb|sample.asn|' is the example data file from the subsection
describing \verb|glp_read_asnprob|, file `\verb|matching.lp|' may look
like follows:
@ -3378,6 +3426,8 @@ End
\end{verbatim}
\end{footnotesize}
\newpage
\subsection{glp\_asnprob\_okalg --- solve assignment problem with
out-of-kilter\\algorithm}
@ -3406,8 +3456,6 @@ The parameter \verb|form| defines which LP formulation should be used:
\verb|GLP_ASN_MMP| --- maximum weighted matching (11)---(14).
\newpage
The parameter \verb|G| is the graph program object, which specifies the
assignment problem instance.
@ -3456,6 +3504,8 @@ integer overflow.\\
\verb|<bug-glpk@gnu.org>|.)\\
\end{retlist}
\newpage
\para{Comments}
Since the out-of-kilter algorithm is designed to find a minimal cost
@ -3479,8 +3529,6 @@ arc $(k\rightarrow i)$, flow $x_{ki}$ through which is costless
unity upper bound ($l_{ij}=0$, $u_{ij}=1$, in case of
\verb|GLP_ASN_MMP|);
\newpage
4) similarly, for each original node $j\in S$ the routine adds
auxiliary demand arc $(j\rightarrow k)$, flow $x_{jk}$ through which is
costless ($c_{jk}=0$) and either fixed at 1 ($l_{jk}=u_{jk}=1$, in case
@ -3597,6 +3645,8 @@ indicator:
1 --- the node is in set $S$.
\newpage
\noindent
If \verb|v_set| $<0$, it is assumed that a node having no incoming arcs
is in set $R$, and a node having no outgoing arcs is in set $S$.
@ -3612,8 +3662,6 @@ matching found. However, if the specified graph is incorrect (as
detected by the routine \verb|glp_check_asnprob|), this routine returns
a negative value.
\newpage
\para{Comments}
The same solution may be obtained with the routine
@ -3668,6 +3716,8 @@ int main(void)
If `\verb|sample.asn|' is the example data file from the subsection
describing \verb|glp_read_asnprob|, the output may look like follows:
\newpage
\begin{footnotesize}
\begin{verbatim}
Reading assignment problem data from `sample.asn'...
@ -3757,12 +3807,6 @@ That representation, however, is much less convenient than the one,
where jobs are represented as nodes of the network.} The project network
for the example above is shown on Fig.~4.
May note that the project network must be acyclic; otherwise, it would
be impossible to satisfy to the precedence relation for any job that
belongs to a cycle.
\newpage
\hspace*{.5in}
\xymatrix
{&&&C|3\ar[rd]&&I|5\ar[r]&K|4\ar[rd]&\\
@ -3776,7 +3820,11 @@ A|3\ar[r]&B|4\ar[rru]\ar[rd]&&E|8\ar[r]&H|8\ar[ru]\ar[rd]&&&M|4\\
\noindent\hfil
Fig.~4. An example of the project network.
\medskip
\newpage
May note that the project network must be acyclic; otherwise, it would
be impossible to satisfy to the precedence relation for any job that
belongs to a cycle.
The critical path problem can be naturally formulated as the following
LP problem:
@ -3824,8 +3872,6 @@ The parameter \verb|v_es| specifies an offset of the field of type
the {\it earliest start time} for corresponding job. If \verb|v_es|
$<0$, this time is not stored.
\newpage
The parameter \verb|v_ls| specifies an offset of the field of type
\verb|double| in the vertex data block, to which the routine stores
the {\it latest start time} for corresponding job. If \verb|v_ls|
@ -3841,6 +3887,8 @@ zero, the corresponding job is critical.
The routine \verb|glp_cpp| returns the minimal project duration, i.e.
minimal time needed to perform all jobs in the project.
\newpage
\para{Example}
The example program below solves the critical path problem shown on
@ -3943,6 +3991,10 @@ Job Time ES EF LS LF
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
\end{document}
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
\chapter{Graph Optimization API Routines}
\section{Maximum clique problem}

0
resources/3rdparty/glpk-4.57/doc/miplib2.txt → resources/3rdparty/glpk-4.65/doc/miplib2.txt

0
resources/3rdparty/glpk-4.57/doc/miplib3.txt → resources/3rdparty/glpk-4.65/doc/miplib3.txt

0
resources/3rdparty/glpk-4.57/doc/netlib.txt → resources/3rdparty/glpk-4.65/doc/netlib.txt

0
resources/3rdparty/glpk-4.57/doc/notes/gomory.pdf → resources/3rdparty/glpk-4.65/doc/notes/gomory.pdf

0
resources/3rdparty/glpk-4.57/doc/notes/keller.pdf → resources/3rdparty/glpk-4.65/doc/notes/keller.pdf

0
resources/3rdparty/glpk-4.57/doc/notes/scf.pdf → resources/3rdparty/glpk-4.65/doc/notes/scf.pdf

BIN
resources/3rdparty/glpk-4.65/doc/notes/simplex1.pdf

BIN
resources/3rdparty/glpk-4.65/doc/notes/simplex2.pdf

283
resources/3rdparty/glpk-4.65/doc/npp.txt

@ -0,0 +1,283 @@
@.@ LP/MIP PREPROCESSING ROUTINES
=================================
@.@.1 Introduction
GLPK has a set of routines that constitute so called the LP/MIP
preprocessor. Its main purpose is to improve a given formulation of the
LP or MIP problem instance provided by the user.
As a rule the LP/MIP preprocessor is used internally (if enabled) in
the LP or MIP solver. However, for various reasons the user may need
to call the preprocessing routines directly in his/her application
program, in which case he/she may use API routines described in this
section.
The preprocessing of an LP/MIP problem instance and recovering its
solution include several steps, which are performed in the following
order.
1. Allocating the workspace. The preprocessor allocates the workspace,
an internal data structure used on all subsequent steps.
2. Loading the original problem instance. The preprocessor copies all
the problem components from the original problem object (glp_prob)
specified by the user into the workspace. On this step the user also
should specify the solution type: basic solution (assumes the
primal or dual simplex solver), interior-point solution (assumes the
interior-point solver), or MIP solution (assumes the MIP solver).
This is needed, because some preprocessing transformations depend on
the solution type.
3. Preprocessing. The user calls preprocessing routines that transform
the problem instance residing in the workspace.
4. Building the resultant problem instance. The preprocessor converts
the problem instance from an internal workspace representation
to the standard problem object (glp_prob) and returns that object to
the user.
5. Solving the resultant problem instance. The user calls an
appropriate solver routine to obtain a solution to the resultant
problem instance.
6. Postprocessing. The user provides the solution to the resultant
problem instance found on the previous step, and the preprocessor
performs inverse transformations to recover the solution to the
original problem instance. Should note that only optimal or integer
feasible (for MIP) solutions can be recovered.
7. Obtaining original solution. The preprocessor copies the solution
to the original problem instance recovered on the previous step from
the workspace to the original problem object (glp_prob). The effect
is the same as if the solution were computed by a solver. Note that
steps 6 and 7 can be performed multiple times (for example, to
recover intermediate integer feasible solutions during the integer
optimization).
8. Freeing the workspace. The preprocessor frees all the memory
allocated to the workspace.
EXAMPLE
In this example the program reads the LP problem data from input file
murtagh.mps\footnote{This is an example model included in the GLPK
distribution.}, performs standard preprocessing, solves the resultant
LP with the primal simplex method, and then recovers the solution to
the original LP.
/* nppsamp.c */
#include <stdio.h>
#include <stdlib.h>
#include <glpk.h>
int main(void)
{ glp_prep *npp;
glp_prob *P, *Q;
int ret;
npp = glp_npp_alloc_wksp();
P = glp_create_prob();
ret = glp_read_mps(P, GLP_MPS_DECK, NULL, "murtagh.mps");
if (ret != 0)
{ printf("Error on reading problem data\n");
goto skip;
}
glp_set_obj_dir(P, GLP_MAX);
glp_npp_load_prob(npp, P, GLP_SOL, GLP_ON);
ret = glp_npp_preprocess1(npp, 0);
switch (ret)
{ case 0:
break;
case GLP_ENOPFS:
printf("LP has no primal feasible solution\n");
goto skip;
case GLP_ENODFS:
printf("LP has no dual feasible solution\n");
goto skip;
default:
xassert(ret != ret);
}
Q = glp_create_prob();
glp_npp_build_prob(npp, Q);
ret = glp_simplex(Q, NULL);
if (ret == 0 && glp_get_status(Q) == GLP_OPT)
{ glp_npp_postprocess(npp, Q);
glp_npp_obtain_sol(npp, P);
}
else
printf("Unable to recover non-optimal solution\n");
glp_delete_prob(Q);
skip: glp_npp_free_wksp(npp);
glp_delete_prob(P);
return 0;
}
/* eof */
------------------------------------------------------------------------
@.@.2 glp_npp_alloc_wksp - allocate the preprocessor workspace
SYNOPSIS
glp_prep *glp_npp_alloc_wksp(void);
DESCRIPTION
The routine glp_npp_alloc_wksp allocates the preprocessor workspace.
(Note that multiple instances of the workspace may be allocated, if
necessary.)
RETURNS
The routine returns a pointer to the workspace, which should be used in
all subsequent operations.
------------------------------------------------------------------------
@.@.3 glp_npp_load_prob - load original problem instance
SYNOPSIS
void glp_npp_load_prob(glp_prep *prep, glp_prob *P, int sol,
int names);
DESCRIPTION
The routine glp_npp_load_prob loads the original problem instance from
the specified problem object P into the preprocessor workspace. (Note
that this operation can be performed only once.)
The parameter sol specifies which solution is required:
GLP_SOL - basic solution;
GLP_IPT - interior-point solution;
GLP_MIP - mixed integer solution.
The parameter names is a flag. If it is GLP_ON, the symbolic names of
original rows and columns are also loaded into the workspace. Otherwise,
if the flag is GLP_OFF, the row and column names are not loaded.
------------------------------------------------------------------------
@.@.4 glp_npp_preprocess1 - perform basic LP/MIP preprocessing
SYNOPSIS
int glp_npp_preprocess1(glp_prep *prep, int hard);
DESCRIPTION
The routine glp_npp_preprocess1 performs basic LP/MIP preprocessing
that currently includes:
-- removing free rows;
-- replacing double-sided constraint rows with almost identical bounds,
by equality constraint rows;
-- removing fixed columns;
-- replacing double-bounded columns with almost identical bounds by
fixed columns and removing those columns;
-- removing empty rows;
-- removing equality constraint row singletons and corresponding
columns;
-- removing inequality constraint row singletons and corresponding
columns;
-- performing general row analysis;
-- removing redundant row bounds;
-- removing forcing rows and corresponding columns;
-- removing rows which become free due to redundant bounds;
-- computing implied bounds for all columns and using them to
strengthen current column bounds (MIP only, optional, performed if
the flag hard is on);
-- fixing and removing empty columns;
-- removing column singletons, which are implied slack variables, and
corresponding rows;
-- removing bounds of columns, which are implied free variables, and
replacing corresponding rows by equality constraints.
If the flag hard is GLP_ON, the routine attempts to improve current
column bounds multiple times within the main processing loop, in which
case this feature may take a time. Otherwise, if the flag hard is
GLP_OFF, improving column bounds is performed only once at the end of
the main loop. (Note that this feature is used for MIP only.)
RETURNS
0 - the problem instance has been successfully preprocessed;
GLP_ENOPFS - primal/integer infeasibility has been detected;
GLP_ENODFS - dual infeasibility has been detected.
------------------------------------------------------------------------
@.@.5 glp_npp_build_prob - build resultant problem instance
SYNOPSIS
void glp_npp_build_prob(glp_prep *prep, glp_prob *Q);
DESCRIPTION
The routine glp_npp_build_prob obtains all necessary information from
the preprocessor workspace to build the resultant (preprocessed)
problem instance, and stores it in the specified problem object Q. Note
that before building the current content of this problem object is
erased with the routine glp_erase_prob.
------------------------------------------------------------------------
@.@.6 glp_npp_postprocess - postprocess solution to resultant problem
SYNOPSIS
void glp_npp_postprocess(glp_prep *prep, glp_prob *Q);
DESCRIPTION
The routine glp_npp_postprocess performs postprocessing of a solution
to the resultant (preprocessed) problem instance specified by the
problem object Q and recovers corrseponding solution to the original
problem instance. The recovered solution is stored in the preprocessor
workspace and can be obtained with the routine glp_npp_obtain_sol.
It is assumed that the resultant problem instance Q has been solved
with an appropriate solver depending on the solution type previously
passed to the routine glp_npp_load_prob (the parameter sol). Note that
only optimal or integer feasible (for MIP) solution can be recovered,
so the calling program should use the routine glp_status to make sure
that this condition is met.
------------------------------------------------------------------------
@.@.7 glp_npp_obtain_sol - obtain solution to original problem
SYNOPSIS
void glp_npp_obtain_sol(glp_prep *prep, glp_prob *P);
DESCRIPTION
The routine glp_npp_obtain_sol copies the solution to the original
problem instance previously recovered by the routine
glp_npp_postorocess from the preprocessor workspace to the problem
object P. The effect is the same as if the solution were computed by an
appropriate solver.
------------------------------------------------------------------------
@.@.8 glp_npp_free_wksp - free the preprocessor workspace
SYNOPSIS
void glp_npp_free_wksp(glp_prep *prep);
DESCRIPTION
The routine glp_npp_free_wksp frees all the memory allocated to the
preprocessor workspace.
===EOF===

11
resources/3rdparty/glpk-4.57/examples/INDEX → resources/3rdparty/glpk-4.65/examples/INDEX

@ -17,11 +17,13 @@ food.mod Food manufacture model
food2.mod Food manufacture model
furnace.mps Electric-arc furnace steelmaking
gap.mod Generalized assignment problem
graceful.mod Graceful Tree Labeling Problem
graph.mod Graph visualization
hashi.mod A solver for the Japanese number-puzzle Hashiwokakero
huge.mod Arithmetic mean of a large number of integers
icecream.mps Ice cream blending
jssp.mod Job-shop scheduling problem
life_goe.mod Conway's Game of Life garden of eden checker
magic.mod Magic square
maxcut.mod Maximum cut problem
maxflow.mod Maximum flow problem
@ -34,9 +36,13 @@ murtagh.mps Oil refinery model
mvcp.mod Minimum vertex cover problem
numbrix.mod Number placement puzzle
pbn/*.* Paint-by-numbers puzzle
pentomino.mod A geometric placement puzzle
plan.lp A simple LP problem (CPLEX LP format)
plan.mod A simple LP problem (MathProg format)
plan.mps A simple LP problem (MPS format)
planarity.mod Graph planarity testing
powpl25h.mod Power plant LP scheduler (25hrs for daylightsavings)
powplant.mod Power plant LP scheduler
prod.mod A multiperiod production model
qfit.mod Quadratic curve fitting solution
queens.mod A classic combinatorial optimization problem
@ -48,11 +54,16 @@ spp.mod Shortest path problem
stigler.mod Original Stigler's 1939 diet problem
sudoku.mod Number placement puzzle
tas.mod Tail assignment problem
tiling.mod Rectifiable polyomino tilings generator
todd.mod A class of hard instances of 0-1 knapsack problems
toto.mod Covering code generator, especially for football pool
systems
train.mod A model of railroad passenger car allocation
transp.mod A transportation problem
trick.mod A transportation design problem
tsp.mod Traveling salesman problem
wolfra6d.lp Neumann CA grid emulator generator
wolfra6d.mod Neumann CA grid emulator generator
xyacfs.mod Extended yet another curve fitting solution
yacfs.mod Yet another curve fitting solution
zebra.mod Who owns the zebra?

2
resources/3rdparty/glpk-4.57/examples/Makefile.am → resources/3rdparty/glpk-4.65/examples/Makefile.am

@ -10,6 +10,6 @@ glpsol_SOURCES = glpsol.c
check: glpsol$(EXEEXT)
./glpsol$(EXEEXT) --version
./glpsol$(EXEEXT) --mps $(srcdir)/plan.mps
./glpsol$(EXEEXT) --mps $(srcdir)/murtagh.mps --max
## eof ##

3
resources/3rdparty/glpk-4.57/examples/Makefile.in → resources/3rdparty/glpk-4.65/examples/Makefile.in

@ -137,6 +137,7 @@ MANIFEST_TOOL = @MANIFEST_TOOL@
MKDIR_P = @MKDIR_P@
NM = @NM@
NMEDIT = @NMEDIT@
NOUNDEFINED = @NOUNDEFINED@
OBJDUMP = @OBJDUMP@
OBJEXT = @OBJEXT@
OTOOL = @OTOOL@
@ -551,7 +552,7 @@ uninstall-am: uninstall-binPROGRAMS
check: glpsol$(EXEEXT)
./glpsol$(EXEEXT) --version
./glpsol$(EXEEXT) --mps $(srcdir)/plan.mps
./glpsol$(EXEEXT) --mps $(srcdir)/murtagh.mps --max
# Tell versions [3.59,3.63) of GNU make to not export all variables.
# Otherwise a system limit (for SysV at least) may be exceeded.

0
resources/3rdparty/glpk-4.57/examples/alloy.mps → resources/3rdparty/glpk-4.65/examples/alloy.mps

0
resources/3rdparty/glpk-4.57/examples/assign.mod → resources/3rdparty/glpk-4.65/examples/assign.mod

0
resources/3rdparty/glpk-4.57/examples/bpp.mod → resources/3rdparty/glpk-4.65/examples/bpp.mod

0
resources/3rdparty/glpk-4.57/examples/cal.mod → resources/3rdparty/glpk-4.65/examples/cal.mod

0
resources/3rdparty/glpk-4.57/examples/cf12a.mod → resources/3rdparty/glpk-4.65/examples/cf12a.mod

0
resources/3rdparty/glpk-4.57/examples/cf12b.mod → resources/3rdparty/glpk-4.65/examples/cf12b.mod

0
resources/3rdparty/glpk-4.57/examples/cflsq.mod → resources/3rdparty/glpk-4.65/examples/cflsq.mod

0
resources/3rdparty/glpk-4.57/examples/color.mod → resources/3rdparty/glpk-4.65/examples/color.mod

0
resources/3rdparty/glpk-4.57/examples/cplex/README → resources/3rdparty/glpk-4.65/examples/cplex/README

0
resources/3rdparty/glpk-4.57/examples/cplex/concorde.txt → resources/3rdparty/glpk-4.65/examples/cplex/concorde.txt

0
resources/3rdparty/glpk-4.57/examples/cplex/cplex.c → resources/3rdparty/glpk-4.65/examples/cplex/cplex.c

0
resources/3rdparty/glpk-4.57/examples/cplex/cplex.h → resources/3rdparty/glpk-4.65/examples/cplex/cplex.h

0
resources/3rdparty/glpk-4.57/examples/cpp.mod → resources/3rdparty/glpk-4.65/examples/cpp.mod

0
resources/3rdparty/glpk-4.57/examples/crypto.mod → resources/3rdparty/glpk-4.65/examples/crypto.mod

0
resources/3rdparty/glpk-4.57/examples/csv/distances.csv → resources/3rdparty/glpk-4.65/examples/csv/distances.csv

0
resources/3rdparty/glpk-4.57/examples/csv/markets.csv → resources/3rdparty/glpk-4.65/examples/csv/markets.csv

0
resources/3rdparty/glpk-4.57/examples/csv/parameters.csv → resources/3rdparty/glpk-4.65/examples/csv/parameters.csv

0
resources/3rdparty/glpk-4.57/examples/csv/plants.csv → resources/3rdparty/glpk-4.65/examples/csv/plants.csv

0
resources/3rdparty/glpk-4.57/examples/csv/transp_csv.mod → resources/3rdparty/glpk-4.65/examples/csv/transp_csv.mod

0
resources/3rdparty/glpk-4.57/examples/dbf/ForestMgt_Model_I_GIS_dbf.mod → resources/3rdparty/glpk-4.65/examples/dbf/ForestMgt_Model_I_GIS_dbf.mod

0
resources/3rdparty/glpk-4.57/examples/dbf/Forest_Cost.dbf → resources/3rdparty/glpk-4.65/examples/dbf/Forest_Cost.dbf

0
resources/3rdparty/glpk-4.57/examples/dbf/NetRev_Table.dbf → resources/3rdparty/glpk-4.65/examples/dbf/NetRev_Table.dbf

0
resources/3rdparty/glpk-4.57/examples/dbf/README → resources/3rdparty/glpk-4.65/examples/dbf/README

0
resources/3rdparty/glpk-4.57/examples/dbf/TCost_Table.dbf → resources/3rdparty/glpk-4.65/examples/dbf/TCost_Table.dbf

0
resources/3rdparty/glpk-4.57/examples/dbf/Yield_Table_Vol.dbf → resources/3rdparty/glpk-4.65/examples/dbf/Yield_Table_Vol.dbf

0
resources/3rdparty/glpk-4.57/examples/dbf/cultural_pres.dbf → resources/3rdparty/glpk-4.65/examples/dbf/cultural_pres.dbf

0
resources/3rdparty/glpk-4.57/examples/dbf/mgt_year.dbf → resources/3rdparty/glpk-4.65/examples/dbf/mgt_year.dbf

Some files were not shown because too many files changed in this diff

|||||||
100:0
Loading…
Cancel
Save