MATLAB: Does there seem to be a discrepancy in TuningGoal.Overshoot specification and visualization of the goal using viewGoal

Control System Toolboxtuninggoal.overshootviewgoal

Why does there seem to be a discrepancy in TuningGoal.Overshoot specification and visualization of the goal using viewGoal?

Best Answer

You can create a TuningGoal.Overshoot class following the example here:
>> Req = TuningGoal.Overshoot('r','y',20);
then view the goal in a plot:
>> viewGoal(Req)
then right click the plot > Properties > Units > change the Magnitude filed to absolute.
The yellow colored section on the plot shows areas in which the TuningGoal.Overshoot is not satisfied. You would expect the yellow region to start at 1.2 ( 20% over 1), but instead it is greater than 1.23. As another example if you specify an overshoot of 50% the yellow area starts at 2.37.
The yellow region displayed on the bode plot by viewGoal for TuningGoal.Overshoot is actually correct.
It is mentioned in the documentation page of TuningGoal.Overshoot
"The overshoot tuning goal is evaluated as a constraint on the peak system gain, assuming second-order model characteristics."
The peak system gain/response is the peak gain of dynamic system frequency response, which can be observed in a bode plot. It is not the gain observed in the time-domain step response, but instead the peak gain at the peak frequency. While the peak gain in the time domain step response is just at one frequency. For example, you can show a second-order dynamic system:
>> zeta = 0.25;
>> w0 = 3;
>> sys = tf(w0^2,[1,2*zeta*w0,w0^2])
Using the 'step' command, you can see that the overshoot is about 44%. Generating the bode plot shows a peak gain of about 6.3 dB, an absolute value of 2.06. This result can be confirmed by using the command 'getPeakGain' or checking the infinity norm:
>> [ninf,fpeak] = norm(sys,Inf)
>> [gpeak,fpeak] = getPeakGain(sys)
The result would be the same if you check the following tuning goal:
>> Req = TuningGoal.Overshoot('r','y',44);
>> viewGoal(Req)
The start of the yellow region is the peak response of the bode plot of the system, 'sys', described earlier. As a result, there is no discrepancy between the tuning goal and the overshoot settings.