Soc min and soc max checks when lists
Summary
In the storage unit, there are two times the soc_min and soc_max are not properly checked when their type is list :
-
line 116 : the elements of a list of soc_min should be below the elements of a list of soc_max OR a float soc_min should be below any element of a list of soc_max OR the elements of a list of soc_min should be below a float soc_max.
-
line 238 when e_f is not None and capacity is not None, ValueError should be raised when e_f set out of bounds, when soc_min and soc_max are floats but also when they are one of the two are lists
Possible fixes
- l 238 : Todo : the checks hereunder, taking into account soc_min and soc_max can be int or float but also lists ! if capacity is not None and (e_f > soc_max * capacity or e_f < soc_min * capacity): # the e_f value should be in between : # [soc_mincapacity; soc_maxcapacity] raise ValueError('e_f should be in the following boundaries ' '[soc_mincapacity; soc_maxcapacity] but ' 'is {0}'.format(e_f)) else: