implemented head reduction