bug fixes, first dynamic programming implementation of contig (doesn't work)

cache on fft now working, infs are applied to 1:minw-1