Yesterday I had problems with another boost functions but luckily you guys helped me to solve them. Today I would need to know how to use bisection function properly.
Note that bisect also supports lambdas:
bisect
using boost::math::tools::bisect; auto root = bisect ( [](double x){return x;}, -1.0, 1.0, [](double l, double r){return abs(l-r) < 1e-8;} );