A line of code allocating memory generates 'Allocate was unable to obtain sufficient memory'. This seems very odd given that the program has worked nicely for years, I have a 64bit laptop workstation with 16Gb of RAM and 8 i7 cores. The error occurs in either debug or release mode. I need to solve this problem QUICKLY as I am under a lot of pressure to complete simulations, compile a report and attend meetings. The size of the array to be allocated is 1 by 2 by 223 so can hardly be classed as massive!! I appreciate that one can include ISTAT=Ierror in the call to allocate to avoid a crash but the point is that all that does is tell me there is an error. Here is the code segment....and the error occurs with every single call to allocate. When the call occurs NSeg=1, NMAx=223, Nitems=2
[ if(allocated(Bdy_XY))deallocate(Bdy_XY) allocate(Bdy_XY(NSeg_bdy,NMax,Nitems)) ][/code]