  We present a theoretical study of Fano interference effects in few-photon
transport. Under appropriate conditions, a local defect in an optical waveguide
induces a highly asymmetric transmission lineshape, characteristic of Fano
interference. For a two-level emitter placed adjacent to such a defect, here
modeled as a partially transmitting element, we find an analytical expression
for the full time evolution of single-photon wavepackets and the emitter
excitation probability. We show how the partially transmitting element affects
the emitter lifetime and shifts the spectral position of the effective system
resonances. Using input-output formalism, we determine the single and
two-photon $ S $-matrices for both a two-level emitter and a cavity-emitter
system coupled to a waveguide with a partially transmitting element. We show
how the Fano interference effect can be exploited for the implementation of a
Hong-Ou-Mandel switch in analogy with a tunable linear or nonlinear beam
splitter.
