Carbon dioxide is naturally present in the atmosphere and involved in photosynthesis, but is also formed during combustion. The chemical formula is CO2. Carbon dioxide is necessary for life on earth to exist. It is a greenhouse gas in the atmosphere, see GHG.