#!/usr/bin/env cadabra2 ex:=(\sin(x)**2 + \cos(x)**2)/x; map_sympy(_, "integrate"); ex; ex2:= \int{\sin(x) \cos(x)}{x}; map_sympy(_); ex3:= \sin(x)\cos(x); ex3._sympy_(); print(type(ex3._sympy_())) sympy.integrate(ex3); print(type(sympy.integrate(ex3))) ex4:= x**3 - x**2 - 4; map_sympy(_, "solve"); ex4; {r,t}::Coordinate; \partial{#}::PartialDerivative; ex:= (\sin(r)**2 + \cos(r)**2) A_{m} \partial_{r}{r} - A_{m} + \int{r**2}{r} B_{m}; map_sympy(_, "simplify"); {r,t}::Coordinate; {\mu,\nu}::Indices(values={r,t}); ex:= \partial_{\mu}{ A^{\mu \nu} }; rl:= A^{t t} -> t \sin(r)**2, A^{r r} -> \int{\cos{r}**2}{r}; evaluate(ex, rl); from sympy import * x,y=var('x,y') i = Integral(sin(x),(x,0,2)); i.doit();