Minimum capacity of photovoltaic energy storage