Added a function for writing the triangular matrices to stl.