  A search is reported for heavy resonances and quantum black holes decaying
into e$\mu$, e$\tau$, and $\mu\tau$ final states in proton-proton collision
data recorded by the CMS experiment at the CERN LHC during 2016-2018 at
$\sqrt{s}$ = 13 TeV, corresponding to an integrated luminosity of 138
fb$^{-1}$. The e$\mu$, e$\tau$, and $\mu\tau$ invariant mass spectra are
reconstructed, and no evidence is found for physics beyond the standard model.
Upper limits are set at 95% confidence level on the product of the cross
section and branching fraction for lepton flavor violating signals. Three
benchmark signals are studied: resonant $\tau$ sneutrino production in $R$
parity violating supersymmetric models, heavy Z' gauge bosons with lepton
flavor violating decays, and nonresonant quantum black hole production in
models with extra spatial dimensions. Resonant $\tau$ sneutrinos are excluded
for masses up to 4.2 TeV in the e$\mu$ channel, 3.7 TeV in the e$\tau$ channel,
and 3.6 TeV in the $\mu\tau$ channel. A Z' boson with lepton flavor violating
couplings is excluded up to a mass of 5.0 TeV in the e$\mu$ channel, up to 4.3
TeV in the e$\tau$ channel, and up to 4.1 TeV in the $\mu\tau$ channel. Quantum
black holes in the benchmark model are excluded up to the threshold mass of 5.6
TeV in the e$\mu$ channel, 5.2 TeV in the e$\tau$ channel, and 5.0 TeV in the
$\mu\tau$ channel. In addition, model-independent limits are extracted to allow
comparisons with other models for the same final states and similar event
selection requirements. The results of these searches provide the most
stringent limits available from collider experiments for heavy particles that
undergo lepton flavor violating decays.
