Phenolphthalein is used for: