Charges Commands

Charges Commands

Assign partial charges to models, atoms, and patterns.

charge

Syntax:

double charge(); 
double charge(q); 
double  q;

Assigns a charge of q to each selected atom in the current model, or returns the total charge of the current selection if no value is supplied.

For example:

charge(1.0);

gives each atom in the current model's selection a charge of 1.0.

chargeff

Syntax:

void charge(); 

Assigns charges to all atoms in the current model based on the forcefield associated to the model and the current types of the atoms.

For example:

chargeff();

chargefrommodel

Syntax:

void chargefrommodel(); 

Copies charges of all atoms in the current model to the atoms of the current trajectory frame.

For example:

chargefrommodel();

chargepatom

Syntax:

void chargepatom(id,  
 q); 
int  id;
double  q;

Assigns a charge of q to atom id in each molecule of the current pattern.

For example:

chargepatom(3, 0.1);

assigns a charge of 0.1 to the third atom in each molecule of the current pattern.

chargetype

Syntax:

void chargetype(fftype,  
 q); 
string  fftype;
double  q;

Assigns a charge of q to each atom that is of type fftype in the current model.

For example:

chargetype("OW",-0.8);

gives a charge of -0.8 to every atom that has an assigned typename of 'OW'.

clearcharges

Syntax:

void clearcharges(); 

Clears all charges in the current model, setting them to zero.

For example:

clearcharges();