Frequently Asked Questions
Questions
1. Software
1.1. Generalities
1.1.1. How do I report bugs or request new features?
Just drop a mail to Luc (luc(at)spaceroots(dot)org)!
1.1.2. Can I use the software on this site as I want?
Yes. This software is distributed in the hope it will be useful, under a BSD-like license. This mean you can do almost what you want, including embedding it in your own closed-source product if you want.
1.1.3. Is this code well tested?
I hope so. Of course, I cannot guarantee anything, but I try to set up tests as early as possible during development. Every time a bug is discovered, a corresponding test is added to the suite. The tests are distributed with the source and can be run using Junit.
The ode package has been tested by several people, only very few errors have been reported, they have all been corrected immediately
1.1.4. Is the full package currently being maintained?
Yes. New versions are distributed as I (or contributors) add new features. I often reply quickly to questions. If you want a new feature, do not hesitate to ask.
1.2. Mantissa versus Commons-math
1.2.1. How do you see the relation between Commons-Math and Mantissa software?
At first, I expected to merge all of Mantissa into Commons-math. However, the existing Commons-math developers expected to include only some parts that would be more interesting and I agreed with them.
The current status is to add only some parts of Mantissa and do this on the long run, not all at once.
Therefore I intend to iteratively add packages to Commons-math, then remove them from Mantissa and have the remaining parts of Mantissa rely on Commons-math and then go to next part. At the end, Mantissa will contain only the parts that will not be considered relevant or useful to Commons-math and it will depend on Commons-math, this will be an upper layer adding a few features.
Reducing Mantissa scope and adding a dependency to Commons-math will start with Mantissa version 8.0 or 9.0. The 7.x serie will be kept independant of Commons-math and will be maintained for as long as I can.
I think on the long run both libraries will stay and provide two layers, one for general usage and the other one for more specialized usage.
1.2.2. Do you intend to continue to develop the Mantissa and Commons-Math software in parallel?
Yes, but the scope of Mantissa will be adjusted. The ODE, geometry, estimation and optimization parts that have been transfered to commons-math will later be removed from Mantissa for example.
1.2.3. As a general user of mathematical software would I be better off using the Commons-Math or the Mantissa software?
If commons-math fits your needs, use it. It will at least include more and more feature whereas Mantissa will include less. If you need features only Mantissa provides, use Mantissa.
2. Maths
2.1. What are the arguments scalAbsoluteTolerance and scalRelativeTolerance in the Mantissa ODE package? What should I use these for, and what are typical values?
These arguments represent the tolerance for the error control. For each component of the state vector y[i] at the beginning of the step and y1[i] at the end of the step, a scaling factor is computed as
scale[i] = scalAbsoluteTolerance + scalRelativeTolerance * max(y[i], y1[i])
The error estimation is the RMS of (y1[i] - y1Diag[i])/scale[i], where y1 is the state vector at the end of the step and y1diag is the previous estimation from the Aitken-Neville interpolation.
This means that the algorithm will roughly keep the local error of y[i] below scalAbsoluteTolerance + scalRelativeTolerance * |y[i]|
If you need different accuracy on different components, you can use vectorial tolerances instead of scalar ones.
Typical values depend on your problem, of course but as a rule of thumb I would suggest something like scalRelativeTolerance = 10-9 and scalAbsoluteTolerance = 10-9 times the expected domain for the components of the state vector (hence having both terms in the sum of consistent order of magnitude).
The Gragg-Bulirsch-Stoer is especially suited for high precision, small tolerances are therefore compliant with the method.
2.2. Does the ODE package in Mantissa support backward integration?
Yes it does. Backward integration is specified by setting a target time smaller than the initial time. Note that the minStep and maxStep parameters of the adaptive stepsize integrators must always be positive, even for backward integration.
