Role of cations in the conformation of iota and kappa carrageenan