>> syms a b c d x y
expand((a+b)^3)
factor(a^3+3*a^2*b+3*a*b^2+b^3)
[n d] = numden(a/b+c/d)
simplify((x\^2+2*x+1)/(x+1))
>> syms x >> y = x/(1+x/(1+x)); >> [n d] = numden(y) n = x*(1+x) d = 1+2*x