commons-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Dennis Hendriks <D.Hendr...@tue.nl>
Subject git commits for common sub components don't identify the sub component in email subject
Date Thu, 09 Oct 2014 07:51:05 GMT
Hi all,

 From the subject of emails of the git commits (e.g. 'git commit: fixed too 
long first step in fixed Runge-Kutta integrators.'), it can no longer be 
seen that the commit is for a specific sub component of commons (e.g. 
'commons-math'). It can be seen from the first line of the email itself 
('Repository: commons-math'). Would it be possible to include the 
repository name as prefix of the subject? Something like: '[commons-math] 
git commit: ...'? That would make email client filtering rules etc possible.

When commons-math used Subversion in the past, it could be seen from the 
path. That is, the subject of the email was 'svn commit: r1554646 - in 
/commons/proper/math/trunk/src: 
main/java/org/apache/commons/math3/geometry/ 
main/java/org/apache/commons/math3/geometry/euclidean/oned/ 
main/java/org/apache/commons/math3/geometry/euclidean/threed/ 
main/java/org/apache/common...' or so, and included '/commons/proper/math' 
near the beginning, usually making filtering possible.

Best regards,
Dennis


On 10/08/2014 02:40 PM, luc@apache.org wrote:
> Repository: commons-math
> Updated Branches:
>    refs/heads/master 86b92b4e5 -> 69273dca6
>
>
> fixed too long first step in fixed Runge-Kutta integrators.
>
> This change is similar to the one done two years ago for adaptive step sizes integrator.
>
> JIRA: MATH-727
>
>
> Project: http://git-wip-us.apache.org/repos/asf/commons-math/repo
> Commit: http://git-wip-us.apache.org/repos/asf/commons-math/commit/69273dca
> Tree: http://git-wip-us.apache.org/repos/asf/commons-math/tree/69273dca
> Diff: http://git-wip-us.apache.org/repos/asf/commons-math/diff/69273dca
>
> Branch: refs/heads/master
> Commit: 69273dca6188a3d7d629d0d32dcf9cdb5b6c1036
> Parents: 86b92b4
> Author: Luc Maisonobe <luc@apache.org>
> Authored: Wed Oct 8 14:25:05 2014 +0200
> Committer: Luc Maisonobe <luc@apache.org>
> Committed: Wed Oct 8 14:25:05 2014 +0200
>
> ----------------------------------------------------------------------
>   .../ode/nonstiff/RungeKuttaIntegrator.java      | 14 +++++++++++-
>   .../ClassicalRungeKuttaIntegratorTest.java      | 24 ++++++++++++++++++++
>   2 files changed, 37 insertions(+), 1 deletion(-)
> ----------------------------------------------------------------------
>
>
> http://git-wip-us.apache.org/repos/asf/commons-math/blob/69273dca/src/main/java/org/apache/commons/math3/ode/nonstiff/RungeKuttaIntegrator.java
> ----------------------------------------------------------------------
> diff --git a/src/main/java/org/apache/commons/math3/ode/nonstiff/RungeKuttaIntegrator.java
b/src/main/java/org/apache/commons/math3/ode/nonstiff/RungeKuttaIntegrator.java
> index 68bd8b0..5f7d5d8 100644
> --- a/src/main/java/org/apache/commons/math3/ode/nonstiff/RungeKuttaIntegrator.java
> +++ b/src/main/java/org/apache/commons/math3/ode/nonstiff/RungeKuttaIntegrator.java
> @@ -119,7 +119,19 @@ public abstract class RungeKuttaIntegrator extends AbstractIntegrator
{
>
>       // set up integration control objects
>       stepStart = equations.getTime();
> -    stepSize  = forward ? step : -step;
> +    if (forward) {
> +        if (stepStart + step >= t) {
> +            stepSize = t - stepStart;
> +        } else {
> +            stepSize = step;
> +        }
> +    } else {
> +        if (stepStart - step <= t) {
> +            stepSize = t - stepStart;
> +        } else {
> +            stepSize = -step;
> +        }
> +    }
>       initIntegration(equations.getTime(), y0, t);
>
>       // main integration loop
>
> http://git-wip-us.apache.org/repos/asf/commons-math/blob/69273dca/src/test/java/org/apache/commons/math3/ode/nonstiff/ClassicalRungeKuttaIntegratorTest.java
> ----------------------------------------------------------------------
> diff --git a/src/test/java/org/apache/commons/math3/ode/nonstiff/ClassicalRungeKuttaIntegratorTest.java
b/src/test/java/org/apache/commons/math3/ode/nonstiff/ClassicalRungeKuttaIntegratorTest.java
> index 8136596..c527680 100644
> --- a/src/test/java/org/apache/commons/math3/ode/nonstiff/ClassicalRungeKuttaIntegratorTest.java
> +++ b/src/test/java/org/apache/commons/math3/ode/nonstiff/ClassicalRungeKuttaIntegratorTest.java
> @@ -310,4 +310,28 @@ public class ClassicalRungeKuttaIntegratorTest {
>         }, 0.0, new double[] { 0.0 }, 5.0, new double[1]);
>     }
>
> +  @Test
> +  public void testTooLargeFirstStep() {
> +
> +      RungeKuttaIntegrator integ = new ClassicalRungeKuttaIntegrator(0.5);
> +      final double start = 0.0;
> +      final double end   = 0.001;
> +      FirstOrderDifferentialEquations equations = new FirstOrderDifferentialEquations()
{
> +
> +          public int getDimension() {
> +              return 1;
> +          }
> +
> +          public void computeDerivatives(double t, double[] y, double[] yDot) {
> +              Assert.assertTrue(t >= FastMath.nextAfter(start, Double.NEGATIVE_INFINITY));
> +              Assert.assertTrue(t <= FastMath.nextAfter(end,   Double.POSITIVE_INFINITY));
> +              yDot[0] = -100.0 * y[0];
> +          }
> +
> +      };
> +
> +      integ.integrate(equations, start, new double[] { 1.0 }, end, new double[1]);
> +
> +  }
> +
>   }
>

---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@commons.apache.org
For additional commands, e-mail: dev-help@commons.apache.org


Mime
View raw message