This issue was previously due to a bug that has been fixed in Release 2013a (R2013a). For previous product releases, read below for any possible workarounds:
In order for MATLAB to execute a command, the file that contains the code for that command must be stored in a folder that is on the MATLAB search path. The MATLAB search path is just a list of folders on your file system. Each time MATLAB launches, that list is repopulated with the help of the file "pathdef.m". These warnings occur because the file "pathdef.m" was not created during installation.
To resolve the issue, follow these steps:
1) Start MATLAB as an administrator.
2) In the MATLAB Desktop interface, locate the address field of the Current Folder browser, in which you can enter a path to change your current working directory.
3) Enter "$MATLABROOT\toolbox\local\" in the address field, where $MATLABROOT should be replaced with the location where MATLAB is installed. On Windows, this is typically in a folder such as:
C:\Program Files\MATLAB\R2012a
On Mac OS X, this is typically:
/Applications/MATLAB_R2012a.app
For example, if I am using MATLAB R2012a on Mac OS X, in the address bar, I would enter:
/Applications/MATLAB_R2012a.app/toolbox/local
4) At the MATLAB Command Window, execute the following commands:
restoredefaultpath;
matlabrc
savepath
These commands will cause a new file, "pathdef.m", to be created.
You should now be able to relaunch MATLAB without seeing those warning messages, and you should be able to execute commands at the MATLAB Command Window.
If the issue is not resolved, try creating the "pathdef.m" file on your desktop by replacing the "savepath" command above with a command such as:
savepath C:\Users\myusername\Desktop\pathdef.m
You can now manually copy that "pathdef.m" file from your desktop into $MATLABROOT\toolbox\local.
Best Answer