I have this big ( 40000 x 40000 ) sparse matrix in matlab workspace and I need to do some statistical test on each element (also the zeros) of it. Since this is pretty slow on matlab, I decided to solve the problem using a simple c++ code. I know how to do what I need to do once I have a c++ array that "stores" the matrix.
The problem is that I do not actually know how to menage to move the matrix from matlab to c++. I thought that I could write the full matrix in a txt or csv file and read it in c++ but I don't know how to write a c++ function/script that can read a csv/txt file and store the elements it reads as an array.
Can you please help me out? Also other possible approaches are more to welcome.