Residual stresses in selective laser sintering and selective laser melting