Calculation of concentration and solubility