# Speed of the calculation and memory usage

### This page gives hints on how to tune the speed and memory usage with the ABINIT package.

##### Copyright (C) 2016-2017 ABINIT group (XG)

Mentioned in help_features#2.4.

### Table of content:

- 1. Introduction.
- 2. Related input variables.
- 3. Selected input files.

### 1. Introduction.

The major factors governing the speed of an ABINIT run, for a given physical system, are:

- the size of the planewave basis set , see topic_Planewaves;
- the size of the wavevector grid sampling, see topic_k-points;
- and the parallelism, see topic_parallelism.

For the two first factors, there is a trade-off between CPU time and precision of the computation, while for the third factor, there is some limit on the maximal speed-up that can be achieved (and also, the resources must be available.

Beyond these major factors, there is still room for some adjustment. The needed planewave basis set will depend on the pseudopotential (or PAW atomic dataset) that is used. Some might be softer than others and need a smaller planewave basis set. They might possibly be less accurate as well ...

If one is only interested in ground-state properties and forces, one might also get some speed up by using a real-space representation of density and potential on a real space FFT grid that does not allow their fine details to be taken into account (actually, filtering such quantities). This is achieved by lowering boxcutmin below its theoretically needed value of 2.0 .

The choice of the FFT algorithm implementation, see fftalg might also lead to significant speed up, on specific machines.

For specific k-points, time-reversal symmetry can be used to represent the wavefunctions with their real part, instead of both their real and complex parts. This allows halving the memory needs, as well as the CPU time. See istwfk.

Other input variables related to tuning the speed or the memory usage are for expert users only.
Go to the top

### 2. Related input variables.

Basic input variables:

... boxcutmin [BOX CUT-off MINimum]
... istwfk [Integer for choice of STorage of WaveFunction at each k point]

Useful input variables:

... fftalg [Fast Fourier Transform ALGorithm]

Input variables for experts:

... exchn2n3d [EXCHange N2 and N3 Dimensions]
... extrapwf [flag - EXTRAPolation of the Wave-Functions]
... fftcache [Fast Fourier Transform CACHE size]
... iboxcut [Integer governing the internal use of BOXCUT - not a very good choice of variable name]
... nbdblock [Number of BanDs in a BLOCK]
... nloc_alg [Non LOCal ALGorithm]
... nloc_mem [Non LOCal MEMOry]
... ortalg [ORThogonalisation ALGorithm]
... useylm [USE YLM (the spherical harmonics)]
Go to the top

### 3. Selected input files.

WARNING : as of ABINITv8.6.x, the list of input files provided in the specific section of the topics Web pages is still to be reviewed/tuned. In some cases, it will be adequate, and in other cases, it might be incomplete, or perhaps even useless.
The user can find some related example input files in the ABINIT package in the directory /tests, or on the Web:

tests/v3/Input: t43.in
Go to the top