In recent years, the concept of vehicle-to-grid (V2G) technology has been gaining traction as a promising solution to optimize energy use and reduce greenhouse gas emissions. By allowing electric vehicles (EVs) to not only draw power from the grid but also return excess energy back to it, V2G systems have the potential to revolutionize the way we manage energy resources.