tr function

Trace of a Matrix