I think all (so simple) you have to do is parse all the tracks ever made, and say generate a sequence of snapshots of what the tune sounds like and the delta.
e.g. if it was notes (for simplicity) E,D,C,D,E,E,E,D,D,D,E,E,E is the start of "Mary had a little Lamb"
Millions of tracks contain the note E. Many hundreds of thousands probably have the note D next - and as you work through the sequence, you're pruning down that list until you who what it is.
Bit that makes my mind hurt though, is the data-structure you put those sequences into to make it quickly searchable.
Users can start recording at any point in the song - so you can't just prune a tree down from a known starting point.
There's going be be background nose - so you need some way of "when you have no choice left", I presume sticking wild-cards into the previous decisions, to see if you end up back on a known track.
Yeah - I think it's magic as well.
Other thoughts:
I used it back in the UK when it launched, and the first track I ever used it on dialling (2580 - the numbers down the middle of your keypad) was also a French track (MC Solaar – La Vie Est Belle)
I always felt they missed a trick, just identifying music (and then trying to sell you stuff).
Surely they could have used the same tech to seamlessly mix all music together.
(i.e. take the sequences within tracks they find hard to differentiate, and then use these points to allow two tracks to be mixed together).
What's the minimum number of tracks it would say take to seamlessly mix from Megadeth to Mozart?