There are many algorithms written in PLC code associated with both DC and
AC drives. Suggest you contact your drives supplier for best answers. If you don't have one in mind you can contact systems engineering at Rockwell Automation for help and direction. This application is one of the most demanding especially if you want the drive to operate in the constant HP region.