function [real_z_index,comp_z_index] = class_real_comp(z) % the function to classify the real zero/poles and complex zero/poles % the complex zero/poles list has only one pole/zero of pole/zero conjugate % pares. comp_z_index = []; real_z_index = []; comp_z = []; for ii = 1:length(z) if isreal(z(ii)) real_z_index = [real_z_index ii]; else if not(sum(mnismember(comp_z,conj(z(ii))))) comp_z = [comp_z z(ii)]; comp_z_index = [comp_z_index ii]; end end end