function [i, p]=IterHorner(p, x0)
  i=0;
  while(1)
    [p_new q]=deconv(p, [1 -x0]);
    if(q(end) != 0)
      break;
    end
    p = p_new;
    i=i+1;
  end
end
