[Top][All Lists]

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
## Re: [Help-glpk] Working with larger numbers

**From**: |
Andrew Makhorin |

**Subject**: |
Re: [Help-glpk] Working with larger numbers |

**Date**: |
Wed, 30 Jul 2008 13:48:47 +0400 |

To fix the defect causing round-off errors please insert the following
fragment in the routine set_d_eps (file glplpx10.c, lines 63-71):
63 int s, n, j;
64 double f, p, q, eps = 1e-9;
65 mpq_t temp;
66 xassert(-DBL_MAX <= val && val <= +DBL_MAX);
+ if (val == floor(val))
+ { /* if val is integral, do not approximate */
+ mpq_set_d(x, val);
+ goto done;
+ }
67 if (val > 0.0)
68 s = +1;
69 else if (val < 0.0)
70 s = -1;
71 else
and then recompile the package as usual.
Note that these changes will appear in a next release of the package.

**[Help-glpk] Working with larger numbers**, *Markus Pilz*, `2008/07/28`
**Re: [Help-glpk] Working with larger numbers**, *Gabor Retvari*, `2008/07/28`
**Re: [Help-glpk] Working with larger numbers**, *Andrew Makhorin*, `2008/07/28`
**Re: [Help-glpk] Working with larger numbers**, *Markus Pilz*, `2008/07/29`
**Re: [Help-glpk] Working with larger numbers**, *Andrew Makhorin*, `2008/07/29`
**Re: [Help-glpk] Working with larger numbers**, *Michael Hennebry*, `2008/07/29`
**Re: [Help-glpk] Working with larger numbers**, *Andrew Makhorin*, `2008/07/29`
**Re: [Help-glpk] Working with larger numbers**, *Michael Hennebry*, `2008/07/29`
**Re: [Help-glpk] Working with larger numbers**, *Markus Pilz*, `2008/07/29`
**Re: [Help-glpk] Working with larger numbers**, *Michael Hennebry*, `2008/07/29`