Hmmm… I reckon three notes is completely inadequate for for most tunes – there are far too many tunes with the same first three notes. The first two bars is much more useful, and even that can get you in trouble. (Witness “The Dawn” versus “Michael Riley’s” – same first two bars, and they’re very distinctive, too, but utterly different tunes after that. Though their names get confused a lot.)
And I find that I can completely lose a tune, even one I’ve played a zillion times, if I haven’t played it in a while, because it gets crossed up with other silmilar phrases in my head. For instance, last week I couldn’t for the life of me get by the first bar of “The Scholar”, even though that’s a tune I competed with at a feis, and have had in one of my standard tune sets for years. Its beginning was too close to the B-parts of “Boys of the Lough” and “Martin Wynne’s #1” (which I also get confused) and I just completely lost it – sat around playing the first bar over and over again, trying pathetically to get to the next bar. No luck. Start on the B-part and wrap around – still no luck. It was just ugly. Then I heard someone else play it, and now I’ve got it back again.
If I have a specific tune in mind, I will always start it in the right key (if it has one) – finger memory, I think. But if I’m just noodling, it’s not at all unusual for me to start a key of D tune in G without realizing it, fly along nicely for a few bars playing by ear (without remembering what tune I’m playing), and then suddenly go off the rails when I hit something that’s unplayable (usually too high) in that key. I accidentally start “Wise Maid” in G at least once a week…