Set charge

Description

This function sets the charge of a system. It requires the main system as the first parent and one or two charged system as the second/third parent. If two charged systems are selected as parents, they must carry a charge of opposite sign. Otherwise, the function is not able to decide which charged system to use and it will raise an error. The function automatically calculates how many copies of the second/third system need to be inserted into the main system to reach the specified target_charge. Once the required number of copies is determined, a fill_cell operation is performed, with random position and random orientation of the molecules in the cell (see here for more details).

Latest version

Allowed number of parents: 2 or 3

  1. Main System

  2. Charged system to be inserted in the Main System

  3. Second (optional) charged system, must have a charge of opposite sign compared to the first charged system

Parameter Description Value type Value restrictions Default value Units

Target charge

The charge of the final system in units of electrons.

int

N/A

0

e

Minimal distance between atoms

Minimal distance between two inserted components.

float

>0

2.0

Angstrom

Periodic boundary conditions

Indicates whether we have periodic boundary conditions in x, y and z

boolean

true, False

[True, True,True]

N/A

Seed for random generation

The seed used in the random generator, -1 can be selected for a random seed

int

>-1

123

N/A

Enable minimization

Indicates if a GROMACS energy minimization should be performed to increase the insertion success rate

boolean

True, False

False

N/A