I have the following minimal example:
import sympy as sp
eq = sp.S("-p**2*(3*p**2 - 9*p + 7)/(p**2 - 3*p + 3) + q")
# This eventually terminates after a few seconds
sp.solve(eq, dict=True)
# Result: [{q: p**2*(3*p**2 - 9*p + 7)/(p**2 - 3*p + 3)}]
# If I instead write it like this
sp.solve([eq], dict=True)
# it does not terminate in reasonable time (even after hours I do not get a result).
What is the reason for this behaviour?
I would expect that both solve calls should terminate in roughly the same amount of time, as the list only contains just a single element which is identical to the non-iterable solve() call