  In the paper, we employ a wavefunction approach to investigate the evolution
of a two-photon wave packet propagating in a one-dimensional waveguide coupled
to the Jaynes-Cummings (JC) system. We derive and solve, both analytically and
numerically, a set of equations of motion governing the quantum state of the
system. That allows us to provide real-time analysis of the evolution of the
wave packet two-photon joint spectrum (2PJS) and the excitation dynamics of the
JC system in the course of its interaction with the two-photon pulse. We
demonstrate that the 2PJS and the spectrum of the wave packet scattered from
the JC system experience transformation for nonzero atom-cavity couplings.
Moreover, using Schmidt decomposition, we show that the scattered photons
feature frequency entanglement contrary to the incident ones which are not
entangled.
