The qubits in a quantum computer are conceptually grouped together in the qubit register. Each qubit has an index within this register, starting at index 0 and counting up by 1. So a system with 5 qubits, for example, has a qubit register that has a width of 5 and indexed by 0, 1, 2, 3 and 4.
Each qubit can be adressed in qubit operations by using the qubit index.
The full quantum state is stored in memory and described in terms of the probability amplitude for each state. As an example, a two-qubit system is described by 4 complex parameters:
and a three-qubit system is described by 8 complex parameters:
where are the probability amplitudes associated with the computational basis states, see also qubit basis states.
Because each complex parameter is specified by two 64-bit precision floating point values, a quantum system with 3 qubits requires 128 kBytes of memory. A system with 10 qubits requires 16 kBytes. A system with 37 qubits requires more than 2 TBytes.