  We study the production and evolution of charm and bottom quarks in hot
partonic medium produced in heavy ion collisions. The heavy quarks loose energy
in the medium which is reflected in the transverse momentum spectra of heavy
mesons. The collisional energy loss of heavy quarks has been calculated using
QCD calculations. The radiative energy loss is obtained using two models namely
reaction operator formalism and generalized dead cone approach. The nuclear
modification factors, $R_{AA}$ as a function of transverse momentum by
including shadowing and energy loss are calculated for $D^{0}$ and $B^{+}$
mesons in PbPb collisions at $\sqrt{s_{NN}}$ = 5.02 TeV and for $D^{0}$ mesons
at $\sqrt{s_{NN}}$ = 2.76 TeV and are compared with the recent measurements.
The radiative energy loss from generalized dead cone approach alone is
sufficient to produce measured $D^{0}$ meson $R_{AA}$ at both the LHC energies.
The radiative energy loss from reaction operator formalism plus collisional
energy loss gives good description of $D^{0}$ meson $R_{AA}$. For the case of
$B^{+}$ meson, the radiative energy loss from generalized dead cone approach
plus collisional energy loss gives good description of the CMS data. The
radiative process is dominant for charm quarks while for the bottom, both the
radiative process and the elastic collisions are important.
