Using one dimension STL vector to store triangular matrix.