add debtmatrix, some come refactor