Update this question was previously titled as \"Give me the name of a simple algorithm for signal(sound) pattern detection\"
If I were you would start reading a little bit about Window Functions like Hamming window, this is a good starting point for sound recognition. (This is, of course, combined with Fourier Transformation)