SSH Matlab Julia Sagemath
Currently one can use the following programs with SSH:
Further programs will follow.
Be aware: Probably you will not be the only user on the device. Therefore please try to keep the workload as low as possible!
Furthermore please keep in mind, that once every morning all SSH connections will be terminated.
ATTENTION: For the use of the server a working Math-Cip-Pool-Account is necessary !! (Only math students get a Cip-Pool-Account)
Using Matlab from outside
As students cannot use the math department’s computer lab (the CIP Pool) right now due to the current pandemic, one can access Matlab from outside. To do so proceed as follows:
1. Establish a VPN connection to the university network
A detailed instruction can be found here: https://www.anleitungen.rrze.fau.de/internet-zugang/vpn/.
2. Log into the CIP’s SSH server
Therefore a SSH client is needed, which one might need to install. For Windows one can use for example PuTTY (https://putty.org/)
To open a SSH connection with PuTTY one needs to enter the following Host-IP and credentials.
Host address: 220.127.116.11
User name: IDM identification (e.g. ab01cdef)
Password: CIP password (by default identical to IDM password)
Detailed instructions on how to use the SSH connection can be found here. Now you are connected to the CIP server and in a command line window in your home directory.
3. Optional: Set up the text editor nano in a “MATLAB friendly” way
To do this, use this command to load/copy the configuration file into ones .nanorc:
mkdir -p ~/.nano && wget -O ~/.nano/octave.nanorc https://www.math.fau.de/download/colorcodes --no-check-certificate&& echo "include ~/.nano/octave.nanorc" >> ~/.nanorc
4. Starting MATLAB
With the following command one can start MATLAB without a graphical user interface and nano as ones text editor:
matlab -nodisplay -r "setenv('EDITOR','nano')"
After executing the command you are in the MATLAB console. First of all, when using script files, as in the desktop version, one should set the current path relative to which all the entered file names are interpreted. In order to navigate with the terminal window, one can use
pwd to have the current path shown or
cd to navigate within the folders.
Executing a script
To do this start MATLAB as explained above. The following should appear on your screen:
MATLAB is selecting SOFTWARE OPENGL rendering. < M A T L A B (R) > Copyright 1984-2019 The MathWorks, Inc. R2019a (18.104.22.1682779) 64-bit (glnxa64) March 8, 2019 To get started, type doc. For product information, visit www.mathworks.com. Classroom License -- for classroom instructional use only. >>
Now you can run MATLAB scripts as usual by typing
>> run NameOfTheFile.m
into the command line. Pay attention that you started MATLAB in the folder of your script.
To edit scripts, please consult the explanations above under First Steps. By
files can be edited.
Plotting graphs is not as easy as when using the regular Matlab graphic interface. The command ‘plot’ can still be used, but no graphical plot will be shown. But in the background, a normal plot command is still executed. You can save said plotted file as a svg-file by typing
It will be saved in your current folder. Other file extensions like ‘-dpng’ are also possible. For further explanation and refined control, see the print documentation from MATLAB (https://www.mathworks.com/help/matlab/ref/print.html). To view the file, copy the files on your personal computer as described in the following part. The path on the CIP computer mostly look like:
You can exit Matlab by typing ‘exit’.
Copy files from the CIP computer to your own computer
It is assumed that the m-files are on your personal computer. You must be able to use the command ‘scp’ for the following instructions. On Mac and Linux, this is built into the operating system.
(Windows) For Windows, the program WinSCP can be used. To log in, first select scp as transmission protocol, secondly enter “22.214.171.124” in the server address (without ” “) and finally port 22 should be used as port. The user name is the IdM identifier (eg. ab01cdef) and the password is your regular IdM password.
After installing Drag and Drop is possible in between the server and your device at home.
Another way to approach this issue: PuTTY provides the tool pscp for this purpose (https://the.earth.li/~sgtatham/putty/0.73/htmldoc/Chapter5.html#psv)
(Mac/Linux) To copy files, enter
scp /Ordner/Filename firstname.lastname@example.org:~/Ordner
in your command line. Be aware that the paths have to be absolute, so you have to give the entire path.
Option Resultat -nojvm Starting MATLAB without Java® Virtual Machine (JVM™) Software. It reduces the starting time and the workload of the RAM. -nodisplay Starting JVM Software without MATLAB Desktop. -logfile filename Writing the complete output in the file named filename (also the logs) -r For interactive working. -h Shows the start options.
> nano’s shortcuts <
External usage of Julia
To start the program, use the following command
An introduction to Julia:
External usage of Sagemath
To start the program, use the following command
An introduction to Sagemath: