Determining pH or Concentration of Ions