Re: Help Large_array [message #52616 is a reply to message #52614] |
Tue, 20 February 2007 04:15   |
Nigel Wade
Messages: 286 Registered: March 1998
|
Senior Member |
|
|
wx_f@sohu.com wrote:
> w...@sohu.com wrote:
>
>>> I need to build a ut=dblarr(36000,500,25) in IDL's pro---sfit.pro.
>
>> It is not possible to build such an array with IDL 32 bit version,
>> no matter how much memory your system has.
>>
>> Ciao,
>> Paolo
>
> Mr Pallo
> Since ut=dblarr(20000,500,25)
this requires 2GB of contiguous memory...
> and ut=fltarr(36000,500,25)can be
this requires 1.8GB of contiguous memory...
> created by my PC(linux_IDL6.0),why it cannot do better(3.6 vs 2,double
> vs float)?
for double it would require 3.8GB of contiguous memory.
> a) What's the reason.Could you give a formula to explain
> quantitatively?
There is a limit to the amount of memory which your OS can address. There is
also a limit below this as to the amount of contiguous memory which the OS can
allocate to a process. For a 32bit OS the absolute maximum amount of
addressable memory is 4GB. But since the OS requires space, and there are
likely to be many other running processes which are using chunks of that
address space the chance of you being able to allocate 3.8GB of the available
4GB for your array are vanishingly small. There is no quantitative formula for
the maximum size of an array which you can allocate, it varies with the amount
of memory in use and the amount of fragmentation of the allocated memory
chunks. The only rule is that it will be less than the maximum.
> b) What's the solution to the operation of large array once and for
> all(I mean by software not changing hardware)?
There is no solution if your hardware is 32bit. You need 64bit hardware, a 64bit
OS and a 64bit version of IDL if you want to use arrays of that size.
--
Nigel Wade, System Administrator, Space Plasma Physics Group,
University of Leicester, Leicester, LE1 7RH, UK
E-mail : nmw@ion.le.ac.uk
Phone : +44 (0)116 2523548, Fax : +44 (0)116 2523555
|
|
|