Create MuPAD Notebooks


MuPAD® notebooks will be removed in a future release. Use MATLAB® live scripts instead.

To convert a MuPAD notebook file to a MATLAB live script file, see convertMuPADNotebook. MATLAB live scripts support most MuPAD functionality, although there are some differences. For more information, see Convert MuPAD Notebooks to MATLAB Live Scripts.

Before creating a MuPAD notebook, it is best to decide which interface you intend to use primarily for your task. The two approaches are:

  • Perform your computations in the MATLAB Live Editor while using MuPAD notebooks as an auxiliary tool. This approach is recommended and implies that you create a MuPAD notebook, and then execute it, transfer data and results, or close it from the MATLAB Live Editor.

  • Perform your computations and obtain the results in the MuPAD Notebook. This approach is not recommended and implies that you use the MATLAB Live Editor only to access MuPAD, but do not intend to copy data and results between MATLAB and MuPAD.

When you start a MuPAD notebook, you can choose to use MATLAB live script instead.

If you created a MuPAD notebook without creating a handle, and then realized that you need to transfer data and results between MATLAB and MuPAD, use allMuPADNotebooks to create a handle to this notebook:

nb = allMuPADNotebooks
nb = 

This approach does not require saving the notebook. Alternatively, you can save the notebook and then open it again, creating a handle.

If You Need Communication Between Interfaces

If you perform computations in both interfaces, use handles to notebooks. The toolbox uses this handle for communication between the MATLAB workspace and the MuPAD notebook.

To create a blank MuPAD notebook from the MATLAB Command Window, type

nb = mupad

The variable nb is a handle to the notebook. You can use any variable name instead of nb.

To create several notebooks, use this syntax repeatedly, assigning a notebook handle to different variables. For example, use the variables nb1, nb2, and so on.

If You Use MATLAB to Access MuPAD

Use the mupad Command

To create a new blank notebook, type mupad in the MATLAB Command Window.

Use the Welcome to MuPAD Dialog Box

The Welcome to MuPAD dialog box lets you create a new notebook or program file, open an existing notebook or program file, and access documentation. To open this dialog box, type mupadwelcome in the MATLAB Command Window.

Create New Notebooks from MuPAD

If you already opened a notebook, you can create new notebooks and program files without switching to the MATLAB Live Editor:

  • To create a new notebook, select File > New Notebook from the main menu or use the toolbar.

  • To open a new Editor window, where you can create a program file, select File > New Editor from the main menu or use the toolbar.