[PATCH 1 of 5] Fix for flys/issue1654: Divide through denisity, do not multiply

Wald Commits scm-commit at wald.intevation.org
Wed Oct 30 11:59:17 CET 2013


# HG changeset patch
# User Sascha L. Teichmann <teichmann at intevation.de>
# Date 1383130510 -3600
# Node ID 906ed0b1f3f116f7611f9284c8ca4a0f2ed8bca9
# Parent  2733b4aae74ba0d9d648a75cbbefac0f0ff0ad46
Fix for flys/issue1654: Divide through denisity, do not multiply.

diff -r 2733b4aae74b -r 906ed0b1f3f1 artifacts/src/main/java/org/dive4elements/river/artifacts/model/minfo/SedimentLoadCalculation.java
--- a/artifacts/src/main/java/org/dive4elements/river/artifacts/model/minfo/SedimentLoadCalculation.java	Tue Oct 29 19:46:41 2013 +0100
+++ b/artifacts/src/main/java/org/dive4elements/river/artifacts/model/minfo/SedimentLoadCalculation.java	Wed Oct 30 11:55:10 2013 +0100
@@ -522,7 +522,7 @@
             SedimentDensityFactory.getSedimentDensity(river, kmLow, kmUp, year);
 
         for (double km: load.getKms()) {
-            double dens = density.getDensity(km, year);
+            double dens = 1d/density.getDensity(km, year);
             SedimentLoadFraction fraction = load.getFraction(km);
             double coarse = fraction.getCoarse();
             double fineMiddle = fraction.getFineMiddle();


More information about the Dive4elements-commits mailing list