Returning to the subject of words and negative prefixes from yesterday - why is it that some words use the negative in- and others use im-? And what about the negative il- and ir-?
When it comes to choosing between the negative prefixes in-, im-, ir-, and il- phonetics and a phonological process are what dictate how the negative prefix is chosen. The phonological process involved is called assimilation. Assimilation is when a particular sound changes to blend with a sound that occurs either before or after the sound. With prefixes, assimilation occurs when the final sound of the prefix matches or comes close to matching the initial sound of the root word in place of articulation.
The "n - sound" from the in- prefix is produced by pushing the tongue against the alveolar ridge, thus it is called an alveolar consonant. This place of articulation is centrally located and can easily adapt to many other sounds and that is why it is the most common of these four negative prefixes (it is also the reason yesterday's list of words contained primarily in- words).
The im- prefix is used with words that start with a "p - sound" or a "b - sound" because the place of articulation of these sounds, the lips, is the same as that of the "m- sound."
The "l - sound" and "r - sound" have variable places of articulation but both are considered liquids. As such, words that start with the "l - sound" will use the il- negative prefix and words that start with an "r - sound" will use the ir- negative prefix.
In sum, while the choice of negative prefix may seem illogical, irregular, inexact and impractical it can all be explained with phonetics and phonology.