Explorar o código

Adds per House Calculations for partially supplied Subnets

Andreas T. Meyer-Berg %!s(int64=7) %!d(string=hai) anos
pai
achega
769dde4377
Modificáronse 1 ficheiros con 4 adicións e 0 borrados
  1. 4 0
      src/ui/controller/SimulationManager.java

+ 4 - 0
src/ui/controller/SimulationManager.java

@@ -111,8 +111,12 @@ public class SimulationManager {
                             } else {
                                 if ((production + minConsumption) >= 0) {
                                     hl.setState(HolonObject.PARTIALLY_SUPPLIED);
+                                    currentProduction += hl.getMinEnergy(x);
+                            		partiallySuppliedList.add(hl);
                                 } else if (hl.checkIfPartiallySupplied(timeStep)) {
                                     hl.setState(HolonObject.PARTIALLY_SUPPLIED);
+                                    currentProduction += hl.getMinEnergy(x);
+                            		partiallySuppliedList.add(hl);
                                 } else {
                                 	/**
                                 	 * Case that only some HolonObjects can be supplied