fricas
(1) -> myExpr := (1-e^x)^2 - (e^(2*x)- 2*e^x + 1)
Type: Expression(Integer)
fricas
dumbRule := rule e^(a*b) == e^(b*a)
Type: RewriteRule
?(Integer,
Integer,
Expression(Integer))
fricas
dumbRule myExpr
Type: Expression(Integer)
fricas
simplify((1-e^x)^2 - (e^(2*x)- 2*e^x + 1))
Type: Expression(Integer)
fricas
simplify((1-%e^x)^2 - (%e^(2*x)- 2*%e^x + 1))
Type: Expression(Integer)
fricas
)set output algebra on
fricas
)set output tex off
fricas
(1-e^x)^2 - (e^(2*x)- 2*e^x + 1)
2 x x 2
(6) - e + (e )
Type: Expression(Integer)
fricas
unparse(%::InputForm)
(7) "(-1)*e^(2*x)+(e^x)^2"
Type: String
fricas
)set output algebra off
fricas
)set output tex on