With sympy, I am aware you can you do something like this:
In [37]: sqrt(8) / sqrt(27) Out[37]: 2*sqrt(6)/9 In [38]: pprint(sqrt(8) / sqrt(27)) 2⋅√6 ──── 9 There is a complex number I would like to represent in the same "symbolic" manner:
In [39]: z = complex(1,2) The length:
In [42]: Abs(z) Out[42]: 1.73205080756888 Now I would like to represent that number as :
In [46]: pprint(sqrt(3)) √3