  In the standard model for giant planet formation, the planetary growth begins
with accretion of solids followed by a buildup of a gaseous atmosphere as more
solids are accreted, and finally, by rapid accretion of gas. The interaction of
the solids with the gaseous envelope determines the subsequent planetary growth
and the final internal structure. In this work we simulate the interaction of
planetesimals with a growing giant planet (proto-Jupiter) and investigate how
different treatments of the planetesimal-envelope interaction affect the
heavy-element distribution, and the inferred core mass. We consider various
planetesimal sizes and compositions as well as different ablation and radiation
efficiencies, and fragmentation models. We find that in most cases the core
reaches a maximum mass of 2 Earth's Mass. We show that the value of the core's
mass mainly depends on the assumed size and composition of the solids, while
the heavy-element distribution is also affected by the fate of the accreted
planetesimals (ablation/fragmentation). Fragmentation, which is found to be
important for planetesimals > 1 km, typically leads to enrichment of the inner
part of the envelope while ablation results in enrichment of the outer
atmosphere. Finally, we present a semi-analytical prescription for deriving the
heavy-element distribution in giant protoplanets.
