Incorporate C code for Brent_fmin (from R)