给定诸如电力消耗、太阳能电池板发电量、价格等输入(在给定时间 t),我们有一个电池,我们想要评估在任何给定时间它应该(dis)/充电多少。问题可以表述如下:
Pt = price of electricity at time t
Lt = consumption of electricity at time t
Zt = charge of battery at time t (how much is in the battery)
St = Electricity generated from solar generator at time t
Qt = amount the battery (dis)/charges at time t
我们试图优化的功能是
Ct = Pt *(Lt - St - Qt)
这样做的目的是尽量减少购买的电量
具有以下约束:
Lt - St - Qt >= 0 (our demand has to be non-negative)
Qmin <= Qt <= Qmax ( the battery can only (dis)/charge between certain values at any given time)
Zmin <= Zt <= Zmax. (the battery has to be within its capacity, i.e. you can't discharge more than the battery holders, and you can charge more than the battery can hold)
Zt+1 = Zt + Qt+1 ( this means that the battery level at the next time step is equal to the battery level at the previous time step plus the amount that was (dis)/charged from the battery)
我遇到的问题是如何在 python (Scipy) 中制定问题,特别是更新电池电量。
我知道存在其他图书馆(Pyomo,Pulp),欢迎使用其中的解决方案。