  The Kepler transit survey with follow-up spectroscopic observations has
discovered numerous super-Earth sized planets and revealed intriguing features
of their sizes, orbital periods, and their relations between adjacent planets.
For the first time, we investigate the size evolution of planets via both giant
impacts and photoevaporation to compare with these observed features. We
calculate the size of a protoplanet, which is the sum of its core and envelope
sizes, by analytical models. $N$-body simulations are performed to evolve
planet sizes during the giant impact phase with envelope stripping via impact
shocks. We consider the initial radial profile of the core mass and the initial
envelope mass fractions as parameters. Inner planets can lose their whole
envelopes via giant impacts, while outer planets can keep their initial
envelopes since they do not experience giant impacts. Photoevaporation is
simulated to evolve planet sizes afterward. Our results suggest that the
period-radius distribution of the observed planets would be reproduced if we
perform simulations in which the initial radial profile of the core mass
follows a wide range of power-law distributions and the initial envelope mass
fractions are $\sim0.1$. Moreover, our model shows that the adjacent planetary
pairs have similar sizes and regular spacings, with slight differences from
detailed observational results such as the radius gap.
