我想要一个快速功能来加速输入
pretty(simplify(x))
所以我做了一个功能:
function [ret] = ps(input)
ret = pretty(simplify(input))
end
足够简单。没工作:
Error using sym.pretty
Too many output arguments.
Error in ps (line 2)
output_args = pretty(simplify(sym(input_args)))
所以我把它分开了:
function [ret] = ps(input)
t1 = sym(input)
t2 = simplify(t1)
t3 = pretty(t2)
ret = t3
end
结果:
Error using sym.pretty
Too many output arguments.
Error in ps (line 4)
t3 = pretty(t2)
是什么给出了?