Undercooling-Induced macrosegregation in directional solidification