Mercurial > dive4elements > river
changeset 9489:8562c60371b8
Fixed: Sinfo flood duration duration curves with km specific Q
author | mschaefer |
---|---|
date | Tue, 18 Sep 2018 17:28:22 +0200 |
parents | c347512a07bd |
children | e44c1a8b0c54 |
files | artifacts/src/main/java/org/dive4elements/river/artifacts/sinfo/flood_duration/FloodDurationCalculator.java |
diffstat | 1 files changed, 6 insertions(+), 3 deletions(-) [+] |
line wrap: on
line diff
--- a/artifacts/src/main/java/org/dive4elements/river/artifacts/sinfo/flood_duration/FloodDurationCalculator.java Tue Sep 18 17:27:09 2018 +0200 +++ b/artifacts/src/main/java/org/dive4elements/river/artifacts/sinfo/flood_duration/FloodDurationCalculator.java Tue Sep 18 17:28:22 2018 +0200 @@ -141,12 +141,15 @@ final double[] ows = new double[udays.length]; for (int i = 0, j = udays.length - 1; i <= udays.length - 1; i++, j--) { odays[j] = 365 - udays[i]; - oqs[j] = qs[i]; final QPosition qpos = wst.getQPosition(gauge.getStation().doubleValue(), qs[i]); - if (qpos != null) + if (qpos != null) { ows[j] = wst.interpolateW(station, qpos, problems); - else + oqs[j] = wst.getQ(qpos, station); + } + else { ows[j] = Double.NaN; + oqs[j] = qs[i]; + } } return new WQDay(odays, ows, oqs); }