Improved integration of renewable energy sources with the participation of active customers