We present a hybrid quantum-classical algorithm to simulate thermal states of
a classical Hamiltonians on a quantum computer. Our scheme employs a sequence
of locally controlled rotations, building up the desired state by adding qubits
one at a time. We identify a class of classical models for which our method is
efficient and avoids potential exponential overheads encountered by Grover-like
or quantum Metropolis schemes. Our algorithm also gives an exponential
advantage for 2D Ising models with magnetic field on a square lattice, compared
with the previously known Zalka's algorithm.Comment: 5 pages, 3 figures; (new in version 2: added new figure, title
changed, rearranged paragraphs