

def test_symbol_expand():
    x = Symbol('x')
    y = Symbol('y')
    f = ((x ** 4) * (y ** 4))
    assert (f == ((x ** 4) * (y ** 4)))
    assert (f == f.expand())
    g = ((x * y) ** 4)
    assert (g == f)
    assert (g.expand() == f)
    assert (g.expand() == g.expand().expand())

dataset/ETHPy150Open sympy/sympy/sympy/core/tests/test_eval.py test_symbol_expand/original