Added rearrangement function to avoid overlapping articles