diff --git a/lib/mosaic-geomath/src/main/java/org/eclipse/mosaic/lib/math/Aggregator.java b/lib/mosaic-geomath/src/main/java/org/eclipse/mosaic/lib/math/Aggregator.java index 8f548e013..51d24acf9 100644 --- a/lib/mosaic-geomath/src/main/java/org/eclipse/mosaic/lib/math/Aggregator.java +++ b/lib/mosaic-geomath/src/main/java/org/eclipse/mosaic/lib/math/Aggregator.java @@ -27,6 +27,10 @@ public Aggregator() { } public Aggregator add(double value) { + if (Double.isNaN(value)) { + return this; + } + min = Math.min(min, value); max = Math.max(max, value); sum += value;