| Products & Services | Solutions | Academia | Support | User Community | Company |
| Download Product Updates | | | Get Pricing | | | Trial Software |
| Documentation → Symbolic Math Toolbox |
| Contents | Index |
| Learn more about Symbolic Math Toolbox |
syms arg1 arg2 ...
syms arg1 arg2 ... real
syms arg1 arg2 ... clear
syms arg1 arg2 ... positive
syms arg1 arg2 ... is a shortcut for
arg1 = sym('arg1');
arg2 = sym('arg2'); ...syms arg1 arg2 ... real is a shortcut for
arg1 = sym('arg1','real');
arg2 = sym('arg2','real'); ...syms arg1 arg2 ... clear is a shortcut for
arg1 = sym('arg1','clear');
arg2 = sym('arg2','clear'); ...syms arg1 arg2 ... positive is a shortcut for
arg1 = sym('arg1','positive');
arg2 = sym('arg2','positive'); ...Each input argument must begin with a letter and can contain only alphanumeric characters. For compatibility with previous versions of the software, syms arg1 arg2 ... unreal has exactly the same effect as syms arg1 arg2 ... clear.
In functions and scripts, do not use the syms command to create symbolic variables with the same names as MATLAB functions. For these names MATLAB does not create symbolic variables, but keeps the names assigned to the functions. If you want to create a symbolic variable with the same name as some MATLAB function inside a function or a script, use the sym command. For example:
alpha = sym('alpha')syms x y real is equivalent to
x = sym('x','real');
y = sym('y','real');To clear the symbolic objects x and y of 'real' status, type
syms x y clear
Note that clear x will not clear the symbolic object of its 'real' status. You can achieve this using
syms x clear to remove the 'real' status from x without affecting any other symbolic variables.
reset(symengine) resets the MuPAD engine.
clear all clears all objects in the MATLAB workspace and resets the MuPAD engine.
Clearing Assumptions and Resetting the Symbolic Engine
![]() | symengine | sym2poly (sym) | ![]() |

Includes the most popular MATLAB recorded presentations with Q&A sessions led by MATLAB experts.
| © 1984-2009- The MathWorks, Inc. - Site Help - Patents - Trademarks - Privacy Policy - Preventing Piracy - RSS |