  The virtual detector is a commonly utilized technique to measure the
properties of a wavefunction in simulation. One type of virtual detector
measures the probability density and current at a set position over time,
permitting an instantaneous measurement of momentum at a boundary. This may be
used as the boundary condition between a quantum and a classical simulation.
However, as a tool for measuring spectra, it possesses several problems
stemming from its incoherent nature. Another form of virtual detector measures
the wavefunction's complex value at a set position in real space over time and
Fourier analyzes it to produce an energy spectrum. The spectra it produces are
exact provided that the wavefunction propagated through the detector in one
direction. Otherwise it will produce a spectrum that includes interference
between forward and backward propagating wavepackets. Here we propose a virtual
detector which maintains all the benefits of this coherent virtual detector
while also being able to resolve the direction of propagation and mitigate
nonphysical interference by use of a second measurement point. We show that, in
the continuum limit, this bi-directional virtual detector can reproduce an
equivalent wavefunction assuming a globally constant potential. It is therefore
equivalent to the exact spectrum.
