(f, *gens, **args)
Compute Sturm sequence of ``f``.

    Examples
    ========

    >>> from sympy import sturm
    >>> from sympy.abc import x

    >>> sturm(x**3 - 2*x**2 + x - 3)
    [x**3 - 2*x**2 + x - 3, 3*x**2 - 4*x + 1, 2*x/9 + 25/9, -2079/4]
Compute Sturm sequence of ``f``.
Compute Sturm sequence of f .
def sturm(f, *gens, **args):
    """
    Compute Sturm sequence of ``f``.

    Examples
    ========

    >>> from sympy import sturm
    >>> from sympy.abc import x

    >>> sturm(x**3 - 2*x**2 + x - 3)
    [x**3 - 2*x**2 + x - 3, 3*x**2 - 4*x + 1, 2*x/9 + 25/9, -2079/4]

    """
    options.allowed_flags(args, ['auto', 'polys'])

    try:
        F, opt = poly_from_expr(f, *gens, **args)
    except PolificationFailed as exc:
        raise ComputationFailed('sturm', 1, exc)

    result = F.sturm(auto=opt.auto)

    if not opt.polys:
        return [r.as_expr() for r in result]
    else:
        return result
def sturm ( f , * gens , * * args ) : options . allowed_flags ( args , [ 'auto' , 'polys' ] ) try : F , opt = poly_from_expr ( f , * gens , * * args ) except PolificationFailed as exc : raise ComputationFailed ( 'sturm' , 1 , exc ) result = F . sturm ( auto = opt . auto ) if not opt . polys : return [ r . as_expr ( ) for r in result ] else : return result