CIS2-Admittance-Control / almost_zero_static_gain_tf.m
almost_zero_static_gain_tf.m
Raw
% This function Checks if a given continuous transfer function has a net
% zero or near zero static gain.
% This function was retrieved from 
% https://www.mathworks.com/matlabcentral/answers/578373-how-to-check-if-two-transfer-functions-are-the-same
% Created: Bill Tubbs on 6 Nov 2020
function [c,absk] = almost_zero_static_gain_tf(G) % Checks if the resultant TF is essentially zero
    [~,~,k] = zpkdata(G);
    c = abs(k) < 1e-10;
    absk = abs(k);
end