Formulas for Liapunov Functions for Systems of Linear Difference Equations