Optimizer: fix first slot of homeProfile (#24381)
This commit is contained in:
parent
38d0a34285
commit
998de44eb6
1 changed files with 1 additions and 1 deletions
|
|
@ -392,7 +392,7 @@ func prorateFirstSlot(profile []float64, firstSlotDuration time.Duration) []floa
|
|||
|
||||
// Take only slots from current hour onwards
|
||||
res := profile[firstSlot:]
|
||||
res[0] *= float64(firstSlotDuration / tariff.SlotDuration)
|
||||
res[0] *= float64(firstSlotDuration) / float64(tariff.SlotDuration)
|
||||
|
||||
return res
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue