A program library that allows a control apparatus for controlling a driver (18, 28) to execute a program, the driver (18, 28) being configured to drive and rotate a rotor (10, 20), the program library comprising instructions for: receiving first input information indicating that a rotational position of the rotor (10, 20) falls within a predetermined range or is a predetermined position, and second input information identifying one or more characteristic values to be calculated selectively from a plurality of characteristic value candidates; and calculating the one or more characteristic values specified by the second input information corresponding to a rotational position of the rotor (10, 20) indicated by the first input information falling within a predetermined range or being a predetermined position using a status value of the driver (18, 28) obtained in predetermined cycles, wherein the plurality of characteristic value candidates include at least two of a maximum value of a difference between a value of a speed command provided to the driver (18, 28) and a measured speed value of the rotor (10, 20), a minimum value of a measured torque value generated in the rotor (10, 20), a rotational position of the rotor (10, 20) at which a difference between a value of a speed command provided to the driver (18, 28) and a measured speed value of the rotor (10, 20) is at a maximum, a rotational position of the rotor (10, 20) at which the measured torque value generated in the rotor (10, 20) is at a maximum, and a correlation coefficient for a difference between the value of the speed command provided to the driver (18, 28) and the measured speed value of the rotor (10, 20), wherein the program library further comprises instructions for using the calculated one or more characteristic values to detect an abnormality. receiving first input information indicating that a rotational position of the rotor (10, 20) falls within a predetermined range or is a predetermined position, and second input information identifying one or more characteristic values to be calculated selectively from a plurality of characteristic value candidates; and calculating the one or more characteristic values specified by the second input information corresponding to a rotational position of the rotor (10, 20) indicated by the first input information falling within a predetermined range or being a predetermined position using a status value of the driver (18, 28) obtained in predetermined cycles, wherein the plurality of characteristic value candidates include at least two of a maximum value of a difference between a value of a speed command provided to the driver (18, 28) and a measured speed value of the rotor (10, 20), a minimum value of a measured torque value generated in the rotor (10, 20), a rotational position of the rotor (10, 20) at which a difference between a value of a speed command provided to the driver (18, 28) and a measured speed value of the rotor (10, 20) is at a maximum, a rotational position of the rotor (10, 20) at which the measured torque value generated in the rotor (10, 20) is at a maximum, and a correlation coefficient for a difference between the value of the speed command provided to the driver (18, 28) and the measured speed value of the rotor (10, 20), wherein the program library further comprises instructions for using the calculated one or more characteristic values to detect an abnormality.