solver for ts problem with time limits