Added on January 15, 2005. Thanks to Stein Grongstad.
If you are planning to install cplexmex on a Linux machine running Matlab R14, please read carefully what follows.
Due to an upgrade of the Matlab APIs all MEX-files have to be recompiled under R14, as explained in the Matlab Release Notes
http://www.mathworks.com/access/helpdesk/help/techdoc/rn/externab.html .
However it can happen that running cplexmex Matlab aborts and exits abnormally. This does not mean that it happens always BUT it may happen and the reason is explained below.
The Matlab crash comes from the mexErrMsgTxt function. To fix this problem please follow the instructions described in the following mailing list:
http://mathforum.org/epigone/comp.soft-sys.matlab/dexyurtwan
This should solve the problem. If you do not have the knowledge to do that or you do not have the rights on your machine to change all the things described, the problem can be still solved. As a temporary work around you could replace in glpkmex.c all occurences of mexErrMsgTxt with the following piece of code:
| Replace: | with: |
| mexErrMsgTxt(<string>) |
mexPrintf(<string>); |
With this modification, if for example you set param.solver=5 (please note that solver can be at most 4) you should get the following output in the Matlab command window:
--- LP problem ---
'solver' parameter must be only:
0 - Automatic [default],
1 - Primal Simplex,
2 - Dual Simplex,
3 - Network Simplex,
4 - Barrier
??? One or more output arguments not assigned during call to
'/directories/cplexmex/cplexmex.mexglx'.
Error in ==> testcplex at 41
[xopt,opt,status,extra]=cplexmex(sense,H,F,A,B,ctype,lb,ub,vartype,[],params)
>>