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.
Unless you have 100K x 100K x 8 ~ 80GB of memory, you cannot create this matrix in memory. You can create this matrix on disk and access it using memory mapping. However, using this approach will be very slow.
What are you trying to do? You may find that representing your data in a different way will be much more efficient.