Time-dependent diffusion coefficient and conventional diffusion constant are calculated and analyzed to study diffusion of nanoparticles in polymer melts. A generalized Langevin equa-tion is adopted to describe the diffusion dynamics. Mode-coupling theory is employed to calculate the memory kernel of friction. For simplicity, only microscopic terms arising from binary collision and coupling to the solvent density fluctuation are included in the formalism. The equilibrium structural information functions of the polymer nanocomposites required by mode-coupling theory are calculated on the basis of polymer reference interaction site modelwith Percus-Yevick closure. The effect of nanoparticle size and that of the polymer size are clarified explicitly. The structural functions, the friction kernel, as well as the diffusion coefficient show a rich variety with varying nanoparticle radius and polymer chain length. We find that for small nanoparticles or short chain polymers, the characteristic short time non-Markov diffusion dynamics becomes more prominent, and the diffusion coefficient takes longer time to approach asymptotically the conventional diffusion constant. This constant due to the microscopic contributions will decrease with the increase of nanoparticle size, while increase with polymer size. Furthermore, our result of diffusion constant from mode-coupling theory is compared with the value predicted from the Stokes-Einstein relation. It shows that the microscopic contributions to the diffusion constant are dominant for small nanoparticles or long chain polymers. Inversely, when nanonparticle is big, or polymer chain is short, the hydrodynamic contribution might play a significant role.