Recently, I work in C++ and I have to create a array[60.000][60.000]. However, i cannot create this array because it’s too large. I tried float **array or even static float array but nothing is good. Does anyone have an ideas?
Thanks for your helps!
Recently, I work in C++ and I have to create a array[60.000][60.000] . However,
Share
A matrix of size
60,000 x 60,000has3,600,000,000elements.You’re using type
floatso it becomes:Do you even have that much memory in your machine?
Note that the issue of stack vs heap doesn’t even matter unless you have enough memory to begin with.
Here’s a list of possible problems: