'Add two polynomials ``f`` and ``g``.
Examples
>>> from sympy import Poly
>>> from sympy.abc import x
>>> Poly(x**2 + 1, x).add(Poly(x - 2, x))
Poly(x**2 + x - 1, x, domain=\'ZZ\')
>>> Poly(x**2 + 1, x) + Poly(x - 2, x)
Poly(x**2 + x - 1, x, domain=\'ZZ\')'

def add(f, g):

    g = sympify(g)
    if (not g.is_Poly):
        return f.add_ground(g)
    (_, per, F, G) = f._unify(g)
    if hasattr(f.rep, 'add'):
        result = F.add(G)
    else:
        raise OperationNotSupported(f, 'add')
    return per(result)
