Theory and Practice of pH Measurement