I think in trial balance if the total debits = the total credits, the trial balance is balanced, But it does not ensure mathematical accuracy cause its only ensures that all debits and the corresponding credits have been properly recorded in the ledger.