# Study Convergence of the Reciprocal Space Grid¶

The present tutorial page explains how to run a convergence study of the size of the grid of k-points, necessary for sampling the Brillouin Zone of the crystal structure under investigation, using density functional theory.

K-point convergence can be run either as a stand-alone workflow, or prepended as a Workflow Add-on to another property calculation.

In the present tutorial, we will study the issue of k-point convergence for the case of crystalline silicon under its equilibrium cubic-diamond crystal structure, by making use of VASP as the main simulation engine. We will investigate k-point convergence in the context of a Total Energy calculation.

## Create Job¶

Silicon in its cubic-diamond crystal structure is the default material that is shown on new job creation, unless this default was changed by the user following account creation. If silicon is still the default choice, it will be automatically loaded at the moment of the opening of Job Designer.

## Choose workflow¶

Workflows for calculating the Total Energy through VASP can readily be imported from the Workflows Bank into the account-owned collection. This workflow can later be selected and added to the Job being created.

Thereafter, in order to add k-point convergence as an Add-on to the total energy calculation workflow, the user should click the appropriate button within the Subworkflow Editor Interface of Workflow Designer. The corresponding "Convergence" option should thus be chosen. The parameters contained in the resulting "Convergence" dialog should be set according to the instructions outlined in this page. For the moment, we shall just accept the default contents of such dialog, and proceed with no further modifications by clicking the bottom Apply button.

At the end of the insertion of the k-point convergence Add-on to the Total Energy Workflow, the user can scroll down to view the extra units which have been added for convergence purposes, which are primarily of Logical type. The objective of such units is to set up the parameters necessary to progressively increase k-point density, and consequently check the corresponding evolution of the total energy difference throughout the study to ensure a sufficiently accurate final convergence.

## Examine Input Files¶

Readers can open the main Execution Unit "vasp" by clicking it. The contents of the input files used for the convergence study within the VASP calculation can in this way be inspected, towards the bottom of the unit editor interface.

Users should be able to notice some differences in the formatting of the KPOINTS file, compared to the more conventional cases. This file should not normally be edited, or should be edited with caution, since the text is modified to contain templating expressions (eg. {{PARAMETER}}) that are necessary for the workflow to function correctly.

## Submit Job¶

Before submitting the Job, the user should click on the "Compute" tab of Job Designer and inspect the compute parameters included therein. Silicon is a small structure, so four cores and a few minutes of calculation runtime should be sufficient.

## Examine Results¶

Once the Job execution is finished, switching to the Results tab of Job Viewer will show the results of the computation, including the final converged value of the total energy as well as additional information about each execution unit.

## Converged k-point Density¶

Finally, the user can also browse the output and input files under the Files tab of Job Viewer. In order to determine the k-point density at which convergence was reached, the KPOINTS file should be downloaded and inspected.

### Convergence plot¶

The convergence plot can be retrieved upon Job completion under the "Charts" tab accessible by opening the main "vasp" Execution Unit. The relevant convergence plot is the one labelled "Ionic Energy". In order for this plot to appear among the calculation results, the "convergence_ionic" option should be selected under the "Detailed View" tab of the Total Energy Subworkflow Editor Interface at the moment of initial Job designing.

An example appearance of the "Ionic Energy" energy convergence chart as a function of k-grid size is given in the image below. In this case, after a sharp initial shift in energy, the desired convergence precision threshold has been reached for a k-grid size of 13 X 13 X 13. The threshold corresponds to the relative energy change between two subsequent steps in the k-grid size progression shown on the x-axis.

## Animation¶

We demonstrate the above-mentioned steps involved in the creation and execution of a k-points convergence study using silicon and Total Energy workflow in the video below.