The SYM command creates a symbolic expression object. Symbolic expressions can be simplified, normalized, differentiated, integrated, evaluated, plotted, and displayed as a slideshow.
slideshow(sym(exp(i*x)))
This example creates the symbolic expression exp(i*x) and displays a slideshow showing the expression, its complex polar plot, expression tree, simplified form, canonical form, derivative, and summary statistics.
sym(expression)
The input should be a mathematical expression using variables, constants, arithmetic operators, and supported functions.
+, -, *, /, and ^sin, cos, tanexp and logsqrtabs, arg, re, im, and conj for complex expressions
Because SYM returns an extractable symbolic object, additional views can be requested with extract.
extract(sym(sin(x^2)),"deriv")
extract(sym(sin(x^2)),"simplify")
extract(sym(sin(x^2)),"normalize")
extract(sym(sin(x^2)),"canon")
extract(sym(sin(x^2)),"tree")
extract(sym(sin(x^2)),"variables")
extract(sym(sin(x^2)),"stats")
extract(sym(sin(x^2)),"slideshow")
For ordinary real-valued expressions, the slideshow includes a real plot of the function and its derivative. Other variables are held constant at 1.0, allowing multivariable formulas to be displayed as a single curve.
slideshow(sym(3*x^2))
This plots 3*x^2 together with its derivative 6*x.
Expressions containing the imaginary unit i are evaluated using complex arithmetic. The slideshow displays a complex polar plot showing the image of a path under the symbolic expression.
slideshow(sym(exp(i*x)))
This evaluates the expression in the complex plane and displays the radius and argument of the resulting complex values.
The SYM command is useful for exploring the structure of mathematical expressions. It helps show not only the final result, but also the underlying expression tree and the transformations produced by simplification, normalization, canonicalization, and differentiation.
The symbolic engine is intended for exploratory analysis and documentation. Some advanced symbolic integrations or derivatives may not be supported for every expression.