We consider the problem of optimal charging/discharging of a bank of
heterogenous battery units, driven by stochastic electricity generation and
demand processes. The batteries in the battery bank may differ with respect to
their capacities, ramp constraints, losses, as well as cycling costs. The goal
is to minimize the degradation costs associated with batt