From SIMION
| Table of contents |
Overview
SIMION can be a memory intensive application. Each grid point requires approx. 8 or 10 bytes of memory. So, a 300x300x300 3D array with no symmetry requires 300x300x300x10 bytes = ~270MB RAM. Multi-electrode PA# files or multiple PAs may require more.
The maximum number of points per PA is almost 200 million (~1.86GB) in SIMION 8.0 or 50 million (~480 MB) in SIMION 7.0. The maximum memory usage per SIMION process (holding all PAs and particles) is ~2 GB in SIMION 8.0 and 7.0 as imposed by standard 32-bit operating systems (/3GB switch probably cannot be used). There are some ideas being considered for going beyond 200 million points in 8.1.
SIMION Error Messages
When SIMION runs out of free voltage memory, you may get errors such as "Out of Heap Space - PA Block", "Heap Allocation Problems", (SIMION 7.0.x-8.0.1) or "Virtual memory not available to allocate %u contiguous bytes for %s" (SIMION 8.0.2). Such messages refer to a failure by SIMION to allocate memory from your operating system's pool of free memory (which includes both physical RAM and virtual disk space on your hard disk).
Solutions to Memory Issues
Some ways to overcome memory limitations are given below:
- (1) Shutdown any other running programs that are memory intensive and not needed. This should increase the proportion of memory that is free.
- (2) Reduce the memory requirements of your simulation. For example, reduce the number of points in the PA, make use of symmetry, combine electrodes in a PA# file, split the system into multiple PAs (See Multiple PAs), or use various PRG tricks to reduce the number of PA's or PA points needed). See e.g. the ion jumping tricks sometimes used to simulate Grids.
- (3) Increase your available virtual memory. You may need to increase your system's "page file" size. The page file is huge file on your hard disk that Windows resorts to if it runs out of physical RAM. Before doing this, check that you actually do have free disk space on the disk drive on which the page file is stored (typically C:). If you have close to zero bytes free, Windows will have problems, and you'll need to free up some hard disk space (e.g. delete temporary files). Beware: hard disks are vastly slower than physical RAM, so it pays to have physical RAM whenever possible.
- (4) Install more physical RAM.
Checking Free RAM on Your System
To check the amount of free volatile memory on your system, use the Windows Task Manager (press CTRL+ALT+DEL). Examine how much "memory usage" and "virtual memory (VM) usage" are listed on the simion.exe processes (you may need to "View | Select Columns...") and compare this to the amount of free physical RAM (total physical RAM minus the amount used by other programs and the operating system). For a global view, see the Performance Tab. The Performance Tab is a little bit complicated to interpret due to how virtual memory works, but basically the "Available" physical memory + system cache is the amount of free physical RAM. When physical RAM starts getting exhausted, the OS starts heavily swapping to disk, and the disk then becomes a huge bottleneck. (If the amount of RAM is a bottleneck, you should only run a single instance of SIMION at a time for this reason.) See the following reference for details on interpreting the memory statistics in the Windows Task Manager: [1] (http://www.theeldergeek.com/sizing_the_page_file.htm).
Installing More RAM
For adding more RAM to existing systems, SIS has had success with these people: www.crucial.com .
Pushing the 2 GB per PA limit in SIMION 8.0
As of SIMION 8.0, the "--reserved-memory" command-line switch is provided. This reserves a certain number of bytes of contiguous memory for SIMION PAs before SIMION starts, thereby preventing memory fragmentation and likely increasing the maximum PA size limit you can use. For example, to reserve 1.85 GB RAM for PAs (close to 200 million points), start up SIMION was follows:
simion.exe --reserved-memory 1.85G
If you want to change your Windows shortcut to do this, do the following under Windows XP (other versions of Windows could differ slightly). Right click on the "SIMION 8.0" program icon in the Windows task bar (which you usually start SIMION with) and click "Properties". In "Target" append the text --reserved-memory 1.85G to it. You may need to decrease the 1.85 number slightly depending on your system so that SIMION will still run (unfortunately, there is no known way to reliably automate the selection of the optimal reserve limit).

