pith. sign in

arxiv: 1705.01729 · v1 · pith:BYYANO5Anew · submitted 2017-05-04 · 💻 cs.SC

Compile-Time Symbolic Differentiation Using C++ Expression Templates

classification 💻 cs.SC
keywords templatesalgebraiccompilecompile-timecompilerdifferentiationexpressionexpressions
0
0 comments X
read the original abstract

Template metaprogramming is a popular technique for implementing compile time mechanisms for numerical computing. We demonstrate how expression templates can be used for compile time symbolic differentiation of algebraic expressions in C++ computer programs. Given a positive integer $N$ and an algebraic function of multiple variables, the compiler generates executable code for the $N$th partial derivatives of the function. Compile-time simplification of the derivative expressions is achieved using recursive templates. A detailed analysis indicates that current C++ compiler technology is already sufficient for practical use of our results, and highlights a number of issues where further improvements may be desirable.

This paper has not been read by Pith yet.

discussion (0)

Sign in with ORCID, Apple, or X to comment. Anyone can read and Pith papers without signing in.