Sand and fog are both mixture and therefore they do not have a chemical formula. Sand is term used for material that ones consisted of rocks and has, as a part of natural process, crumbled to small particles. Like rocks the sands can be of many different types. Each of these types is composed of mixtures of many different minerals.
Fog is composed of fine particles of moisture - that is water - suspended in air. The air itself is a mixture of many different gases. The moisture of the fog is an additional ingredient in the mixture of gases called air.
Common vinegar is also a mixture. However, the main ingredient of vinegar, which is acetic acid, is a compound. The chemical formula of Acetic acid is CH3COOH.