diff --git a/src/main/java/org/matsim/prepare/commercial/DefaultDemandPerDayCalculator.java b/src/main/java/org/matsim/prepare/commercial/DefaultDemandPerDayCalculator.java index 2840ef5..99770a7 100644 --- a/src/main/java/org/matsim/prepare/commercial/DefaultDemandPerDayCalculator.java +++ b/src/main/java/org/matsim/prepare/commercial/DefaultDemandPerDayCalculator.java @@ -53,12 +53,12 @@ public int calculateWasteDemandPerDay(Person freightDemandDataRelation) { } //if zone has a waste collection on this day, calculate the demand if (zonesWithWasteCollectionsOnThisDay.get(destination).contains(originCell)){ - int numberOfCollectionsPerWeek = 1; - double kilogramsPerDay = 0; - double tonsPerYear = CommercialTrafficUtils.getTonsPerYear(freightDemandDataRelation); - kilogramsPerDay = tonsPerYear * 1000 / (52 * numberOfCollectionsPerWeek); - kilogramsPerDay = Math.floor(kilogramsPerDay + this.rnd.nextDouble()); - return (int) kilogramsPerDay; + int numberOfCollectionsPerWeek = 1; + double shareOfPersonalWaste = 0.15; //TODO the current matrix has a wrong demand, because the tons per year are inclusive commercial/construction waste -> the share of personal waste is 0.15 + double tonsPerYear = CommercialTrafficUtils.getTonsPerYear(freightDemandDataRelation) * shareOfPersonalWaste; + double kilogramsPerDay = tonsPerYear * 1000 / (52 * numberOfCollectionsPerWeek); + kilogramsPerDay = Math.floor(kilogramsPerDay + this.rnd.nextDouble()); + return (int) kilogramsPerDay; } return 0; }