3x + y = 2

x + 3y = 0

It's the sort of easy maths problem that you can work out in a few minutes using pencil and paper, but physicists in China, Canada and Singapore have now solved pairs of linear equations like this one using a simple quantum computer. Their experiment involves encoding quantum information into four photons and sending them through a system of optical devices. The physicists claim that their set-up could be improved and modified further to solve other types of problems.

The computational feat has been carried out by Jian-Wei Pan and colleagues at the University of Science and Technology of China, the University of Toronto and the National University of Singapore, who used a quantum algorithm created in 2009 by Aram Harrow, Avinatan Hassidim and Seth Lloyd. For simple systems of linear equations, Harrow and colleagues showed that their algorithm can be exponentially faster than the best solving methods that use a classical computer. One important caveat, however, is that the algorithm does not find an exact solution, but only the most likely answer.

Pan's team implemented the algorithm by firing ultraviolet (UV) laser pulses into an optical system containing two barium-borate crystals to create two pairs of photons. The two photons in a pair are entangled in terms of their polarization, which means that the correlation between the polarizations of the photons is greater than that allowed by classical physics.

### Beam splitters, mirrors and prisms

Each entangled pair is then sent through a polarizing beam splitter, which separates the photons according to their polarization – the four photons being the input qubits for the calculation. The qubits are then processed in an optical circuit that comprises polarizing beam splitters, mirrors and prisms. Two linear equations with two unknowns can be described in terms of a 2×2 matrix and a vector, both of which are encoded using three of the qubits. The fourth qubit is an "ancilla", which is set to a fixed value to make the quantum circuit function in the desired way.

As the four photons pass through the circuit they are placed in a highly entangled Greenberger–Horne–Zeilinger state, which is a hallmark of the quantum computation. The four photons are then detected using four different detectors. These detectors measure the polarizations of the photons and this information can be used to obtain the solution to the algebra problem.

Of course, the team already knew the answer, so they were able to test their implementation of the algorithm against the output predicted by theory. This was done for three different problems and they found that the fidelity of the experimental output varied from 0.993 to 0.825. (A fidelity of 1 would have corresponded to a perfect match.)

### Better sources and detectors

The team points out that its current set-up is limited by the use of single-photon sources – which are probabilistic and therefore do not always emit photons on demand – and by photon detectors that are relatively inefficient. However, the researchers are now developing better sources and detectors, which means that – when combined with on-chip integration – larger-scale implementations of the circuit could be created to solve more complex linear equation. The team's technique could also be used to implement other quantum algorithms for solving differential equations or fitting data to mathematical functions.

"The near-future goal is to control 10 to 20 photonic quantum bits," explains Lu Chaoyang at the University of Science and Technology of China. "The enhanced capability would allow us to test more complicated quantum algorithms, for instance, solving differential equations, realizing universal quantum-error correction codes, and quantum simulations of various systems."

The experiment is described in Physical Review Letters.