sym_subs

Symbolic

Substitute a value for a variable in a symbolic expression. Alias for subs().

Syntax

sym_subs(expr, var, val)

Examples

sym_subs('x^2 + 1', 'x', '3')
▶ Run
sym_subs('a*x + b', 'x', '5')
▶ Run

See Also

Try SimLab — Free MATLAB® Alternative

466 functions. Runs in your browser. No install.

Open SimLab

Stay Updated

Get notified about new simulations and tools. We send 1-2 emails per month.