How do the a horizon and b horizon form?