Battery storage plays a vital role in the successful integration of renewable energy sources such as solar and wind power into the grid. By storing excess energy generated during periods of high production, batteries can deliver power when generation is low or intermittent, securing a more reliable and consistent energy supply. Optimizing battery