smith-waterman generate scores and backtrace matrix