Electronic and optical properties of Si and Ge nanocrystals: an ab-initio study