The glass is not a single compound. It is therefore very difficult to give any particular chemical formula for it. But with reasonable accuracy, it may generally be expressed as follows:
aX2, bYO, 6SiO2
where a and b are numbers of molecules,
X = an atom of an alkali metal such as Na, K, etc.
Y = an atom of a bivalent metal such as Ca, Pb, etc.
With this expression, the chemical formulas for three groups of glass, as classified above, are as follows
Soda-lime glass: Na2O, CaO, 6SiO2
Potash-lime glass: K2O, CaO, 6SiO2
Potash-lead glass: K2O, PbO, 6SiO2