You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
if (p_batteryAsset.getStorageCapacity_kWh() != 0){
358
+
doubleCoopConnectionCapacityDelivery_kW = parentCoop.v_liveConnectionMetaData.contractedDeliveryCapacity_kW * 0.9; //10% reduction, to accord for time step delay
359
+
doubleCoopConnectionCapacityFeedin_kW = parentCoop.v_liveConnectionMetaData.contractedDeliveryCapacity_kW * 0.9; //10% reduction, to accord for time step delay
360
+
doublev_previousPowerBattery_kW = v_previousPowerElectricity_kW;// Assumes battery is only asset on gridconnection!! p_batteryAsset.electricityConsumption_kW-p_batteryAsset.electricityProduction_kW;
doubleavailableChargePower_kW = CoopConnectionCapacityDelivery_kW - currentCoopElectricityBalance_kW; // Max battery charging power within grid capacity
364
+
doubleavailableDischargePower_kW = CoopConnectionCapacityFeedin_kW + currentCoopElectricityBalance_kW; // Max discharging power within grid capacity
365
+
//Tuning parameters
366
+
doubleFeedbackGain_kWpSOC = 3 * p_batteryAsset.getCapacityElectric_kW(); // How strongly to aim for SOC setpoint
367
+
doubleFeedforwardGain_kWpKw = 0.1; // Feedforward based on current surpluss in Coop
368
+
doublechargeOffset_kW = 0; // Charging 'bias', basically increases SOC setpoint slightly during the whole day.
369
+
doublechargeSetpoint_kW = 0;
370
+
371
+
//Congestion prevention
372
+
if (availableChargePower_kW < 0) { //Delivery side
0 commit comments