Error When Using MATLAB Symbolic Math Toolbox on Linux

From ECE Information Technology Services
Jump to navigationJump to search


Users of MATLAB 7 on Linux have reported that any attempt to perform symbolic calculations results in "Invalid MEX-file" error, as in this session:

syms a b;
a+b;

??? Invalid MEX-file '/opt/matlab7/toolbox/symbolic/maplemex.mexglx': /opt/matlab7/bin/glnx86/libmaple.so: symbol errno, version GLIBC_2.0 not defined in file libc.so.6 with link time reference.

Error in ==> maple at 104
[result,status] = maplemex(statement);

Error in ==> sym.maple at 85
[result,status] = maple(statement);

Error in ==> sym.plus at 22
X = maple(A(:),'+',B(:));


This bug is due to an incompatibility between the Maple library code and the C library on your system.

If you are using tcsh as your shell, the workaround is to set an environment variable before invoking MATLAB:

setenv LD_ASSUME_KERNEL 2.4.19
matlab

If you are using bash as your shell, the workaround is:

LD_ASSUME_KERNEL=2.4.19 matlab