This is a bit of an unusual post, aimed at people familiar with optimization problems solved by the Excel solver (or Add-ins like OpenSolver)
In the attached Excel file, I simulate the following simple scenario:
A house consumes electricity from the grid for 24 hours.
The amount of...