try working through the math using sympy.