The formula for calculating pH is:
-LOG10[H+]
([H+] means the concentration of H+ ions, and is measures in moles? per litre)
A pH of 7 indicates neutrality, e.g. pure water. A lower pH number indicates increasing strength of acidity, and a higher pH number indicates increasing strength of alkilinity.