While attempting to start Matlab R2013b in Ubuntu, I get the following dialog box with an error message and Matlab crashes and closes.
Can someone explain the error and how to rectify it?

1 Answer
This is a known JDK bug. It is addressed in this question pretty thoroughly from the java perspective.
When it comes to Matlab, you options seem to be (apart from upgrading Matlab and/or OS):
Add the following JVM startup option through
java.optsfile:-Djava.util.Arrays.useLegacyMergeSort=trueUse a different java version by setting
MATLAB_JAVAenvironmental variable. It may result in all sorts of side-effects, depending on which Matlab / Java combination you end up using.
11 Comments
nirvana-msu
It comes with its own JVM on all operating systems. It does not respect windows
JAVA_HOME environmental variable as mentioned in this answer, and pretty sure the same is true for linux. You need to set MATLAB_JAVA instead.nirvana-msu
You can find the list of bundled JVM versions for Matlab releases on the wiki page. Using a different major java version would likely result in severe issues. Using a different minor version should be ok. I would strongly advise, though, to try setting
useLegacyMergeSort flag via java.opts first. It is much simpler and should not result in any problems.nirvana-msu
Just add this line to
java.opts. Read the docs on how to start Matlab properly so JVM would pick up this configuration (one option is to have java.opts in the same directory you start Matlab in).Tasos Papastylianou
@user_1_1_1 if the above fails, then yes, try Octave, it's not always 100% compatible but I've had very few problems I couldn't work around, and basic functionality is all there. On linux if you want the latest version you'd have to compile from source though, which, if you've not done before, you might stumble there. Also, what ubuntu do you have? If it's an older version, it may be worth trying on a newer ubuntu version?
Tasos Papastylianou
happy to help if you get stuck building from source. just drop me a line.
|
matlab -nodesktop -nosplash)matlab -nodisplayeven.