R/getTrace.R

getTrace <-
function(m)
{ #++
    # Returns the trace of the matrix m.
    
    return (sum(m[col(m) == row(m)]))
}
BERENZ/RISQ documentation built on May 5, 2019, 10:25 a.m.