In chemistry, concentration is the level of a substance in a mix of substances, such as the amount of sodium chloride found in the sea, for example. Concentration may be expressed as various units, often given in terms of weights and volumes. Molarity is a form of weight per unit of volume. The molar concentration of a particular substance is the number of moles of that substance dissolved in one liter of solution, regardless of how many other substances may be dissolved in that same solution.
In sodium chloride (NaCl), ordinary table salt, the atomic weight of the two substances — sodium and chlorine — may be found by referring to the periodic table. Sodium’s atomic weight is 22.99. Chlorine's atomic weight is 35.45. This means sodium chloride — one atom of both these elements combined — has a molecular weight of 58.44. Since one mole of a substance is defined as its molecular weight in grams, one mole of NaCl is 58.44 grams (g).
By way of illustration, if 537 milliliters (ml) of a solution contains 15.69 g of sodium chloride, but no other substance, that solution’'s molar concentration is (15.69 g / 58.44 g) ÷ (537 ml / 1000 ml) = 0.50. The solution is 0.50M in sodium chloride. If the solution contains another component, such as magnesium bromide, this solution remains 0.50M in sodium chloride. It also has, however, a molar concentration in magnesium bromide.
Magnesium's atomic weight is 24.31. Bromine's atomic weight is 79.90. The molecular weight of magnesium bromide is not 24.31 + 79.90 = 104.21, however. This is because magnesium bromide has the chemical formula, MgBr2, since the valency of magnesium is +2, whereas the valency of bromine is only -1. Correctly, the molecular weight of magnesium bromide is 24.31 + (2 × 79.90) = 184.11.
If 24.72 g of magnesium bromide is present, the molar concentration of magnesium bromide is (24.72 g / 184.11 g) ÷ (537 ml / 1000 ml) = 0.25M. This means the solution is both 0.50M in NaCl and 0.25M in MgBr2. It is interesting to realize that, despite the decrease in water molecules in this second solution compared to the first — the concentrations are in terms of "per liter of solution," not "per liter of water" — the molar concentration of sodium chloride is the same for both. It is theoretically possible for an immensely large number of substances to be present in a single liter of solution, resulting in a collection of molar concentrations that are quite low, with almost no water present.