Python: Exponent-Characters shown in string -
i'm looking way, generate string, contains example "x³". if don't know exponent (3), , want add string, this: "x^"+"3" doesn't work (of course). there way, add numbers, or possibly characters exponent string python?
you might want @ sympy:
import sympy sympy import init_printing init_printing() sympy.pprint(sympy.exp("x^3")) ⎛ 3⎞ ⎝x ⎠ ℯ sympy.pprint(sympy.exp("x3")) x₃ ℯ
Comments
Post a Comment