  Topological metamaterials have robust properties engineered from their
macroscopic arrangement, rather than their microscopic constituency. They can
be designed by starting from Dirac metamaterials with either symmetry-enforced
or accidental degeneracy. The latter case provides greater flexibility in the
design of topological switches, waveguides, and cloaking devices, because a
large number of tuning parameters can be used to break the degeneracy and
induce a topological phase. However, the design of a topological logic
element--a switch that can be controlled by the output of a separate
switch--remains elusive. Here we numerically demonstrate a topological logic
gate for ultrasound by exploiting the large phase space of accidental
degeneracies in a honeycomb lattice. We find that a degeneracy can be broken by
six physical parameters, and we show how to tune these parameters to create a
phononic switch that transitions between a topological waveguide and a trivial
insulator by ultrasonic heating. Our design scheme is directly applicable to
photonic crystals and may guide the design of future electronic topological
transistors.
