Smart grid and renewable energy integration