Code Performance

Profile and improve performance


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.

MuPAD Functions

rtimeMeasure real time
timeMeasure CPU time
Pref::maxTimeTime limit for computations
prog::ntimeHardware independent time unit
prog::profileDisplay timing data of nested function calls

Examples and How To

Measure Time

The simplest tool you can use to estimate code performance is the time function.

Profile Your Code

Profiling is a way to measure where a program spends time.


When to Analyze Performance

Symbolic computations can be very time consuming.

Techniques for Improving Performance

For most symbolic and numeric computation tasks, MuPAD implements the fastest and most reliable currently known algorithms.