How to determine whether a compound is an anion/cation/zwitt

User 779e37e0e6

25-04-2014 18:59:31


I would like to determine for each compound of a set of chemicals, if it is an anion, cation, or zwitterion. Could you please tell me what tool is the best? Can I do this using cxcalc or the JchemWebservices? How?

Looking forward to hearing from you.



ChemAxon d51151248d

05-05-2014 11:50:40

Hi MrYan,

The ionization of a molecule depends basically on the pH. So to decide if a molecule is an anion or a cation you have to calculate this feature at a given pH. You can use the averagemicrospeciescharge cxcalc function to calculate the average formal charge for the microspecies at a given pH.

An example:

cxcalc "CC(N)C(O)=O" averagemicrospeciescharge -H 7 -p 4

The output is:

id    Charge
1    7,0000    -0,0033

A molecule can have a zwitterionic form if it has an isoelectric point. To decide this, you can use the isoelectricpoint function. If the output contains a number, this means that the compound has a zwitterionic form.

The ouput for the previous example is :

id    pI
1    5,98

So I recommend that you use the cxcalc tool or you can use the Chemical Terms language to evaluate the formal charge at a given pH. See examples for this in the following forum topic: />

Best regards,











User 779e37e0e6

06-05-2014 19:07:52

Hi Daniel,


Thanks for the repsonse. I had the isoelectric point figured out, but it is good to have the confirmation. Regarding the anion/cation question. I have tried this example with the option "averagemicrospeciescharge", on the following structures:

cxcalc  -p 2 -H 7.4 ~/test.mol

1) [NH3+]C1=CC2=CC=C3COC4=C(C=C(C=C4)[N+](O)=O)C3=C2C=C1 :  

   averagemicrospeciescharge = 0.00 at pH 7.4; 1.00 at pH 0; 0.00 at pH 14

   formal charge = 2

2) NCC([O-])=O :

    averagemicrospeciescharge = -0.01 at pH 7.4; 1.00 at pH 0; -1.00 at pH 14

    formal charge = -1

3) [NH3+][C@@H](Cc1c[nH]c2ccccc12)C([O-])=O:

   averagemicrospeciescharge = -0.01 at pH 7.4; 1.00 at pH 0; -1.01 at pH 14

   formal charge = 0

In conclusion, I find that the formal charge is more reliable than the average microspecies charge when we want to determine if a compound is a cation or an anion. The more convenient way for me is to use those chemical terms but averagemicrospeciescharge does not help.



ChemAxon d51151248d

13-05-2014 09:14:14

Hi MrYan, 

So the best for you is to use the evaluate command line tool for the formalcharge() Chemical Terms function. This simply sums up the charges in the microspecies given as the input of the function.

See the following example:

evaluate -e "formalcharge()" "[NH3+][C@@H](Cc1c[nH]c2ccccc12)C([O-])=O"


Note however that a neutral compound (e.g. an amino acid) has many microspecies when soluted, and the average charge calculated over these microspecies at a given pH can have more chemical relevance than the charge of a single species. The former calculation is also available as a Chemical Terms function. (averagemicrospeciescharge(), see my previous post)

Best regards,