How to design and size a solar battery system