What is the formula of tear gas, and the process of how its made?

What is the formula of tear gas, and the process of how its made?

Actually, tear gas agents are not only gases. Some of them are solids at normal temperature which are suspended in solution and sprayed as aerosols.
There are different types of compounds that may be used as tear gas.
Chloropicrin (Cl3CNO2) is one of the tear gas which also called trichloronitromethane, toxic organic compound .Its vapours are irritating to the skin, eyes, and upper respiratory tract, and it has been used in chemical warfare and as a tear gas.
It is manufactured by the reaction of nitro methane with sodium hypochlorite sodium hypochlorite.
H3CNO2 + 3 NaOCl → Cl3CNO2 + 3 NaOH

Yes, at home it is possible to prepare tear gas (pepper spray – prepared by using chili peppers dissolving vegetable oils).
Use of it causes inflammation and burning of the eyes, nose, and mouth.