Dissolution and reprecipitation in model systems of porous hydroxyapatite