CXSC  A C++ Class Library for Extended Scientific Computing
2.5.4

The speed of digital Computers is ever increasing. While the emphasis in computing was traditionally on speed, more emphasis can now be put on accuracy and reliability of results. Numerical mathematics has devised algorithms which deliver highly accurate and automatically verified results by applying mathematical fixedpoint theorems. This means that these computation carry their own accuracy control. However, their implementation requires suitable arithmetic support and powerful programming tools which are not generally available.
Different hardware solutions are available for Personal Computers, Workstations, Mainframes and Super Computers. In particular a vector arithmetic coprocessor for the PC has been developed in VLSItechnology. Language support is available on the basis of FORTRAN, PASCAL, and C (ACRITHXSC, FortranXSC, PASCALXSC, and C XSC). Problemsolving routines with automatic result verification have been developed for many standard problems of numerical analysis as for linear or nonlinear systems of equations, for differential and integral equations, etc. as well as for a large number of applications in the engineering and natural sciences.
Language eXtensions for Scientific Computation provide all features indispensable for modern numerical software development, such as
To learn how to use the CXSC class library you can read the page Simple programming examples and follow the examples described there.
For more experienced users the C++ Toolbox for Verified Computing is the more interesting place. There you find much more sophisticated examples on how to use the CXSC class library.
The C++ Toolbox for Verified Computing is the C++ edition of the Numerical Toolbox for Verified Computing. The programs of the original edition were written in PASCALXSC, a PASCAL eXtension for Scientific Computation.
The methods presented here are practical, reliable, and elegant. They are provided in theory, algorithmic descriptions, and implementations to solve a number of basic numerical problems in a reliable way.
By default, CXSC uses a software emulation of a long fixpoint accumulator for dot product computations, which delivers results with maximum accuracy. This means that all operations by default are only one rounding away from the exact result. However, due to the software emulation these operations are slow.
The user can change the default behaviour for the overloaded operators by setting the global integer variable opdotprec to a value K. All dot products computed with overloaded operators (for example in a matrixmatrix product), are then carried out in (simulated) Kfold double precision. For K=1, pure floating point operations are used. For K>=2, the DotK algorithm, based on socalled error free transformations is used. Accuracy of the results and computing costs increase with K. For K=0, the default setting, the long accumulator is used as before.
When computing dot product expressions using the dotprecision classes, the precision used in each call of the accumulatefunction can be set via the member function set_dotprec of the dotprecision classes. The meaning of the setting is the same as for the operators.
For more information, see: Zimmer, M.; Krämer, W.; Bohlender, G.; Hofschuster, W.: Extension of the CXSC Library with Scalar Products with Selectable Accuracy Published in: Serdica Journal of Computing, Vol. 4, No. 3, p. 349370, 2010
For best performance, it is suggested to make use of the BLAS support of CXSC. BLAS support can be used for the overloaded operator* of the dense vector and matrix types. To activate it, the global variable opdotprec must be set to 1 and the flag DCXSC_USE_BLAS must be set during compilation. The program must then be linked to an optimized BLAS and CBLAS library. When activating BLAS support, and intermediate midpointradiusformat is used for intervals, which might result in some additional overestimation.
Please note that the BLAS library used must allow the changing of the rounding mode. Suitable BLASlibrarier in our tests were ATLAS and the Intel MKL. Not supported at the moment is GoTo BLAS.
For more information, see:
Zimmer, M.; Krämer, W.; Hofschuster, W.: Using CXSC in High Performance Computing Preprint 2009/5, Universität Wuppertal, 2009 Revised version submitted for publication (PARA2010): Walter Krämer, Michael Zimmer, Werner Hofschuster: Using CXSC for High Performance Verified Computing PARA 2010, Reykjavik, Iceland, Part II, LNCS 7134, SpringerVerlag, pp. 168178, 2012
Some of the CXSC operators can be parallelized using OpenMP. This is especially helpful when using higher precision computations or if no BLASlibrary is available. To activate OpenMP support, set the appropriate OpenMP flag of your compiler and additionally the flag DCXSC_USE_OPENMP during the compilation of your program.
Since CXSC is now nearly twenty years old, threadsafety has not been a focus in its development for a long time. In recent years, a lot of work has been invested into making CXSC fit for high performance computing and the threadsafety of CXSC has been vastly improved in the process.
More information can be found in:
Zimmer, M.: "Using CXSC in a MultiThreaded Environment" Preprint BUWWRSWT 2011/2, Universität Wuppertal, 2011, http://www2.math.uniwuppertal.de/wrswt/preprints/prep_11_2.pdf
The work on CXSC started in 1990 at the Institute for Applied Mathematics (Prof. Kulisch), University of Karlsruhe. Many colleagues and scientists have directly and indirectly contributed to the realization of CXSC. The authors would like to thank each of them for his or her cooperation. Special thanks go to U. Allendörfer, C. Baumhof, H. Berlejung, H. Bleher, H. Böhm, B. Bohl, G. Bohlender, F. Blomquist, K. Braune, H.H. Chen, D. Cordes, A. Davidenkoff, H.C. Fischer, M. Grimmer, K. Grüner, R. Hammer, M. Hinz, M. Hocks, B. Höffgen, W. Hofschuster, P. Januscke, E. Kaucher, R. Kelch, R. Kirchner, R. Klatte, W. Klein, W. Krämer, U. Kulisch, C. Lawo, M. Metzger, W.L. Miranker, M. Neaga, M. Neher, D. Ratz, M. Rauch, S. Ritterbusch, S.M. Rump, R. Saier, D. Schiriaev, L. Schmidt, G. Schumacher, U. Storck, J. Suckfüll, F. Toussaint, C. Ullrich, W. Walter, S. Wedner, G. Werheit, A. Wiethoff, H.W. Wippermann, J. Wolff von Gudenberg and M. Zimmer.
CXSC is an outcome of an ongoing collaboration of the Institute for Applied Mathematics (Prof. Kulisch), University of Karlsruhe and the Institute for Scientific Computing/Software Engineering (Prof. Krämer), University of Wuppertal. For the latest news and up to date software contact http://www.math.uniwuppertal.de/~xsc/ .
Thanks to the referees for valuable comments and suggestions.