Fixed a convergence discrepancy with respect to theory in Gragg-Bulirsch-Stoer integrator.
JIRA: MATH-324 git-svn-id: https://svn.apache.org/repos/asf/commons/proper/math/trunk@893281 13f79535-47bb-0310-9956-ffa450edef68
This commit is contained in:
parent
204990415d
commit
95f2dd6f5f
|
@ -746,7 +746,7 @@ public class GraggBulirschStoerIntegrator extends AdaptiveStepsizeIntegrator {
|
||||||
// estimate if there is a chance convergence will
|
// estimate if there is a chance convergence will
|
||||||
// be reached on next iteration, using the
|
// be reached on next iteration, using the
|
||||||
// asymptotic evolution of error
|
// asymptotic evolution of error
|
||||||
final double ratio = ((double) sequence [k] * sequence[k+1]) /
|
final double ratio = ((double) sequence [targetIter] * sequence[targetIter + 1]) /
|
||||||
(sequence[0] * sequence[0]);
|
(sequence[0] * sequence[0]);
|
||||||
if (error > ratio * ratio) {
|
if (error > ratio * ratio) {
|
||||||
// we don't expect to converge on next iteration
|
// we don't expect to converge on next iteration
|
||||||
|
|
|
@ -39,6 +39,10 @@ The <action> type attribute can be add,update,fix,remove.
|
||||||
</properties>
|
</properties>
|
||||||
<body>
|
<body>
|
||||||
<release version="2.1" date="TBD" description="TBD">
|
<release version="2.1" date="TBD" description="TBD">
|
||||||
|
<action dev="luc" type="fix" issue="MATH-324" due-to="Vincent Morand">
|
||||||
|
Fixed a convergence discrepancy with respect to theory in Gragg-Bulirsch-Stoer
|
||||||
|
integrator.
|
||||||
|
</action>
|
||||||
<action dev="luc" type="fix" due-to="Dimitri Pourbaix">
|
<action dev="luc" type="fix" due-to="Dimitri Pourbaix">
|
||||||
Fixed a wrong dimension check in SVD solver.
|
Fixed a wrong dimension check in SVD solver.
|
||||||
</action>
|
</action>
|
||||||
|
|
|
@ -78,8 +78,8 @@ public class GraggBulirschStoerStepInterpolatorTest {
|
||||||
oos.writeObject(handler);
|
oos.writeObject(handler);
|
||||||
}
|
}
|
||||||
|
|
||||||
assertTrue(bos.size () > 34000);
|
assertTrue(bos.size () > 33000);
|
||||||
assertTrue(bos.size () < 35000);
|
assertTrue(bos.size () < 34000);
|
||||||
|
|
||||||
ByteArrayInputStream bis = new ByteArrayInputStream(bos.toByteArray());
|
ByteArrayInputStream bis = new ByteArrayInputStream(bos.toByteArray());
|
||||||
ObjectInputStream ois = new ObjectInputStream(bis);
|
ObjectInputStream ois = new ObjectInputStream(bis);
|
||||||
|
@ -101,7 +101,7 @@ public class GraggBulirschStoerStepInterpolatorTest {
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
assertTrue(maxError < 5.0e-11);
|
assertTrue(maxError < 5.0e-10);
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue