bug-glpk
[Top][All Lists]

## Re: [Bug-glpk] Problem in the MIP problem

 From: Andrew Makhorin Subject: Re: [Bug-glpk] Problem in the MIP problem Date: Fri, 17 Oct 2008 14:40:26 +0300

```> I have a problem for integer variables with a lower bound equal at upper
> bound.

> I obtain this error message:

> lpx_intopt: column 1 has incorrect bounds

> My problem is:

> PROBLEM: spConf_ whose formulation ref number is 1
> Minimize
>  Objectif: -11.6667 Yi0_copy -11.6667 Yi1_copy -5 Yi2_copy
>  -5 Yi3_copy -2.7 Yi4_copy -4.6 Yi5_copy -4.6 Yi6_copy -4.6 Yi7_copy
>  -21.5 Yi8_copy -21.5 Yi9_copy
> Subject To
>  RTBH____: +7 Yi0_copy +7 Yi1_copy +2 Yi2_copy +2 Yi3_copy
>  +2 Yi4_copy +4 Yi5_copy +4 Yi6_copy +4 Yi7_copy +9 Yi8_copy
>  +9 Yi9_copy <= 10

> Bounds
>  1 <= Yi0_copy <= 1
>  0 <= Yi1_copy <= 1
>  0 <= Yi2_copy <= 1
>  0 <= Yi3_copy <= 1
>  0 <= Yi4_copy <= 1
>  0 <= Yi5_copy <= 1
>  0 <= Yi6_copy <= 1
>  0 <= Yi7_copy <= 1
>  0 <= Yi8_copy <= 1
>  0 <= Yi9_copy <= 1

> Integers

>  Yi0_copy  Yi1_copy  Yi2_copy  Yi3_copy  Yi4_copy  Yi5_copy  Yi6_copy
> Yi7_copy
>  Yi8_copy  Yi9_copy
> End

> Why?

> Though, I use this function to include bound for the first variable:

> glp_set_col_bnds(glpkProbPtr,id+1,GLP_FX,dlb[id],dub[id]);

The error appears because the column (variable) Yi0_copy is specified
as double-bounded (GLP_DB), however, its lower and upper bounds are
identical. To avoid the error the type of Yi0_copy should be GLP_FX,
not GLP_DB; in particular, in the cplex lp file Yi0_copy should be
specified as follows:

Bounds
Yi0_copy = 1

```