Module ImportFrom alias alias alias Import alias ImportFrom alias ImportFrom alias alias alias Assign NameStore Num Assign NameStore Num Assign NameStore BinOpMult Num AttributeLoad Call NameLoad NameLoad attr Assign NameStore ListLoad Str Str Str Str Str Assign NameStore Str Assign NameStore Str Assign NameStore Str Assign NameStore Dict Num Num Num NameLoad NameLoad NameLoad ClassDef bases NameLoad body Expr Str FunctionDef arguments args NameParam NameParam NameParam NameParam NameParam defaults body Assign AttributeStore NameLoad attr NameLoad Assign AttributeStore NameLoad attr NameLoad Assign AttributeStore NameLoad attr NameLoad Assign AttributeStore NameLoad attr CompareEq NameLoad Num TryExcept body Assign AttributeStore NameLoad attr SubscriptLoad NameLoad Index NameLoad handlers ExceptHandler type NameLoad body Assign AttributeStore NameLoad attr BinOpMod Str TupleLoad NameLoad decorator_list FunctionDef arguments args NameParam defaults body Assign NameStore ListLoad Str Str Str Str Str Assign NameStore BinOpAdd Call NameLoad Call NameLoad NameLoad NameLoad Num Return Call AttributeLoad Str attr ListComp BinOpAdd BinOpAdd Call AttributeLoad NameLoad attr NameLoad Str Call NameLoad Call NameLoad NameLoad NameLoad comprehension NameStore NameLoad decorator_list decorator_list FunctionDef arguments args NameParam NameParam defaults body If NameLoad body Assign TupleStore NameStore NameStore NameStore NameStore NameLoad Assign NameStore Call NameLoad keyword NameLoad keyword NameLoad keyword NameLoad keyword NameLoad Return TupleLoad NameLoad NameLoad orelse Return NameLoad decorator_list FunctionDef arguments args NameParam NameParam NameParam NameParam NameParam NameParam NameParam defaults NameLoad TupleLoad Num Num NameLoad body Expr Str If CompareLtE NameLoad Num body Raise Call NameLoad BinOpMod Str NameLoad If CompareLt NameLoad Num body Raise Call NameLoad Str If CompareIsNot NameLoad NameLoad body Assign NameStore BinOpMult Num NameLoad Assign NameStore Num For NameStore Call NameLoad NameLoad body Assign NameStore BinOpAdd TupleLoad NameLoad NameLoad Assign NameStore Call NameLoad NameLoad If CompareEq NameLoad Num body Assign NameStore Str Expr Call AttributeLoad NameLoad attr NameLoad NameLoad Return NameLoad Assign NameStore Call NameLoad NameLoad If CompareIsNot NameLoad NameLoad body Assign NameStore Call NameLoad NameLoad If CompareEq NameLoad Num body Assign NameStore BinOpSub NameLoad BinOpDiv NameLoad NameLoad orelse Assign NameStore BinOpSub BinOpPow NameLoad Num BinOpMult BinOpMult Num NameLoad NameLoad If CompareLt NameLoad Num body Assign NameStore BinOpSub NameLoad BinOpDiv NameLoad NameLoad orelse Assign NameStore BinOpSub NameLoad BinOpDiv BinOpMult Num NameLoad BinOpAdd NameLoad BinOpMult Call NameLoad NameLoad Call NameLoad NameLoad If CompareLt Call NameLoad BinOpSub NameLoad NameLoad NameLoad body Return NameLoad Assign NameStore NameLoad orelse Assign NameStore NameLoad If CompareGtE NameLoad Num body Assign NameStore BinOpAdd BinOpMult NameLoad BinOpAdd Num Num Num orelse Assign NameStore BinOpSub BinOpMult NameLoad BinOpAdd Num Num Num Assign NameStore Call NameLoad BinOpAdd TupleLoad NameLoad NameLoad Assign NameStore Call NameLoad BinOpAdd TupleLoad NameLoad NameLoad For NameStore Call NameLoad NameLoad body If CompareEq NameLoad NameLoad body If CompareNotEq NameLoad NameLoad body Assign NameStore BinOpMod Str BinOpSub NameLoad NameLoad Expr Call AttributeLoad NameLoad attr NameLoad NameLoad Return BinOpDiv BinOpAdd NameLoad NameLoad Num orelse Assign NameStore BinOpSub NameLoad BinOpDiv BinOpMult NameLoad BinOpSub NameLoad NameLoad BinOpSub NameLoad NameLoad If CompareLt Call NameLoad BinOpSub NameLoad NameLoad NameLoad body Return NameLoad Assign NameStore NameLoad Assign NameStore NameLoad Assign NameStore NameLoad Assign NameStore Call NameLoad BinOpAdd TupleLoad NameLoad NameLoad Assign NameStore BinOpMod Str TupleLoad NameLoad NameLoad Raise Call NameLoad NameLoad decorator_list FunctionDef arguments args NameParam NameParam NameParam NameParam NameParam NameParam NameParam NameParam NameParam defaults TupleLoad NameLoad NameLoad NameLoad NameLoad NameLoad body Expr Str If UnaryOpNot Call NameLoad NameLoad NameLoad body Assign NameStore TupleLoad NameLoad If CompareLtE NameLoad Num body Raise Call NameLoad BinOpMod Str NameLoad If CompareLt NameLoad NameLoad body Raise Call NameLoad BinOpMod Str TupleLoad NameLoad NameLoad Assign NameStore Call AttributeLoad NameLoad attr NameLoad NameLoad NameLoad NameLoad NameLoad NameLoad NameLoad NameLoad NameLoad Return Call NameLoad NameLoad NameLoad decorator_list FunctionDef arguments args NameParam NameParam NameParam NameParam NameParam NameParam NameParam NameParam NameParam defaults TupleLoad NameLoad NameLoad NameLoad NameLoad NameLoad body Expr Str If UnaryOpNot Call NameLoad NameLoad NameLoad body Assign NameStore TupleLoad NameLoad If CompareLtE NameLoad Num body Raise Call NameLoad BinOpMod Str NameLoad If CompareLt NameLoad NameLoad body Raise Call NameLoad BinOpMod Str TupleLoad NameLoad NameLoad Assign NameStore Call AttributeLoad NameLoad attr NameLoad NameLoad NameLoad NameLoad NameLoad NameLoad NameLoad NameLoad NameLoad Return Call NameLoad NameLoad NameLoad decorator_list FunctionDef arguments args NameParam NameParam NameParam NameParam NameParam NameParam NameParam NameParam NameParam defaults TupleLoad NameLoad NameLoad NameLoad NameLoad NameLoad body Expr Str If UnaryOpNot Call NameLoad NameLoad NameLoad body Assign NameStore TupleLoad NameLoad If CompareLtE NameLoad Num body Raise Call NameLoad BinOpMod Str NameLoad If CompareLt NameLoad NameLoad body Raise Call NameLoad BinOpMod Str TupleLoad NameLoad NameLoad Assign NameStore Call AttributeLoad NameLoad attr NameLoad NameLoad NameLoad NameLoad NameLoad NameLoad NameLoad NameLoad NameLoad Return Call NameLoad NameLoad NameLoad decorator_list FunctionDef arguments args NameParam NameParam NameParam NameParam NameParam NameParam NameParam NameParam NameParam defaults TupleLoad NameLoad NameLoad NameLoad NameLoad NameLoad body Expr Str If UnaryOpNot Call NameLoad NameLoad NameLoad body Assign NameStore TupleLoad NameLoad If CompareLtE NameLoad Num body Raise Call NameLoad BinOpMod Str NameLoad If CompareLt NameLoad NameLoad body Raise Call NameLoad BinOpMod Str TupleLoad NameLoad NameLoad Assign NameStore Call AttributeLoad NameLoad attr NameLoad NameLoad NameLoad NameLoad NameLoad NameLoad NameLoad NameLoad NameLoad Return Call NameLoad NameLoad NameLoad decorator_list
N/A __future__ division print_function absolute_import N/A warnings N/A _zeros numpy finfo sign sqrt N/A _iter 100 N/A _xtol 2e-12 N/A _rtol N/A 4 N/A N/A finfo float eps N/A __all__ N/A newton bisect ridder brentq brenth N/A CONVERGED converged N/A SIGNERR sign error N/A CONVERR convergence error N/A flag_map N/A 0 -1 -2 CONVERGED SIGNERR CONVERR RootResults N/A object N/A N/A  Represents the root finding result.
    Attributes
    ----------
    root : float
        Estimated root location.
    iterations : int
        Number of iterations needed to find the root.
    function_calls : int
        Number of times the function was called.
    converged : bool
        True if the routine converged.
    flag : str
        Description of the cause of termination.
     __init__ N/A N/A self root iterations function_calls flag N/A N/A N/A N/A self root root N/A N/A self iterations iterations N/A N/A self function_calls function_calls N/A N/A self converged N/A flag 0 N/A N/A N/A N/A self flag N/A flag_map N/A flag N/A N/A N/A KeyError N/A N/A N/A self flag N/A unknown error %d N/A flag N/A __repr__ N/A N/A self N/A N/A N/A attrs N/A converged flag function_calls iterations root N/A m N/A N/A max N/A map len attrs 1 N/A N/A N/A join N/A N/A N/A N/A N/A a rjust m :  N/A repr N/A getattr self a N/A a attrs N/A N/A results_c N/A N/A full_output r N/A N/A N/A full_output N/A N/A N/A x funcalls iterations flag r N/A results N/A RootResults root x iterations iterations function_calls funcalls flag flag N/A N/A x results N/A N/A r N/A newton N/A N/A func x0 fprime args tol maxiter fprime2 N/A None N/A 1.48e-08 50 None N/A N/A 
    Find a zero using the Newton-Raphson or secant method.

    Find a zero of the function `func` given a nearby starting point `x0`.
    The Newton-Raphson method is used if the derivative `fprime` of `func`
    is provided, otherwise the secant method is used.  If the second order
    derivate `fprime2` of `func` is provided, parabolic Halley's method
    is used.

    Parameters
    ----------
    func : function
        The function whose zero is wanted. It must be a function of a
        single variable of the form f(x,a,b,c...), where a,b,c... are extra
        arguments that can be passed in the `args` parameter.
    x0 : float
        An initial estimate of the zero that should be somewhere near the
        actual zero.
    fprime : function, optional
        The derivative of the function when available and convenient. If it
        is None (default), then the secant method is used.
    args : tuple, optional
        Extra arguments to be used in the function call.
    tol : float, optional
        The allowable error of the zero value.
    maxiter : int, optional
        Maximum number of iterations.
    fprime2 : function, optional
        The second order derivative of the function when available and
        convenient. If it is None (default), then the normal Newton-Raphson
        or the secant method is used. If it is given, parabolic Halley's
        method is used.

    Returns
    -------
    zero : float
        Estimated location where function is zero.

    See Also
    --------
    brentq, brenth, ridder, bisect
    fsolve : find zeroes in n dimensions.

    Notes
    -----
    The convergence rate of the Newton-Raphson method is quadratic,
    the Halley method is cubic, and the secant method is
    sub-quadratic.  This means that if the function is well behaved
    the actual error in the estimated zero is approximately the square
    (cube for Halley) of the requested tolerance up to roundoff
    error. However, the stopping criterion used here is the step size
    and there is no guarantee that a zero has been found. Consequently
    the result should be verified. Safer algorithms are brentq,
    brenth, ridder, and bisect, but they all require that the root
    first be bracketed in an interval where the function changes
    sign. The brentq algorithm is recommended for general use in one
    dimensional problems when such an interval has been found.

     N/A N/A tol 0 N/A N/A N/A ValueError N/A tol too small (%g <= 0) tol N/A N/A maxiter 1 N/A N/A N/A ValueError maxiter must be greater than 0 N/A N/A fprime None N/A N/A p0 N/A 1.0 x0 N/A fder2 0 N/A iter N/A range maxiter N/A N/A myargs N/A N/A p0 args N/A fder N/A fprime myargs N/A N/A fder 0 N/A N/A msg derivative was zero. N/A N/A N/A warnings warn msg RuntimeWarning N/A p0 N/A fval N/A func myargs N/A N/A fprime2 None N/A N/A fder2 N/A fprime2 myargs N/A N/A fder2 0 N/A N/A p N/A p0 N/A fval fder N/A N/A discr N/A N/A fder 2 N/A N/A 2 fval fder2 N/A N/A discr 0 N/A N/A p N/A p0 N/A fder fder2 N/A N/A p N/A p0 N/A N/A 2 fval N/A fder N/A N/A sign fder N/A sqrt discr N/A N/A N/A abs N/A p p0 tol N/A N/A p N/A p0 p N/A N/A p0 x0 N/A N/A x0 0 N/A N/A p1 N/A N/A x0 N/A 1 0.0001 0.0001 N/A N/A p1 N/A N/A x0 N/A 1 0.0001 0.0001 N/A q0 N/A func N/A N/A p0 args N/A q1 N/A func N/A N/A p1 args N/A iter N/A range maxiter N/A N/A N/A q1 q0 N/A N/A N/A p1 p0 N/A N/A msg N/A Tolerance of %s reached N/A p1 p0 N/A N/A N/A warnings warn msg RuntimeWarning N/A N/A N/A p1 p0 2.0 N/A N/A p N/A p1 N/A N/A q1 N/A p1 p0 N/A q1 q0 N/A N/A N/A abs N/A p p1 tol N/A N/A p N/A p0 p1 N/A q0 q1 N/A p1 p N/A q1 N/A func N/A N/A p1 args N/A msg N/A Failed to converge after %d iterations, value is %s N/A maxiter p N/A N/A RuntimeError msg N/A bisect N/A N/A f a b args xtol rtol maxiter full_output disp N/A N/A _xtol _rtol _iter False True N/A N/A 
    Find root of a function within an interval.

    Basic bisection routine to find a zero of the function `f` between the
    arguments `a` and `b`. `f(a)` and `f(b)` cannot have the same signs.
    Slow but sure.

    Parameters
    ----------
    f : function
        Python function returning a number.  `f` must be continuous, and
        f(a) and f(b) must have opposite signs.
    a : number
        One end of the bracketing interval [a,b].
    b : number
        The other end of the bracketing interval [a,b].
    xtol : number, optional
        The computed root ``x0`` will satisfy ``np.allclose(x, x0,
        atol=xtol, rtol=rtol)``, where ``x`` is the exact root. The
        parameter must be nonnegative.
    rtol : number, optional
        The computed root ``x0`` will satisfy ``np.allclose(x, x0,
        atol=xtol, rtol=rtol)``, where ``x`` is the exact root. The
        parameter cannot be smaller than its default value of
        ``4*np.finfo(float).eps``.
    maxiter : number, optional
        if convergence is not achieved in `maxiter` iterations, an error is
        raised.  Must be >= 0.
    args : tuple, optional
        containing extra arguments for the function `f`.
        `f` is called by ``apply(f, (x)+args)``.
    full_output : bool, optional
        If `full_output` is False, the root is returned.  If `full_output` is
        True, the return value is ``(x, r)``, where x is the root, and r is
        a `RootResults` object.
    disp : bool, optional
        If True, raise RuntimeError if the algorithm didn't converge.

    Returns
    -------
    x0 : float
        Zero of `f` between `a` and `b`.
    r : RootResults (present if ``full_output = True``)
        Object containing information about the convergence.  In particular,
        ``r.converged`` is True if the routine converged.

    See Also
    --------
    brentq, brenth, bisect, newton
    fixed_point : scalar fixed-point finder
    fsolve : n-dimensional root-finding

     N/A N/A N/A isinstance args tuple N/A N/A args N/A args N/A N/A xtol 0 N/A N/A N/A ValueError N/A xtol too small (%g <= 0) xtol N/A N/A rtol _rtol N/A N/A N/A ValueError N/A rtol too small (%g < %g) N/A rtol _rtol N/A r N/A N/A _zeros _bisect f a b xtol rtol maxiter args full_output disp N/A N/A results_c full_output r N/A ridder N/A N/A f a b args xtol rtol maxiter full_output disp N/A N/A _xtol _rtol _iter False True N/A N/A 
    Find a root of a function in an interval.

    Parameters
    ----------
    f : function
        Python function returning a number.  f must be continuous, and f(a) and
        f(b) must have opposite signs.
    a : number
        One end of the bracketing interval [a,b].
    b : number
        The other end of the bracketing interval [a,b].
    xtol : number, optional
        The computed root ``x0`` will satisfy ``np.allclose(x, x0,
        atol=xtol, rtol=rtol)``, where ``x`` is the exact root. The
        parameter must be nonnegative.
    rtol : number, optional
        The computed root ``x0`` will satisfy ``np.allclose(x, x0,
        atol=xtol, rtol=rtol)``, where ``x`` is the exact root. The
        parameter cannot be smaller than its default value of
        ``4*np.finfo(float).eps``.
    maxiter : number, optional
        if convergence is not achieved in maxiter iterations, an error is
        raised.  Must be >= 0.
    args : tuple, optional
        containing extra arguments for the function `f`.
        `f` is called by ``apply(f, (x)+args)``.
    full_output : bool, optional
        If `full_output` is False, the root is returned.  If `full_output` is
        True, the return value is ``(x, r)``, where `x` is the root, and `r` is
        a RootResults object.
    disp : bool, optional
        If True, raise RuntimeError if the algorithm didn't converge.

    Returns
    -------
    x0 : float
        Zero of `f` between `a` and `b`.
    r : RootResults (present if ``full_output = True``)
        Object containing information about the convergence.
        In particular, ``r.converged`` is True if the routine converged.

    See Also
    --------
    brentq, brenth, bisect, newton : one-dimensional root-finding
    fixed_point : scalar fixed-point finder

    Notes
    -----
    Uses [Ridders1979]_ method to find a zero of the function `f` between the
    arguments `a` and `b`. Ridders' method is faster than bisection, but not
    generally as fast as the Brent rountines. [Ridders1979]_ provides the
    classic description and source of the algorithm. A description can also be
    found in any recent edition of Numerical Recipes.

    The routine used here diverges slightly from standard presentations in
    order to be a bit more careful of tolerance.

    References
    ----------
    .. [Ridders1979]
       Ridders, C. F. J. "A New Algorithm for Computing a
       Single Root of a Real Continuous Function."
       IEEE Trans. Circuits Systems 26, 979-980, 1979.

     N/A N/A N/A isinstance args tuple N/A N/A args N/A args N/A N/A xtol 0 N/A N/A N/A ValueError N/A xtol too small (%g <= 0) xtol N/A N/A rtol _rtol N/A N/A N/A ValueError N/A rtol too small (%g < %g) N/A rtol _rtol N/A r N/A N/A _zeros _ridder f a b xtol rtol maxiter args full_output disp N/A N/A results_c full_output r N/A brentq N/A N/A f a b args xtol rtol maxiter full_output disp N/A N/A _xtol _rtol _iter False True N/A N/A 
    Find a root of a function in a bracketing interval using Brent's method.

    Uses the classic Brent's method to find a zero of the function `f` on
    the sign changing interval [a , b].  Generally considered the best of the
    rootfinding routines here.  It is a safe version of the secant method that
    uses inverse quadratic extrapolation.  Brent's method combines root
    bracketing, interval bisection, and inverse quadratic interpolation.  It is
    sometimes known as the van Wijngaarden-Dekker-Brent method.  Brent (1973)
    claims convergence is guaranteed for functions computable within [a,b].

    [Brent1973]_ provides the classic description of the algorithm.  Another
    description can be found in a recent edition of Numerical Recipes, including
    [PressEtal1992]_.  Another description is at
    http://mathworld.wolfram.com/BrentsMethod.html.  It should be easy to
    understand the algorithm just by reading our code.  Our code diverges a bit
    from standard presentations: we choose a different formula for the
    extrapolation step.

    Parameters
    ----------
    f : function
        Python function returning a number.  The function :math:`f`
        must be continuous, and :math:`f(a)` and :math:`f(b)` must
        have opposite signs.
    a : number
        One end of the bracketing interval :math:`[a, b]`.
    b : number
        The other end of the bracketing interval :math:`[a, b]`.
    xtol : number, optional
        The computed root ``x0`` will satisfy ``np.allclose(x, x0,
        atol=xtol, rtol=rtol)``, where ``x`` is the exact root. The
        parameter must be nonnegative. For nice functions, Brent's
        method will often satisfy the above condition will ``xtol/2``
        and ``rtol/2``. [Brent1973]_
    rtol : number, optional
        The computed root ``x0`` will satisfy ``np.allclose(x, x0,
        atol=xtol, rtol=rtol)``, where ``x`` is the exact root. The
        parameter cannot be smaller than its default value of
        ``4*np.finfo(float).eps``. For nice functions, Brent's
        method will often satisfy the above condition will ``xtol/2``
        and ``rtol/2``. [Brent1973]_
    maxiter : number, optional
        if convergence is not achieved in maxiter iterations, an error is
        raised.  Must be >= 0.
    args : tuple, optional
        containing extra arguments for the function `f`.
        `f` is called by ``apply(f, (x)+args)``.
    full_output : bool, optional
        If `full_output` is False, the root is returned.  If `full_output` is
        True, the return value is ``(x, r)``, where `x` is the root, and `r` is
        a RootResults object.
    disp : bool, optional
        If True, raise RuntimeError if the algorithm didn't converge.

    Returns
    -------
    x0 : float
        Zero of `f` between `a` and `b`.
    r : RootResults (present if ``full_output = True``)
        Object containing information about the convergence.  In particular,
        ``r.converged`` is True if the routine converged.

    See Also
    --------
    multivariate local optimizers
      `fmin`, `fmin_powell`, `fmin_cg`, `fmin_bfgs`, `fmin_ncg`
    nonlinear least squares minimizer
      `leastsq`
    constrained multivariate optimizers
      `fmin_l_bfgs_b`, `fmin_tnc`, `fmin_cobyla`
    global optimizers
      `basinhopping`, `brute`, `differential_evolution`
    local scalar minimizers
      `fminbound`, `brent`, `golden`, `bracket`
    n-dimensional root-finding
      `fsolve`
    one-dimensional root-finding
      `brentq`, `brenth`, `ridder`, `bisect`, `newton`
    scalar fixed-point finder
      `fixed_point`

    Notes
    -----
    `f` must be continuous.  f(a) and f(b) must have opposite signs.


    References
    ----------
    .. [Brent1973]
       Brent, R. P.,
       *Algorithms for Minimization Without Derivatives*.
       Englewood Cliffs, NJ: Prentice-Hall, 1973. Ch. 3-4.

    .. [PressEtal1992]
       Press, W. H.; Flannery, B. P.; Teukolsky, S. A.; and Vetterling, W. T.
       *Numerical Recipes in FORTRAN: The Art of Scientific Computing*, 2nd ed.
       Cambridge, England: Cambridge University Press, pp. 352-355, 1992.
       Section 9.3:  "Van Wijngaarden-Dekker-Brent Method."

     N/A N/A N/A isinstance args tuple N/A N/A args N/A args N/A N/A xtol 0 N/A N/A N/A ValueError N/A xtol too small (%g <= 0) xtol N/A N/A rtol _rtol N/A N/A N/A ValueError N/A rtol too small (%g < %g) N/A rtol _rtol N/A r N/A N/A _zeros _brentq f a b xtol rtol maxiter args full_output disp N/A N/A results_c full_output r N/A brenth N/A N/A f a b args xtol rtol maxiter full_output disp N/A N/A _xtol _rtol _iter False True N/A N/A Find root of f in [a,b].

    A variation on the classic Brent routine to find a zero of the function f
    between the arguments a and b that uses hyperbolic extrapolation instead of
    inverse quadratic extrapolation. There was a paper back in the 1980's ...
    f(a) and f(b) cannot have the same signs. Generally on a par with the
    brent routine, but not as heavily tested.  It is a safe version of the
    secant method that uses hyperbolic extrapolation. The version here is by
    Chuck Harris.

    Parameters
    ----------
    f : function
        Python function returning a number.  f must be continuous, and f(a) and
        f(b) must have opposite signs.
    a : number
        One end of the bracketing interval [a,b].
    b : number
        The other end of the bracketing interval [a,b].
    xtol : number, optional
        The computed root ``x0`` will satisfy ``np.allclose(x, x0,
        atol=xtol, rtol=rtol)``, where ``x`` is the exact root. The
        parameter must be nonnegative. As with `brentq`, for nice
        functions the method will often satisfy the above condition
        will ``xtol/2`` and ``rtol/2``.
    rtol : number, optional
        The computed root ``x0`` will satisfy ``np.allclose(x, x0,
        atol=xtol, rtol=rtol)``, where ``x`` is the exact root. The
        parameter cannot be smaller than its default value of
        ``4*np.finfo(float).eps``. As with `brentq`, for nice functions
        the method will often satisfy the above condition will
        ``xtol/2`` and ``rtol/2``.
    maxiter : number, optional
        if convergence is not achieved in maxiter iterations, an error is
        raised.  Must be >= 0.
    args : tuple, optional
        containing extra arguments for the function `f`.
        `f` is called by ``apply(f, (x)+args)``.
    full_output : bool, optional
        If `full_output` is False, the root is returned.  If `full_output` is
        True, the return value is ``(x, r)``, where `x` is the root, and `r` is
        a RootResults object.
    disp : bool, optional
        If True, raise RuntimeError if the algorithm didn't converge.

    Returns
    -------
    x0 : float
        Zero of `f` between `a` and `b`.
    r : RootResults (present if ``full_output = True``)
        Object containing information about the convergence.  In particular,
        ``r.converged`` is True if the routine converged.

    See Also
    --------
    fmin, fmin_powell, fmin_cg,
           fmin_bfgs, fmin_ncg : multivariate local optimizers

    leastsq : nonlinear least squares minimizer

    fmin_l_bfgs_b, fmin_tnc, fmin_cobyla : constrained multivariate optimizers

    basinhopping, differential_evolution, brute : global optimizers

    fminbound, brent, golden, bracket : local scalar minimizers

    fsolve : n-dimensional root-finding

    brentq, brenth, ridder, bisect, newton : one-dimensional root-finding

    fixed_point : scalar fixed-point finder

     N/A N/A N/A isinstance args tuple N/A N/A args N/A args N/A N/A xtol 0 N/A N/A N/A ValueError N/A xtol too small (%g <= 0) xtol N/A N/A rtol _rtol N/A N/A N/A ValueError N/A rtol too small (%g < %g) N/A rtol _rtol N/A r N/A N/A _zeros _brenth f a b xtol rtol maxiter args full_output disp N/A N/A results_c full_output r N/A