Text this: Density functional theory study of the electronic and optical properties of pure and magnesium doped Β-tricalcium phosphate compound