X Forwarding on Mac
While Mac is *nix based, you'll need to install X Windows software on a Mac before you can do X forwarding. First download and install XQuartz, the Mac version of X Windows. Once its installed, find and run XQuartz via Spotlight:
When you launch XQuartz, by default it will start XTerm, an X Windows enabled terminal.
Now that you have XTerm open, use ssh with the -Y option to use X Forwarding when connecting to the cluster.
When you then use qlogin, it will automaticly forward; so when you launch MATLAB, you will be greeted by its interface.