All the contractions seem to follow some sort of logic: they place the mark between the words, and leave only the part of the sound that is predominantly heard ("I will" -> "I'll", "you have" -> "you've"). But with "not", the mark is placed right in the middle of the word (like in "does not"-> "doesn't" ), leaving the "n" attached to the previous word.
Is this an historical accident (and if it is, how it was born?), or does it have some (may be phonetic) explanation?