A lead–lag compensator is a device used to improve the performance of systems that use electricity. It helps the system respond more quickly when something changes, like an increase or decrease in electricity. To do this, the lead–lag compensator smooths out changes in electricity by adding an extra amount of electricity to the system a little bit ahead of the change. This extra "pre-charge" of electricity will help the system respond more quickly when something changes.