Opened 5 years ago

Closed 8 months ago

#69 closed defect (migrated)

Unable to handle LP without Non-GUB columns in testGub.cpp

Reported by: neo_liu Owned by: somebody
Priority: major Milestone:
Component: component1 Version:
Keywords: Cc:

Description

I find that line 144-150 in testGub.cpp tries to handle LP without Non-GUB columns. However, it doesn't work.

A possible fix could be recording the last GUB row we found, inserting it into the right place in 'which', and updating corresponding counters.

84a85
>      int lastGubRow = -1;
118a120
>                lastGubRow = iRow;
143,150c145,163
<           }
<           if (!numberNormal) {
<                printf("Putting back one gub row to make non-empty\n");
<                for (iColumn = gubStart[putGub]; iColumn < gubEnd[putGub]; iColumn++)
<                     mark[numberNormal++] = iColumn;
<                putGub++;
<                numberGub--;
<           }
---
>         }
>         if (!numberNormal) {
>             printf("Putting back one gub row to make non-empty\n");
>             for (iColumn = gubStart[putGub]; iColumn < gubEnd[putGub]; iColumn++)
>                 mark[numberNormal++] = iColumn;
>             putGub++;
>             numberGub--;
>             numberNonGub++;
> 
>             int index = putNonGub;
>             while (index < numberRows && which[index] < lastGubRow) {
>                 which[index - 1] = which[index];
>                 index++;
>             }
>             which[index - 1] = lastGubRow;
>             --putNonGub;
> 
>             rowIsGub[lastGubRow] = 0;
>         }

Change History (1)

comment:1 Changed 8 months ago by stefan

  • Resolution set to migrated
  • Status changed from new to closed

This ticket has been migrated to GitHub and will be resolved there: ​https://github.com/coin-or/Clp/issues/69

Note: See TracTickets for help on using tickets.