Created error messages relating to the mex file library when I tried to run it on Matlab 2018b. I switched back to 2016b, here everything works fine.