Hi all,
That is the algorithm that I coded for the sprand(n,m,density,rc) function (added 4th parameter). The aproach is the following :
a) If rc is a vector with the singular values desired for the sparse matrix then:
1) Create an nxm diagonal matrix with the singular values ordered in the 1st diagonal and then the rest 0s.