Let's say I have a vector $\vec{v}=(1,0)$ and a state $|10\rangle$, and a decimal number $3$. I know that I can associate the decimal $3$ with the vector $\vec{v}$, but can I also associate the state $|10\rangle$ with the decimal $3$? Is there some kind of isomorphism between these two, which I don't think there is because the state $|10\rangle$ corresponds to a 4 dimensional vector. Can someone clarify these doubts?
-
$\begingroup$ I'm confused about what you are calling the isomorphism. Do you mean to equate your vector to $2$ (binary $(1,0)$)? $\endgroup$Mark Spinelli– Mark Spinelli2019-04-21 23:04:18 +00:00Commented Apr 21, 2019 at 23:04
-
$\begingroup$ yes that is what i mean $\endgroup$Upstart– Upstart2019-04-22 02:12:46 +00:00Commented Apr 22, 2019 at 2:12
2 Answers
Let's use four bits/qubits for exposition.
With four bits, you want there to be an isomorphism between the classical vectors $(d,c,b,a)$ (with $d,c,b,a\in \{0,1\}$) and decimal numbers $D$. There is the obvious mapping $D=8d+4c+2b+a$. If you have $(d,c,b,a)=(0,0,1,1)$ then you map to $3$.
When you have four qubits that you know are in $\vert dcba\rangle$ with $(d,c,b,a)=(0,0,1,1)$ (because, say, you measured them) then it's OK to have that same mapping. The qubits are, in sense, classical bits after measurement.
It sounds like you're nervous about whether this mapping is still valid even when the system is in a superposition. But why wouldn't it be? After Hadamarding $4$ qubits that are initially $\vert 0000 \rangle$ then you can think of it as a uniform superpositon of $\vert 0000\rangle, \vert 0001\rangle, \cdots, \vert 1111\rangle$ or as a uniform superposition of $0,1,\cdots ,15$ as you see fit.
EDIT
Classically, with modern electronic computers, we have an "isomorphism" between bits and voltages. For example, we can equate +0V to $0$, and +1.1V to $1$. If we have a plurality of inputs, then we can equate the $n$ input voltages to an $n$-bit binary number.
Quantum mechanically, we have an "isomorphism" between, say, qubits and spin states. For example, we can equate spin down to $\vert 0\rangle$, and spin up to $\vert 1\rangle$. If we have a plurality of spin states, then we can equate a superposition of the $n$ spin states to a superposition of an $n$-bit binary number.
-
$\begingroup$ If I hadamard say $2$ zero states i.e $|0\rangle$, $|0\rangle$, I get (ignoring the normalizing factor) states $|00\rangle, |01\rangle,|10\rangle, 11\rangle$, this is before measuring the 2 qubits, now how do i think of them as $0,1,2,3$? This is still unclear $\endgroup$Upstart– Upstart2019-04-22 09:35:50 +00:00Commented Apr 22, 2019 at 9:35
-
$\begingroup$ You can use a representation. You represent "00" by "0", "01" by "1", "10" by "2" and "11" by "3". It are just two different ways to write the same thing. $\endgroup$nippon– nippon2025-11-19 13:40:29 +00:00Commented 2 days ago
Let's say I have a vector $\vec{v}=(1,0)$ and a state $|10\rangle$, and a decimal number $3$. I know that I can associate the decimal $3$ with the vector $\vec{v}$, but can I also associate the state $|10\rangle$ with the decimal $3$?
Is there some kind of isomorphism between these two, which I don't think there is because the state $|10\rangle$ corresponds to a 4 dimensional vector. Can someone clarify these doubts?
$|10\rangle$ can indeed correspond to a 4-dimensional vector due to the state $|10\rangle$ having 2 qubits, which can yield ${\#Discrete(Measurable)StatesPerQubit}^{\#Qubits} = 2^2 = 4$ possible states. Specifically, $|10\rangle$ can be represented as the 4-dimensional column vector $\begin{pmatrix} 0 \\ 0 \\ 1 \\ 0 \end{pmatrix}$, where the place values are, from top to bottom, $ \begin{pmatrix} |00\rangle \\ |01\rangle \\ |10\rangle \\ |11\rangle \end{pmatrix}$. Fully written out, the vector can equivalently be written as $0\cdot|00\rangle + 0\cdot|01\rangle + 1\cdot|10\rangle + 0\cdot|11\rangle$, which is equivalent to $|10\rangle$ since the rest of the terms are multiplied by the canceling coefficient (0). In this specific instance, we can map $|10\rangle$ to 3, just like OP wants.
However, if we in the future ever decide we want to apply any quantum gates to the state $|10\rangle$ that produce any type of non-One-Hot-format superposition$\dagger$ as a result, then we can't directly map the resulting superposition state to an integer. Well, we could spend $\infty$ time mapping each of the infinitely many possible permutations of the four amplitudes to an integer or natural#, but since amplitudes can be (irreducible) fractions (i.e., Reals) instead of being far more restricted to only being integers/naturals (like only being 0 or 1 with no in-between values), and since the size of the infinite set of Reals is greater than the size of the infinite set of integers, then we will never be able to map every possible tuple-that-contains-4-amplitudes to a unique integer because it would take not just $\infty_{Natural}$ time, but an infinitely larger infinity, $\infty_{Real}$ time.
$\dagger$"One-Hot" in this context means that exactly one of the elements in the column vector has nonzero amplitude (and is specifically an amplitude of value 1 so that it can satisfy probability calculation rules), all the other amplitudes in the column vector being 0. In the case of having exactly two qubits, there are exactly 4 possible One-Hot states, where each state is represented by a column vector:
$
\begin{pmatrix}
1 \\ 0 \\ 0 \\ 0
\end{pmatrix},
\begin{pmatrix}
0 \\ 1 \\ 0 \\ 0
\end{pmatrix},
\begin{pmatrix}
0 \\ 0 \\ 1 \\ 0
\end{pmatrix},
\begin{pmatrix}
0 \\ 0 \\ 0 \\ 1
\end{pmatrix}$
Example of a non-One-Hot "state" (it's actually a superposition):
$|10\rangle \rightarrow \text{Apply H to rightmost qubit} = |1+\rangle = \frac{1}{\sqrt{2}}|10\rangle + \frac{1}{\sqrt{2}}|11\rangle = \text{Uniform Superposition of the }|10\rangle \text{ and } |11\rangle \text{ states} =
\begin{pmatrix}
0 \\ \frac{1}{\sqrt{2}} \\ \frac{1}{\sqrt{2}} \\ 0
\end{pmatrix}$
How would we map a 4D column vector to a single integer? To map to an integer, uniquely, and for all possible 4-dimensional column vectors, I'm not certain it's possible.
However, what if we map the column vector to an expectation (i.e. weighted sum, i.e. weighted average)? That would allow us to at least convert the column vector into a unique fraction (i.e., convert to a fraction rather than the integer that we desired), like
$$\begin{align}
&0\cdot|00\rangle + 0\cdot|01\rangle
+ \frac{1}{\sqrt{2}}\cdot|10\rangle + \frac{1}{\sqrt{2}}\cdot|11\rangle \\
=&
0\cdot 1
\;\;\;\; +
0\cdot 2
\;\;\;\; +
\frac{1}{\sqrt{2}}\cdot 3
\;\;\;\; +
\frac{1}{\sqrt{2}}\cdot 4 \\
=&
0+0+ \frac{3}{\sqrt{2}} + \frac{4}{\sqrt{2}} \\
=&
\frac{7}{\sqrt{2}}
\end{align}$$
Why did I substitute the individual ket states to 1, 2, 3, and 4? It was somewhat arbitrary, but it needed to ensure that no ket has the same value so that there are no non-unique mappings. E.g., I can't substitute the kets with (1, 1, 2, 3) due to the duplicate "1".
I could've also chosen (0, 1, 2, 3) to replace the kets, or I could've chosen (10000, 11000, 25000, 999999) to replace the kets, etc.
So, we just converted (i.e., "mapped")
$\begin{pmatrix}
0 \\ 0 \\ \frac{1}{\sqrt{2}} \\ \frac{1}{\sqrt{2}}
\end{pmatrix}$
to
$\frac{7}{\sqrt{2}}$.
Another example mapping from (column vector that represents a superposition) to (unique irreducible fraction that represents Expectation), but where this example isn't a Uniform Superposition, but instead is just a general/arbitrary superposition (which is more useful since it works in the general case):
$$\begin{align} &\sqrt{\frac{3}{11}}\cdot|00\rangle + \sqrt{\frac{7}{11}}\cdot|01\rangle + 0\cdot|10\rangle + \sqrt{\frac{1}{11}}\cdot|11\rangle \\ =& \sqrt{\frac{3}{11}}\cdot 1 \;\;\;\; + \sqrt{\frac{7}{11}}\cdot 2 \;\;\;\; + 0\cdot 3 \;\;\;\; + \sqrt{\frac{1}{11}}\cdot 4 \\ =& 1\cdot\sqrt{\frac{3}{11}} \;\;\;\; + 2\cdot\sqrt{\frac{7}{11}} \;\;\;\; + 0 \;\;\;\;\;\;\;\; + 4\cdot\sqrt{\frac{1}{11}} \\ =& \sqrt{1^2}\cdot\sqrt{\frac{3}{11}} + \sqrt{2^2}\cdot\sqrt{\frac{7}{11}} + \sqrt{4^2}\cdot\sqrt{\frac{1}{11}} \\ =& \sqrt{\frac{3}{11}} + \sqrt{\frac{28}{11}} + \sqrt{\frac{16}{11}} \\ =& \sqrt{\frac{47}{11}} \end{align}$$
This was the conversion from $\begin{pmatrix} \sqrt{\frac{3}{11}} \\ \sqrt{\frac{7}{11}} \\ 0 \\ \sqrt{\frac{1}{11}} \end{pmatrix}$ to $\sqrt{\frac{47}{11}}$.
Edit:
Can the downvoters please enlighten me as to what is wrong or bad about my answer?
-
$\begingroup$ Hi Stev. 1. It’s too long for the question. 2. $|10\rangle$ is 2, not 3. 3. The stuff about floating precision of amplitudes is irrelevant. 4. Your use of “one-hot” is confusing. 5. The last half is not motivated to me. Otherwise good luck! $\endgroup$Mark Spinelli– Mark Spinelli2025-11-20 11:07:52 +00:00Commented 2 days ago
-
$\begingroup$ 1) I wasn't aware that answers can't be long, but I will consider that from now on. 2) $|10\rangle$ is indeed the binary representation of the value "2", but OP started with the statement "associate the state $|10\rangle$ with the decimal 3", so I continued to use that. 3) I believe the float terminology is relevant because you can't bidirectionally and uniquely map every Real number to the entire set of natural numbers, though I could switch it to only use the more-officially-correct "real" instead of "float" if that is the issue. 5) Motivated==Lazy?, or Motivated=="Why are we doing this"? $\endgroup$Stev– Stev2025-11-20 11:23:54 +00:00Commented 2 days ago
-
$\begingroup$ Answers can be long and I’ve drafted plenty of long answers before, just be judicious. And motivated refers to the latter. Your contributions lately haven’t been wrong so much as they’ve been a little disconnected; it seems like you’re excited to share what you know, which is great, but try to answer a tight question with a tight answer. Maybe check out the unanswered questions list and try to take a stab at some of them? $\endgroup$Mark Spinelli– Mark Spinelli2025-11-20 11:33:00 +00:00Commented 2 days ago