less_retarded_wiki/qubit.md
Miloslav Ciz ad727dcdc6 Update
2022-04-11 14:40:07 +02:00

2.5 KiB

Qubit

Qubit is a quantum computing equivalent of a bit. While bits in classical computers can have one of two state -- either 0 or 1 -- a qubit can additionally have infinitely many states "in between" 0 and 1 (so called superposition). Physically qubits can be realized thanks to quantum states of particles, e.g. the polarization of a photon or the spin of a photon. Qubits are processed with quantum gates.

Whenever we measure a qubit, we get either 1 or 0, just like with a normal bit. However during quantum computations the internal state of a qubit is more complex. This state determines the probabilities of measuring either 1 or 0. When the measurement is performed (which is basically any observation of its state), the qubit state collapses into one of those two states.

The state of a qubit can be written as

A * |0> + B * |1>

where A and B are complex numbers such that A^2 + B^2 = 1, |0> is a vector [0, 1] and |1> is a vector [1, 0]. A^2 gives the probability of measuring the qubit in the state 0, B^2 gives the probability of measuring 1.

The vectors |0> and |1> use so called bra-ket notation and represent a vector basis of a two dimensional state. So the qubit space is a point in a space with two axes, but since A and B are complex, the whole space is four dimensional (there are 4 variables: A real, A imaginary, B real and B imaginary). However, since A + B must be equal to 1 (normalized), the point cannot be anywhere in this space. Using logic^TM we can figure out that the final state of a qubit really IS a point in two dimensions: a point on a sphere (Bloch sphere). A point of the sphere can be specified with two coordinates: phase (yaw, 0 to 2 pi, can be computed from many repeated measurements) and p (pitch, says he probability of measuring 1). It holds that:

A = sqrt(1 - p)

B = e^(i * phase) * sqrt(p)

The sphere has the state |0> at the top (north pole) and |1> at the bottom (south pole); these are the only points a normal bit can occupy. The equator is an area of states where the probability of measuring 0 and 1 are equal (above the equator gives a higher probability to 0, below the equator to 1).

In fact this all holds only with so called pure states. A quibit can sometimes also have a mixed state; such a state can be represented by a point inside the sphere.