Motif finding algorthims implementation