How can I store a 100K X 100K matrix in Java?
I can\'t do that with a normal array declaration as it is throwing a java.lang.OutofMemoryError.
java.lang.OutofMemoryError
The Colt library has a sparse matrix implementation for Java.
You could alternatively use Berkeley DB as your storage engine.
Now if your machine has enough actual RAM (at least 9 gigabytes free), you can increase the heap size in the Java command-line.