To download the code you can simply clone it from the repository


go to


The installation of mSim is straightforward. Unzip or untar the file and that’s all.

To obtain access to all available functions of mSim you need to add to the Matlab path all the folders of mSim. One way to do this is to run:

where msim_root is the main mSim directory.

Alternatively, you can add the above line to the startup.m file.

If you clone the repository then the above command will add the .git folder and all its subfolders under the Matlab path. To avoid this add each directory individually. For example to add only the useful folders:

To access the documentation make sure you open the Matlab help file after the above commands are executed. In that case, you should be able to see mSim as an additional toolbox


In Matlab version 2012b and above click on the supplemental software tab as shown below:


This should open the traditional help file menu showing only the available third party software

mSim contains a few functions written in C/C++. To use them you need to compile them. You can do so by running the following command from the msim_root directory.

mSim is based on external codes for mesh generation and visualization.

The Gmsh can be downloaded from

The paraview can be downloaded from

Binary distributions of both codes are available for a variety of OS and architectures.