The behavior of polyprotic anions in ion-exchange resins