RedaElMakroum / lecture-spring-2024

Following through live demo in open source energy modeling course.
Apache License 2.0
0 stars 1 forks source link

Feature: Optimize EV Charging Schedule #2

Open MilicaKov opened 4 months ago

MilicaKov commented 4 months ago

I made the following changes regarding the code: -Replaced the copy.deepcopy function with a simple list slicing method to copy the electricity prices. This simplifies the code and improves readability. -The modification of the input parameter prices is done directly within the function, eliminating the need to create a deep copy. -The print statement now displays the total cost. -The function minimize_cost is ready for use with the provided parameters, as indicated in the example usage comment at the bottom. -Removed the unnecessary comment lines to declutter the code.