Optimization of both the energetic efficiency and the duration of life of PV arrays by means of the dynamical reconfiguration of PV modules connections