I'm doing a project in recommendation systems, and using the MovieLens ratings databse.
I need to calculate the SVD for different size Matrixes. I'm running the following code on matrixes of different sizes,and i have some questions:
Matrix mat = Matrix.Create(item.Value);//item value is Double[,]
DateTime dtStart = DateTime.Now;
SingularValueDecomposition temp = mat.SingularValueDecomposition;
double runTime = (DateTime.Now - dtStart).TotalSeconds;
1.First,i tried a 6040X503 Matrix. it succeeded, and the runtime was about 2 minutes. But another Matrix of 6040X471 just kept going and going and didn't finish.
The Matrixes are mostly zeroes.I wanted to know what reasons could be for such a problem?
2. I divided the user databse, from 6040 to 4331 and 1709. I ran the same code,but now the matrix is 4331X503,and the SVD did'nt take less than 2 minutes,it didn't finish,which is odd,because the matrix is smaller,and before he did it faster. If anyone knows
why this can happen,i would appreciate the help.
I'm using MathNet.Numerics.LinearAlgebra;
Thanks in advance,