Functional identites on matrix algebras