Definition:A formula which indicates the simplest whole number ratio of atoms of different elements present in a compound is called an empirical formula.
1: First, calculate the percentage of each element present in a compound.
2: Divide the percentage of each element by its atomic mass to get the number of moles of each element.
3: Divide number of moles of each element by least value to get simple whole number ratio of atoms.
4: If atomic ratios are in fractions, multiply these by a suitable number to get simple whole number ratio.
5: Write atomic ratios of elements below their symbols to get the empirical formula.
To understand let's take an example