Request for commentary about Boost interest in a new numerics package

I have been working on a compact (1 header, 1 cpp file, total about 1500 lines) and highly portable package for numerical operations on smooth functions. The package is in internal use by my research collaborators at Vanderbilt, and is very stable. The package consists of routines for manipulating smooth functions, which are defined as functions which are capable of not only returning their value, but the first two derivatives. Obvious cases are analytic functions, and cubic splines. The name of the package (and the objects it represents) is C2Functions. The most important and interesting parts of the package are 1) Very general spline support, including transparent change of variables in both X and Y to permit storage of linearized spline tables, while still presenting the function externally as it was established. Examples are LogLogInterpolatingFunction, LogLinInterpolatingFunction, etc., but the class is extensible to other schemes. These transformations allow high accuracy representation of functions by reducing the second derivatives in the spline tables, while exactly reconstructing the derivatives when evaluated. 2) Functional algebra, allowing one to generate new functions, constructed of old ones, which automatically keep track of the derivatives correctly. Thus, one can trivially write a new function g=C2Sin(f) where f is another C2Function, and g will correctly carry the derivatives through the composition. Available operators include basic binary functions, and composition. This allows a very compact representation of 'stiff' functions, such as the sine of a slowly varying phase error superimposed on a time, since the phase error can be embedded in an InterpolatingFunction, and the composition operation will reconstruct the exact derivatives of the rapidly varying sinusoid. 3) Very fast root finding and adaptive integration. Since the functions are smooth, and have exactly known derivatives, numerical methods are be introduced which are extraordinarily efficient. 4) Very light weight implementation. The C2Functions package is very shallowly nested, and the objects it creates are very low consumers of memory. They do almost no memory management themselves, leaving the user to be in charge of remembering to create and destroy them. In many cases, a lot of the work can be done with statically constructed functional compositions, etc., into which one plugs a pointer at run time to a particular function to which the operations will apply. As it currently stands, the only conflicts with Boost style are 1) naming... if the package is considered 'likely to be interesting', I will rename all functions to conform to Boost style 2) exception specification... I put these in while writing the code, thinking them to be a good idea, but I agree with the Boost rationale, and would gladly eliminate them. If this package is deemed interesting by the Boost community, it can be quickly cleaned up for actual submission. At present, I am working on a package of documentation for it, which describes both the thoery behind the package and its application. This still needs a bit of work. Comments? Thanks in advance. Marcus Mendenhall Research Associate Professor of Physics Vanderbilt University

| -----Original Message----- | From: boost-bounces@lists.boost.org | [mailto:boost-bounces@lists.boost.org] On Behalf Of Marcus Mendenhall | Sent: 21 March 2006 19:13 | To: boost@lists.boost.org | Subject: [boost] Request for commentary about Boost interest | in a newnumerics package | | I have been working on a compact (1 header, 1 cpp file, total about | 1500 lines) and highly portable package for numerical operations on | smooth functions. The package is in internal use by my research | collaborators at Vanderbilt, and is very stable. | | The package consists of routines for manipulating smooth functions, | which are defined as functions which are capable of not only | returning their value, but the first two derivatives. Obvious cases | are analytic functions, and cubic splines. The name of the package | (and the objects it represents) is C2Functions. Sounds very useful, for some. Upload files and documentation and examples to Boost vault? Paul -- Paul A Bristow Prizet Farmhouse, Kendal, Cumbria UK LA8 8AB Phone and SMS text +44 1539 561830, Mobile and SMS text +44 7714 330204 mailto: pbristow@hetp.u-net.com http://www.hetp.u-net.com/index.html http://www.hetp.u-net.com/Paul%20A%20Bristow%20info.html

"Marcus Mendenhall" wrote
If this package is deemed interesting by the Boost community, it can be quickly cleaned up for actual submission. At present, I am working on a package of documentation for it, which describes both the thoery behind the package and its application. This still needs a bit of work.
It sounds interesting to me. It would help to have some documentation describing use of the library too. . Is the documentation designed to be comprehensible to a non-mathematician like me (Though the unkind might prefer to call me mathematically challenged) ? regards Andy Little

On Tue, Mar 21, 2006 at 01:13:15PM -0600, Marcus Mendenhall <marcus.h.mendenhall@vanderbilt.edu> wrote:
3) Very fast root finding and adaptive integration. Since the functions are smooth, and have exactly known derivatives, numerical methods are be introduced which are extraordinarily efficient.
Sounds interesting, I would like to hear more, especially about that feature. Regards Andreas Pokorny
participants (4)
-
Andreas Pokorny
-
Andy Little
-
Marcus Mendenhall
-
Paul A Bristow