answered 1 year ago
Also:
from sympy import Integral from sympy.abc import x Integral(1/x, (x, -1, 1)).principal_value()