<div style="line-height:1.7;color:#000000;font-size:14px;font-family:System">Dear <span style="font-family: arial; white-space: pre-wrap;">Marc,</span><br /><br /><div>Thanks for your kind response. I have tried it as you suggested and it works!</div><div><br /></div><div>Although the code is a little redundant, it functions well.</div><div><br /></div><div>Thank you again! </div><div><br /></div><div>Regards!</div><div><br /></div><div><br /></div><div>----------------</div><div>Waiming Zhu</div><div><br /></div><div><br /></div><br /><br /><div  style="position:relative;zoom:1"></div><br /><pre><br />From: Marc Pfetsch <pfetsch@mathematik.tu-darmstadt.de>
Date: 2021-05-13 21:52:38
To:  scip@zib.de
Subject: Re: [SCIP] SoPlex Status Code -7>
>
>Dear Waiming,
>
>in SoPlex one should indeed always first include the columns, then the
>rows. The run time overhead happens because of the internal data structures.
>
>In your case, please reconsider whether it is at least possible to add
>some columns up-front. From the times you indicate, it might be
>advantageous to have a two-loop approach. In the first, you can count
>the number of columns you need. Then you create the columns and then the
>rows. Note that you can change properties of the columns later, so a
>stand-in is possible.
>
>Finally, you might consider solving the dual, where the roles of rows
>and columns are flipped.
>
>Hope this helps.
>
>Best
>
>Marc
>
>
>
>
>
>On 12/05/2021 14:30, 朱外明 wrote:
>> Hi,
>> 
>> I am using SoPlex 5.0.2 as a callable lib (coded in C++) to solve a LP
>> problem. 
>> 
>> The tested instance is truely simple. However, SoPlex reports:
>> 
>> "Error: SoPlex returned with status -7." 
>> 
>> if I use  "row first column second" adding method, the outline code of
>> which are as follows:
>> 
>> /*add rows*/
>> for (int k = 0; k < n; k++){
>> DSVector row(0);
>> model.addRowReal(LPRow(row, soplex::LPRow::Type::LESS_EQUAL, rhs));
>> }
>> 
>> /*add columns*/
>> for (int k = 0; k < m; k++){
>>         DSVector var(2);
>> ...
>>         model.addColReal(LPCol(ege->distance, var, infinity, 0.0));
>> }
>> 
>> 
>> SoPlex will works well if I code follow the "column first row second"
>> method, in which the same instance can be solved in 0.01 seconds.
>> 
>> I also tried the function 'SetRealParam' to set the time limit:
>> "model.setRealParam(SoPlex::TIMELIMIT, 10);" . But still failed.
>> 
>> I need to use the "row first column second" method as there is a special
>> structure in my formulation. 
>> 
>> 
>> I much appreciate if anyone who tell me what is the most possible reason
>> or what should I do to make SoPlex works. 
>> 
>> Thanks a lot.
>> 
>> 
>> Regards!
>> 
>> 
>> -------------------------------------------------------------
>> Waiming Zhu
>> School of Management, Hefei University of Technology
>> 
>> 
>> 
>> 
>> _______________________________________________
>> Scip mailing list
>> Scip@zib.de
>> https://listserv.zib.de/mailman/listinfo/scip
>> 
>_______________________________________________
>Scip mailing list
>Scip@zib.de
>https://listserv.zib.de/mailman/listinfo/scip
</pre></div><br>