Bob Swart is a professional software developer and free-lance technical author using Borland Pascal, C++, and Delphi. In his spare time he likes to watch video tapes of Star Trek The Next Generation with his one-year-old son Erik Mark Pascal. He can be reached via e-mail at bob@bolesian.nl.
This book's complete title is rather long: Scientific and Engineering C++: An Introduction with Advanced Techniques and Examples. The book's contents are rather heavy too, being specifically targetted to scientists and engineers who use FORTRAN or C and want to use C++. The authors feel that while Fortran or C are adequate for small programs of strictly numerical content, larger and non-numeric programs written in these languages become too expensive to understand, revise, or improve. Thus, the book's purpose is to teach how to use C++ and object-oriented programming (OOP) to produce better quality programs especially scientific and engineering programs.
This book assumes that you have at least some programming experience in either FORTRAN or C. (Barring that, you will need experience in some procedural programming language to get any use out of this book). The first few chapters focus on the new things C++ offers compared to FORTRAN and C. From there, it quickly moves beyond C++ syntax and rules to more interesting and important territory: object-oriented programming in C++. The authors state that C++ and OOP will lead to better science programs that are correct, readable, modifiable, affordable, and efficient. They concede, however, that OOPing in C++ is not a panacea. Such programming, while possibly easier, requires the same kind of creative effort and persistence as other endeavors in science and engineering.
The first part of the book about 220 pages is a good C++ tutorial using simple mathematical and engineering examples. One such example is finding the solution of partial differential equations by the finite element method. This part of the book covers just about every novel aspect of C++, from function overloading to templates, exceptions, and multiple inheritance. Of course, the market is already crowded with books that offer a comparable introduction to C++. The rest of the book is what makes it worthwhile, and possibly more interesting than those other books.
The rest of the book (Parts 2 and 3) builds on the foundation laid in Part 1 to introduce the OOP concept. Understanding the examples here requires quite a bit of scientific and engineering background. The examples include class wrappers for LAPACK (a linear algebra library written in FORTRAN), classes for abstract algebra and dimensional analysis, and automatic differentiation and data analysis via nonlinear least squares using the singular value decomposition. Readers who aren't into these subjects, will have some problems understanding the code, as well; the authors use these same examples to go deeper into pure programming topics, such as expressing common behavior, common implementation, and common structure.
The third part of the book spends a lot of time describing how to use existing FORTRAN and C subroutine libraries, such as LAPACK, to implement C++ class wrappers matching the design of the original library. The final chapter of the book covers data modeling in C++ and uses just about every technique learned in the previous chapters. This chapter shows typical scientific and engineering programming problems in C++ from the authors' own experience.
The book includes a reference list, a large subject index, and an index of source files used in the book. These source files do not come with the book (no bundled code disk), but you can get them from the Internet via anonymous tip from software. watmore.ibm.com in directory /pub/SciEng.
Target Audience
Are you heavily involved in science or engineering projects? Do you also program in FORTRAN or C, and want to move to C++? Then you probably will find this book of great interest. You might also enjoy it if you're just interested in advanced examples of scientific and engineering programming. If you don't fit either of these categories, you might want to pass on this book it gets rather heavy after its seemingly benign introduction to C++.
About the Authors
John J. Barton, and Lee R. Nackman are research staff members at the IBM Thomas J. Watson Research Center in Hawthorne, NY, USA. The authors are open to your comments, and can be reached by e-mail at C++SciEn@aw.com.Title: Scientific and Engineering C++
Authors: John Barton & Lee Nackman
Publisher: Addison Wesley, 1994
Pages: 675, hardcover (no disk; source code available via ftp-site)
Price: US$54.95
ISBN: 0-201-53393-6