Dicarboxyamylose and dicarboxycellulose, stereoregular polyelectrolytes: binding of calcium and magnesium ions