I am trying to subdivide a sphere recursively to implement a spherical wavelet algorithm on the faces. While I have 8 GB on memory available, I am limited to 9 subdivision levels for an icosahedron. My problem is the lack of memory and a bad_alloc exception while building my sphere even when I have plenty of memory available.
I thought I would reach my limit at 4 GB for a Win32 application because I would run out of addressable memory pointers. But as you can see I reached the limit at about 1.9 GB.
This error is independent from the used system.
Does anybody know what happened and how to deal with this kind of problem?