Is there some off-the-shelf C/C++ library to solve the following problem:
Software Recommendations Stack Exchange is a question and answer site for people seeking specific software recommendations. It only takes a minute to sign up.Sign up to join this community
I'm not sure about the particular formula you've referred to, but you have an extremely wide variety of libraries to choose from for regression, optimization and other numerical solutions: http://en.wikipedia.org/wiki/List_of_numerical_libraries (see C, C++ and multi-language sections). In addition, take a look at IMHO very interesting Accord.NET framework, which offers this functionality and much more. Hope this helps.