If you do not have the concentration of ions, but instead you have the molarity or molality, you need to get the ionic concentration first. To do this, multiply the number of ions of each atom/ion by the molarity or morality.
ci(element) = molarity/molality × species quantity
You then place the ionic concentrations in the ionic strength formula like you normally would:
I = 1/2 × ∑(ci × zi2)
where:
I - Ionic strength;
∑ - Sum of values;
ci - Concentration of ions; and
zi2 - Charges of ions squared.
Read more