SciPy Root Finding: root, root_scalar and brentq
SciPy gives you three doors into root finding, and picking the wrong one is why scipy.optimize.root feels awkward for simple problems. Most people land here with a single equation, so it’s one of the first two they want. I reach for brentq unless there’s a reason not to. Everything that follows was run on SciPy … Read more >>