Open MATLAB and click the Add-Ons drop down menu on the top right
Start Support Package Installer
Click on Get Hardware Support Packages in the drop down menu to start the installer. Select 'Install from Internet' as the source for installing the support package
Select Arduino from a list of support packages
Click Next to see a list of support packages and select Arduino from the list for MATLAB Support Package and Arduino Due for the Simulink Support Package.
Click next and log in to your MathWorks account. If you don't have a MathWorks account, you can create one during the install process or by visiting this page on the MathWorks website.
Continue and Complete the Installation
Accept the license agreement on the next screen and click Next through the following screens to finish the installation for both MATLAB and Simulink Support Package for Arduino.