function D = centerBlocks(D)
% Shift blocks so that their default feedthrough is zero.

%   Author(s): P. Gahinet
%   Copyright 1986-2010 The MathWorks, Inc.
[D.Blocks,S] = center(D.Blocks);
if norm(S,1)>0
   if isnumeric(D.IC)
      IC = ltipack.lftdataM.shiftLFT(D.IC,S);
      SingularFlag = ~allfinite(IC);
   else
      [IC,SingularFlag] = shiftLFT(D.IC,S);
   end
   if SingularFlag
      ctrlMsgUtils.error('Control:lftmodel:InvalidModel')
   else
      D.IC = IC;
   end
end
