====== Matlab ====== Mathworks Matlab is available on our HPC facilities as part of our University licensing agreement. It is available to all users. ===== Check Versions ===== $ module avail MATLAB ------------------------------------------------------------ /mnt/storage/apps/eb/modules/all ------------------ MATLAB/2017a MATLAB/2018b MATLAB/2020a MATLAB/2022b MATLAB/2024a (D) Where: D: Default Module $ The actual versions displayed may vary depending on which HPC facility you are using. Use the ''module avail'' command, as above, to determine which versions are present. ---- ===== Running ===== ==== Open OnDemand Application ==== **This section is incomplete** This documentation section is still being written and will not be available until **Comet** is in production. ==== Interactive Desktop GUI ==== Interactive via the Matlab desktop interface (you must have enabled [[advanced:interactive#ssh_and_x11_tunnelling|X11 over SSH]] in your client): $ module load MATLAB $ matlab Matlab will load the desktop interface/window and, assuming you have correctly configured your X11 over SSH settings, this should be displayed on your desktop: {{:advanced:matlab_x11_ssh.jpg?1000|}} ==== Command Line ==== Run Matlab in command line mode, without the desktop application window: $ module load MATLAB $ matlab -nodesktop -nosplash MATLAB is selecting SOFTWARE rendering. Opening log file: /path/to/your/home/java.log.25303 < M A T L A B (R) > Copyright 1984-2024 The MathWorks, Inc. R2024a Update 2 (24.1.0.2578822) 64-bit (glnxa64) April 9, 2024 To get started, type doc. For product information, visit www.mathworks.com. >> ---- ===== Tips ===== ==== Matlab Home Directory Use ==== When running Matlab on the HPC it will create an entirely new, host-specific preference directory within your ''.MathWorks/ServiceHost'' folder in your home directory. Since you may end up running Matlab on many dozens of different hosts via Slurm, this //can// end up taking up many gigabytes of your home directory space: $ cd $HOME $ cd .MathWorks/ServiceHost $ du -h -s * 950M login01/ 898M login02/ 1023M sb085/ 1291M sb090/ 1407M sb091/ 789M sb099/ $ It is __safe__ to delete these directories, as they will be recreated again the next time you run Matlab on another host. //Initial discussion of large, per-host ''ServiceHost'' folders reported on the Mathworks support forum:// * https://www.mathworks.com/matlabcentral/answers/2145014-is-it-safe-to-delete-the-node-specific-folders-under-mathworks-servicehost-on-linux ---- [[advanced:software|Back to Advanced Software Index]]