Decision Optimization

Decision Optimization

Delivers prescriptive analytics capabilities and decision intelligence to improve decision-making.

 View Only
Expand all | Collapse all

out of memory (Cplex-Matlab) Error

  • 1.  out of memory (Cplex-Matlab) Error

    Posted Fri November 25, 2011 05:36 AM

    Originally posted by: SystemAdmin


    Dear Friends,
    I have the same problem regrading the out of memory (Cplex-Matlab)Error. I already solved my Model by less constraints and variables so I am sure that my Model and code are correct. However, when I tried to solve my real Model I was facing with the below comment:
    it should be noted that, I am using windows 7 - 32bit and 4GB RAM. I got the mentioned Error after approximately 14 min. and the used memory was 1170 Mb so I increased the default memory to 3Gb and finally I got the same error after 30 min. and the used memory was 2160 Mb (it has been recommended in different sources the memory should not be increased to more than 3Gb). In such circumstances,Would you please do me a favor and let me know about your idea to solve this problem.
    P.S. attached is the *.m file.

    I am looking forward to hearing from you.
    Root node processing (before b&c):
    Real time = 0.67
    Parallel b&c, 4 threads:
    Real time = 1815.17
    Sync time (average) = 261.86
    Wait time (average) = 514.48

    Total (root+branch&cut) = 1815.84 sec.
    Warning: MIP starts not constructed because of out-of-memory status.
    ??? Error using ==> cplexlink121
    CPLEX Error 1001: Out of memory.
    Error in ==> C:\ILOG\CPLEX121\matlab\x86_win32\@Cplex\Cplex.p>Cplex.solve at 641
    % The length of the vector must not be
    Error in ==> Vw_final_Test_newObj at 292
    cplex.solve();
    #CPLEXOptimizers
    #DecisionOptimization


  • 2.  Re: out of memory (Cplex-Matlab) Error

    Posted Fri November 25, 2011 09:35 AM

    Originally posted by: John Cui


    I just tried CPLEX12.3
    #CPLEXOptimizers
    #DecisionOptimization


  • 3.  Re: out of memory (Cplex-Matlab) Error

    Posted Fri November 25, 2011 09:36 AM

    Originally posted by: John Cui


    I just tried CPLEX 12.3, your problem can be solved in seconds:

    
    Elapsed real time =   1.86 sec. (tree size =  0.01 MB, solutions = 3) *   211+  199                       144478.0000    96939.8733     9206   32.90% *   211+  199                       144072.0000    96939.8733     9206   32.71% *   211+  199                       143720.0000    96939.8733     9206   32.55% *   211+  199                       143370.0000    96939.8733     9206   32.38% *   211+  199                       143120.0000    96939.8733     9206   32.27% *   211+  199                       142870.0000    96939.8733     9206   32.15% *   211+  199                       142470.0000    96939.8733     9206   31.96% *   211+  199 142168.0000    96939.8733     9206   31.81% *   211+  199                       141820.0000    96939.8733     9206   31.65% *   211+  199                       141670.0000    96939.8733     9206   31.57% 211   201   120459.0809   149   141670.0000    96939.8733     9206   31.57% 502   479   125626.4664   430   141670.0000   125626.4664    16386   11.32% *   503+  318                       141520.0000   125626.4664    16404   11.23% 540    18   140292.9648    76   141520.0000   139783.6870    16857    1.23% *   618+   80                       140518.0000   139882.4828    17115    0.45% *   618+   73                       140416.0000   139882.4828    17115    0.38% *   634+   33                       140266.0000   139882.4828    17156    0.27% *   677+   46                       140216.0000   139903.5559    17270    0.22% *   727+   72                       140170.0000   139909.2391    17383    0.19% *   781+   78                       140018.0000   139911.2292    17481    0.08% 826    45   139924.1935    50   140018.0000   139911.2292    17558    0.08% *   864+   37                       139970.0000   139926.8765    17630    0.03% Clique cuts applied:  6 Cover cuts applied:  1 Implied bound cuts applied:  36 Flow cuts applied:  3 Mixed integer rounding cuts applied:  529 Zero-half cuts applied:  215 Gomory fractional cuts applied:  45   Root node processing (before b&c): Real time             =    1.78 Parallel b&c, 2 threads: Real time             =   11.33 Sync time (average)   =    0.64 Wait time (average)   =    0.00 ------- Total (root+branch&cut) =   13.11 sec. Objective function 1.3997e+005   y solution y1=1 y2=0 y3=1 y4=1 y5=1 y6=1 y7=1 y8=1 y9=1 y10=1 y11=1 y12=1 y13=1 y14=1 y15=0 I solution I11=0.667 I12=0.334 I13=0.001 I14=0.668 I15=0.335 I16=0.002 I17=0.669 I18=0.336 I19=0.003 I110=0.67 I111=0.337 I112=0.004 I113=0.671 I114=0.338 I115=0.005 I21=1.867 I22=0.734 I23=0.601 I24=0.468 I25=0.335 I26=0.202 I27=0.069 I28=0.936 I29=0.803 I210=0.67 I211=0.537 I212=0.404 I213=0.271 I214=1.138 I215=0.005 I31=0.6 I32=0.2 I33=0.8 I34=0.4 I35=0 I36=0.6 I37=0.2 I38=0.8 I39=0.4 I310=0 I311=0.6 I312=0.2 I313=0.8 I314=0.4 I315=0 I41=0.667 I42=0.334 I43=0.001 I44=0.668 I45=0.335 I46=0.002 I47=0.669 I48=0.336 I49=0.003 I410=0.67 I411=0.337 I412=0.004 I413=0.671 I414=0.338 I415=0.005 I51=0.534 I52=0.068 I53=0.602 I54=0.136 I55=0.67 I56=0.204 I57=0.738 I58=0.272 I59=0.806 I510=0.34 I511=0.874 I512=0.408 I513=0.942 I514=0.476 I515=0.01 I61=1.4 I62=0.8 I63=0.2 I64=0.6 I65=0 I66=0.4 I67=0.8 I68=0.2 I69=0.6 I610=0 I611=0.4 I612=0.8 I613=0.2 I614=0.6 I615=0 I71=0.534 I72=0.068 I73=0.602 I74=0.136 I75=0.67 I76=0.204 I77=0.738 I78=0.272 I79=0.806 I710=0.34 I711=0.874 I712=0.408 I713=0.942 I714=0.476 I715=0.01 I81=2.067 I82=0.134 I83=0.201 I84=0.268 I85=0.335 I86=0.402 I87=0.469 I88=0.536 I89=0.603 I810=0.67 I811=0.737 I812=0.804 I813=0.871 I814=1.938 I815=0.005 I91=0.6 I92=0.2 I93=0.8 I94=0.4 I95=0 I96=0.6 I97=0.2 I98=0.8 I99=0.4 I910=0 I911=0.6 I912=0.2 I913=0.8 I914=0.4 I915=6.6613e-016 I101=2.134 I102=0.268 I103=0.402 I104=0.536 I105=0.67 I106=0.804 I107=0.938 I108=0.072 I109=0.206 I1010=0.34 I1011=0.474 I1012=0.608 I1013=0.742 I1014=1.876 I1015=0.01 I111=1.534 I112=0.068 I113=0.602 I114=0.136 I115=0.67 I116=0.204 I117=0.738 I118=0.272 I119=0.806 I1110=0.34 I1111=0.874 I1112=0.408 I1113=0.942 I1114=1.476 I1115=0.01 I121=1.534 I122=0.068 I123=0.602 I124=0.136 I125=0.67 I126=0.204 I127=0.738 I128=0.272 I129=0.806 I1210=0.34 I1211=0.874 I1212=0.408 I1213=0.942 I1214=1.476 I1215=0.01 I131=1.067 I132=0.134 I133=0.201 I134=0.268 I135=0.335 I136=0.402 I137=0.469 I138=0.536 I139=0.603 I1310=0.67 I1311=0.737 I1312=0.804 I1313=0.871 I1314=0.938 I1315=0.005 I141=1.067 I142=0.134 I143=0.201 I144=0.268 I145=0.335 I146=0.402 I147=0.469 I148=0.536 I149=0.603 I1410=0.67 I1411=0.737 I1412=0.804 I1413=0.871 I1414=0.938 I1415=0.005 I151=0.534 I152=0.068 I153=0.602 I154=0.136 I155=0.67 I156=0.204 I157=0.738 I158=0.272 I159=0.806 I1510=0.34 I1511=0.874 I1512=0.408 I1513=0.942 I1514=0.476 I1515=0.01 I161=1.8 I162=0.6 I163=0.4 I164=0.2 I165=0 I166=0.8 I167=0.6 I168=0.4 I169=0.2 I1610=0 I1611=0.8 I1612=0.6 I1613=0.4 I1614=1.2 I1615=0 I171=1.334 I172=0.668 I173=0.002 I174=0.336 I175=0.67 I176=0.004 I177=0.338 I178=0.672 I179=0.006 I1710=0.34 I1711=0.674 I1712=0.008 I1713=0.342 I1714=0.676 I1715=0.01 I181=0.6 I182=0.2 I183=0.8 I184=0.4 I185=0 I186=0.6 I187=0.2 I188=0.8 I189=0.4 I1810=0 I1811=0.6 I1812=0.2 I1813=0.8 I1814=0.4 I1815=0 I191=1.4 I192=0.8 I193=0.2 I194=0.6 I195=0 I196=0.4 I197=0.8 I198=0.2 I199=0.6 I1910=0 I1911=0.4 I1912=0.8 I1913=0.2 I1914=0.6 I1915=0 I201=0.667 I202=0.334 I203=0.001 I204=0.668 I205=0.335 I206=0.002 I207=0.669 I208=0.336 I209=0.003 I2010=0.67 I2011=0.337 I2012=0.004 I2013=0.671 I2014=0.338 I2015=0.005 I211=1.4 I212=0.8 I213=0.2 I214=0.6 I215=0 I216=0.4 I217=0.8 I218=0.2 I219=0.6 I2110=0 I2111=0.4 I2112=0.8 I2113=0.2 I2114=0.6 I2115=0 I221=1.4 I222=0.8 I223=0.2 I224=0.6 I225=0 I226=0.4 I227=0.8 I228=0.2 I229=0.6 I2210=0 I2211=0.4 I2212=0.8 I2213=0.2 I2214=0.6 I2215=0 I231=1.8 I232=0.6 I233=0.4 I234=0.2 I235=0 I236=0.8 I237=0.6 I238=0.4 I239=0.2 I2310=0 I2311=0.8 I2312=0.6 I2313=0.4 I2314=1.2 I2315=0 I241=1.8 I242=0.6 I243=0.4 I244=0.2 I245=0 I246=0.8 I247=0.6 I248=0.4 I249=0.2 I2410=0 I2411=0.8 I2412=0.6 I2413=0.4 I2414=1.2 I2415=0 I251=1.467 I252=0.934 I253=0.401 I254=0.868 I255=0.335 I256=0.802 I257=0.269 I258=0.736 I259=0.203 I2510=0.67 I2511=0.137 I2512=0.604 I2513=0.071 I2514=0.538 I2515=0.005 I261=0.6 I262=0.2 I263=0.8 I264=0.4 I265=0 I266=0.6 I267=0.2 I268=0.8 I269=0.4 I2610=0 I2611=0.6 I2612=0.2 I2613=0.8 I2614=0.4 I2615=1.3323e-015 p solution P11=1 P12=0 P13=0 P14=1 P15=0 P16=0 P17=1 P18=0 P19=0 P110=1 P111=0 P112=0 P113=1 P114=0 P115=0 P21=3 P22=0 P23=1 P24=1 P25=1 P26=1 P27=1 P28=2 P29=1 P210=1 P211=1 P212=1 P213=1 P214=2 P215=0 P31=1 P32=0 P33=1 P34=0 P35=0 P36=1 P37=0 P38=1 P39=0 P310=0 P311=1 P312=0 P313=1 P314=0 P315=0 P41=1 P42=0 P43=0 P44=1 P45=0 P46=0 P47=1 P48=0 P49=0 P410=1 P411=0 P412=0 P413=1 P414=0 P415=0 P51=1 P52=0 P53=1 P54=0 P55=1 P56=0 P57=1 P58=0 P59=1 P510=0 P511=1 P512=0 P513=1 P514=0 P515=0 P61=2 P62=0 P63=0 P64=1 P65=0 P66=1 P67=1 P68=0 P69=1 P610=0 P611=1 P612=1 P613=0 P614=1 P615=0 P71=1 P72=0 P73=1 P74=0 P75=1 P76=0 P77=1 P78=0 P79=1 P710=0 P711=1 P712=0 P713=1 P714=0 P715=0 P81=4 P82=0 P83=2 P84=2 P85=2 P86=2 P87=2 P88=2 P89=2 P810=2 P811=2 P812=2 P813=2 P814=3 P815=0 P91=1 P92=0 P93=1 P94=0 P95=0 P96=1 P97=0 P98=1 P99=0 P910=0 P911=1 P912=0 P913=1 P914=0 P915=0 P101=4 P102=0 P103=2 P104=2 P105=2 P106=2 P107=2 P108=1 P109=2 P1010=2 P1011=2 P1012=2 P1013=2 P1014=3 P1015=0 P111=3 P112=0 P113=2 P114=1 P115=2 P116=1 P117=2 P118=1 P119=2 P1110=1 P1111=2 P1112=1 P1113=2 P1114=2 P1115=0 P121=3 P122=0 P123=2 P124=1 P125=2 P126=1 P127=2 P128=1 P129=2 P1210=1 P1211=2 P1212=1 P1213=2 P1214=2 P1215=0 P131=2 P132=0 P133=1 P134=1 P135=1 P136=1 P137=1 P138=1 P139=1 P1310=1 P1311=1 P1312=1 P1313=1 P1314=1 P1315=0 P141=2 P142=0 P143=1 P144=1 P145=1 P146=1 P147=1 P148=1 P149=1 P1410=1 P1411=1 P1412=1 P1413=1 P1414=1 P1415=0 P151=1 P152=0 P153=1 P154=0 P155=1 P156=0 P157=1 P158=0 P159=1 P1510=0 P1511=1 P1512=0 P1513=1 P1514=0 P1515=0 P161=3 P162=0 P163=1 P164=1 P165=1 P166=2 P167=1 P168=1 P169=1 P1610=1 P1611=2 P1612=1 P1613=1 P1614=2 P1615=0 P171=2 P172=0 P173=0 P174=1 P175=1 P176=0 P177=1 P178=1 P179=0 P1710=1 P1711=1 P1712=0 P1713=1 P1714=1 P1715=0 P181=1 P182=0 P183=1 P184=0 P185=0 P186=1 P187=0 P188=1 P189=0 P1810=0 P1811=1 P1812=0 P1813=1 P1814=0 P1815=0 P191=2 P192=0 P193=0 P194=1 P195=0 P196=1 P197=1 P198=0 P199=1 P1910=0 P1911=1 P1912=1 P1913=0 P1914=1 P1915=0 P201=1 P202=0 P203=0 P204=1 P205=0 P206=0 P207=1 P208=0 P209=0 P2010=1 P2011=0 P2012=0 P2013=1 P2014=0 P2015=0 P211=2 P212=0 P213=0 P214=1 P215=0 P216=1 P217=1 P218=0 P219=1 P2110=0 P2111=1 P2112=1 P2113=0 P2114=1 P2115=0 P221=2 P222=0 P223=0 P224=1 P225=0 P226=1 P227=1 P228=0 P229=1 P2210=0 P2211=1 P2212=1 P2213=0 P2214=1 P2215=0 P231=3 P232=0 P233=1 P234=1 P235=1 P236=2 P237=1 P238=1 P239=1 P2310=1 P2311=2 P2312=1 P2313=1 P2314=2 P2315=0 P241=3 P242=0 P243=1 P244=1 P245=1 P246=2 P247=1 P248=1 P249=1 P2410=1 P2411=2 P2412=1 P2413=1 P2414=2 P2415=0 P251=2 P252=0 P253=0 P254=1 P255=0 P256=1 P257=0 P258=1 P259=0 P2510=1 P2511=0 P2512=1 P2513=0 P2514=1 P2515=0 P261=1 P262=0 P263=1 P264=0 P265=0 P266=1 P267=0 P268=1 P269=0 P2610=0 P2611=1 P2612=0 P2613=1 P2614=0 P2615=0
    


    So please upgrade your CPLEX. :-)

    John Cui
    #CPLEXOptimizers
    #DecisionOptimization


  • 4.  Re: out of memory (Cplex-Matlab) Error

    Posted Sat November 26, 2011 05:26 AM

    Originally posted by: SystemAdmin


    Dear John Cui,
    Really Thanks for your fast and knowledgeable response. It's unbelievable that you got the results in 13 Sec. but I couldn't in 30 min. Actually, I am using CPLEX 11 and it's a little strange to have this large difference in performance between the 11 and 12.3. I am wondering if the only difference is from the CPLEX version or it can be affected by the computer specifications. Since, would you please let me know about the computer specification which you used to solve this problem.
    By the way, It is very nice of you if you can let me know how I can get the new version of CPLEX (12.3) for Matlab to update my CPLEX. Is this software free to use? I already installed the CPLEX 12.3 on my PC as it is free however, I don't know how I can add the new version of CPLEX on Matlab. Do I need licensee for the new version of CPLEX on Matlab?

    Warmest regards,
    Masood
    #CPLEXOptimizers
    #DecisionOptimization


  • 5.  Re: out of memory (Cplex-Matlab) Error

    Posted Sat November 26, 2011 09:41 AM

    Originally posted by: John Cui


    If you installed 12.3 version CPLEX, then matlab interface for CPLEX is free as CPLEX 12.1's matlab interface.

    And the usage is the same as CPLEX 12.1's MATLAB interface.

    John Cui
    #CPLEXOptimizers
    #DecisionOptimization


  • 6.  Re: out of memory (Cplex-Matlab) Error

    Posted Sat November 26, 2011 12:00 PM

    Originally posted by: SystemAdmin


    Sorry but I couldn't understand exactly if CPLEX is a free software in general or not.As I remember I downloaded and installed CPLEX from IBM website and I don't know it's a full version or trial. Regarding the CPLEX-Matlab interface I should say that it was already installed on my PC in the center that I am working and the version should be 11. In such circumstance, would you please let me know more about the possibility of installing the new version of CPLEX 12.1 on Matlab. Is there any website to download the new version?

    Thanks in advance,
    Masood
    #CPLEXOptimizers
    #DecisionOptimization


  • 7.  Re: out of memory (Cplex-Matlab) Error

    Posted Sat November 26, 2011 08:50 PM

    Originally posted by: John Cui


    Are you from academy?
    #CPLEXOptimizers
    #DecisionOptimization


  • 8.  Re: out of memory (Cplex-Matlab) Error

    Posted Sun November 27, 2011 03:56 AM

    Originally posted by: SystemAdmin


    Yes
    #CPLEXOptimizers
    #DecisionOptimization


  • 9.  Re: out of memory (Cplex-Matlab) Error

    Posted Sun November 27, 2011 07:22 AM

    Originally posted by: John Cui


    Ok, then you can follow instructions from below link to download CPLEX 12.3.

    http://www.ibm.com/developerworks/forums/thread.jspa?threadID=335577&tstart=0

    John Cui
    #CPLEXOptimizers
    #DecisionOptimization


  • 10.  Re: out of memory (Cplex-Matlab) Error

    Posted Mon November 28, 2011 06:40 AM

    Originally posted by: M8Y7_Masood_fathi


    Thanks you so much. It has been a long time that I was looking for this instruction.
    I tried to install the Cplex-Matlab interface but I have a problem and I really don't know what the solution is. I already asked my colleagues and I found that they also had the same problem several times.
    Attached is the instruction which I followed to install the CPLEX-Malab interface and the mentioned error is as below: (it should mentioned that this instruction is the one my colleagues already used and most of them didn’t have any problem to install the CPLEX 12.1)
    Would you please do me favor and help with this problem as well.

    Sincere appreciation in advance,
    Masood

    >> cplexgui
    ??? Error using ==> load
    Unable to read MAT-file C:\Program
    Files\IBM\ILOG\CPLEX_Studio_Academic123\cplex\examples\src\matlab\cplexgui.fig

    File may be corrupt.

    Error in ==> hgload>localLoadFile at 177
    AllVars = load(filename, '-mat');

    Error in ==> hgload at 59
    FigVersion, FigData, VerNum = localLoadFile(filename);

    Error in ==> openfig at 72
    fig, savedvisible = hgload(filename, struct('Visible','off'));

    Error in ==> gui_mainfcn>local_openfig at 286
    gui_hFigure = openfig(name, singleton, visible);

    Error in ==> gui_mainfcn at 159
    gui_hFigure = local_openfig(gui_State.gui_Name, gui_SingletonOpt,
    gui_Visible);

    Error in ==> cplexgui at 55
    gui_mainfcn(gui_State, varargin{:});
    #CPLEXOptimizers
    #DecisionOptimization


  • 11.  Re: out of memory (Cplex-Matlab) Error

    Posted Wed December 21, 2011 05:42 PM

    Originally posted by: PingLiu


    when I run this .m file until the line
    cplex=Cplex('Vw problem');
    

    why does it say
    ??? Undefined function or method 'Cplex' for input arguments of type 'char'.
     
    Error in ==> Vw_final_Test_newObj at 30
    cplex=Cplex('Vw problem');
    

    #CPLEXOptimizers
    #DecisionOptimization


  • 12.  Re: out of memory (Cplex-Matlab) Error

    Posted Thu December 22, 2011 01:37 AM