I am following a TI lab about opamp stability: "Precision Labs - Op amps: Stability". And I have some trouble to interpret phase margin from bode plot on an example.
The transfer function (closed loop gain) is: $$A_{CL}=\frac{A_{OL}}{1+A_{OL}\times\beta} \text{; where }\frac{1}{\beta}=\frac{R_f}{Z_1}+1$$ We know that for stability, the denominator of the transfer function must be different from 0, which leads to loop gain must be different from -1 \$(A_{OL}\times\beta\neq-1)\$. I understand that the Phase margin tells how much the \$A_{OL}\times\beta\$ is close to -1, correct!?
From the Gain graph below we see that \$@f_c\$, loop Gain \$|A_{OL}\times\beta|_{db}=|A_{OL}|_{dB}-|\frac{1}\beta|_{dB}=0\text{ dB}=1\$. And from the phase graph, always \$@f_c\$, \$\arg(A_{OL}\times\beta)=\arg(A_{OL})-\arg(\frac{1}\beta)≈5°\$. This makes \$A_{OL}\times\beta=1\$ and not \$-1\$. What I see is, in this example, loop gain is 175° far from the instability point (which is 180°). Am I misunderstanding something?
In other words, based on the \$\text{phase}(A_{OL}\times\beta)\$ graph, I can not see how the Phase Margin is 5° and in same time \$\text{phase}(A_{OL}\times\beta)=5°\$ \$@fc\$