Chemical Formulas

Out[]=
The Wolfram|Alpha Chemistry Team
Chemical formulas are a compact representation of the elemental composition of a molecular entity.
Consider an ammonia molecule.
Out[]=
ChemicalFormula
objects are easily created for molecules such as ammonia along with ions and even atoms!

Creation

An ammonia molecule:
ChemicalFormula["NH3"]
Out[]=
N
H
3
A uranyl dication:
ChemicalFormula["UO2+2"]
Out[]=
2+
U
O
2
A helium atom:
ChemicalFormula["He"]
Out[]=
He
Phase information can be specified using a second argument or including it directly in the formula string.
Liquid ammonia:
ChemicalFormula["NH3",<|"Phase"->"Liquid"|>]
Out[]=
N
H
3
(l)
Aqueous uranyl dication:
ChemicalFormula["UO2+2(aq)"]
Out[]=
2+
U
O
2
(aq)
ChemicalFormula
can be used to extract the chemical formula of other chemistry objects.
Get the chemical formula from a chemical entity, molecule and biomolecular sequence:
MapChemicalFormula,
water
CHEMICAL
,Molecule
Formula:
C
6
H
6
Atoms: 12 Bonds: 12
,BioSequence
Type: DNA Sequence
Content: ATAAAC…GCT 
(21 letters)

Out[]=

H
2
O
,
C
6
H
6
,
C
207
H
261
N
75
O
126
P
20

Empirical formulas are computable from a molecular formula or condensed formula using the “EmpiricalFormula” property.
A condensed formula for N-octanol:
ChemicalFormula["CH3(CH2)7OH"]
Out[]=
C
H
3
(C
H
2
)
7
OH
The empirical formula for n-octanol:
ChemicalFormula["CH3(CH2)4CH3"]["EmpiricalFormula"]
Out[]=
C
3
H
7

Properties

Chemical formula objects have many of the same properties of other chemistry objects.
The properties of the chemical formula for n-hexane:
Out[]=
Property
Value
AtomCount
20
ElementCounts

carbon
6,
hydrogen
14
ElementMassFraction

carbon

83.62
%
,
hydrogen

16.38
%

EmpiricalFormula
C
3
H
7
Formula
C
H
3
(C
H
2
)
4
C
H
3
FormulaString
CH3(CH2)4CH3
HillFormula
C
6
H
14
HillFormulaString
C6H14
MolarMass
86.18
g/mol
MolecularMass
86.18
u
NetCharge
0
Phase
Missing[Unspecified]
RelativeMolecularMass
86.18
Out[]=
Close
TOC