Book for Numerical Analysis with C++

I am looking for a book in Numerical Analysis, with algorithms implemented in C++. Basically, I am looking for the usual stuff: Newton's method, numerical integration, numerical solutions of differential equations, and so on. I would like to see how C++ can be used for doing numerical analysis, so taking advantage of the inheritance mechanism and the object-oriented programming style.

There are many books of Numerical Analysis which implement their algorithms in Matlab, such as for example this one: http://www.springer.com/gp/book/9783540346586 which is quite good.

Now, I am looking for something similar, but where C++ is used instead of Matlab or Python.

What is the problem? Apparently there are some, but they are quite old, like this one: https://www.amazon.com/Introduction-Numerical-Methods-C/dp/0198506937 but the version of the langauge used is almost obsolete, as its first edition is from 1999. So I am asking you if you know some similar book, possibly well written, which uses C++ as it is today.

I should add that I checked the book https://www.amazon.com/Scientific-Computing-Undergraduate-Computer-Science/dp/1447127358/ref=pd_sbs_14_1?_encoding=UTF8&pd_rd_i=1447127358&pd_rd_r=PV5HVAQ38QVEBC2CB951&pd_rd_w=eehAa&pd_rd_wg=eQQz2&psc=1&refRID=PV5HVAQ38QVEBC2CB951 but I hoestly came to hate it. Unclear and confusing, I totally agree with the 1-star review and possibly worse.

So do you have any suggestion? Thank you very much.
oh goodness ... numerical recipes in c is a classic... but the code is full of third rate hacks to get the job done, its extremely poorly written code even for its own era, nevermind today's approaches. (And if I am saying that, you know its bad!)

I don't know of any written in the modern fashion. Math is the one place object oriented code kind of fall apart to me... I prefer loose functions, in a namespace. The only object oriented math code I used was for linear algebra, and that was just to overload operators for the container really to make the code look like the math it represented.

But I didn't handle generic form equations. For that, you need a class, if you want more than say a vector of [0] = 0th power coefficient, [1] = 1st power coefficient, ... style storage. Ive done it this way, but never anything fancier.

Do you have a class in mind, and what it represents?

Last edited on
Sorry, that is not a book in numerical analysis.
Numerical Recipes: the Art of Scientific Computing (3rd ed., 2007) - expensive book, though: better with access to a University library. Note that it was written before c++11 and uses some "in-house" c++. Very strong on the mathematical methods.
Last edited on
It is not exactly what I am looking for. To repeat it: ". I would like to see how C++ can be used for doing numerical analysis, so taking advantage of the inheritance mechanism and the object-oriented programming style. Apparently there are some, but they are quite old, like this one: https://www.amazon.com/Introduction-Numerical-Methods-C/dp/0198506937 but the version of the langauge used is almost obsolete, as its first edition is from 1999. So I am asking you if you know some similar book, possibly well written, which uses C++ as it is today. "
Topic archived. No new replies allowed.