If the number of moles present in a gas and its mass is known, then the relative molecular mass of a gas can be calculated.
Relative molecular mass calculation
This was one of the first means of establishing relative masses. The number of moles can be ascertained using the volume data at STP and the mass of the gas can be worked out from density or other, more direct, weighing methods.
Example: Calculate the relative molecular mass of a gas if 0.254g of it occupies 80cm3 at STP
1 mole of gas occupies 22.7 dm3 at STP
therefore 80 cm3 of gas = 3.52 x 10-3 moles
3.52 x 10-3 moles of gas has a mass = 0.254g
Therefore relative molecular mass = 0.254/(3.52 x 10-3) = 72.1