findSingleMatElement: Find a single element of a symmetric matrix based on a...

Description Usage Arguments Value


Given a flattened vector representation of a symmatric matrix findSingleMatElement computes the row and column indices in the original matrix of a given element. The element is given by the index of the flattened vector. The flattened vector is a vector that contains all elements of the lower triangular part of the matrix including all diagonal elements. The order in which the elements are written to the vector is going through each row and copying each element from column one up to the diagonal element of that row into the flattened vector.


findSingleMatElement(pnElementIdx, pvFlatVec, pvIds = NULL)



Vector index of element to be searched for


Flattened vector represenation of symmetric matrix


Optional vector of Ids, if !, then they are added to result


lResultList Result list with components nRowIndex, nColIndex and nCoefficient

charlotte-ngs/rgrm documentation built on May 13, 2019, 3:34 p.m.