Skip main navigation

Working with larger quantum registers

How do we work with data in a quantum computer? In this article, read about entanglement and collapse of many-qubit states.
ยฉ Keio University

Working with multi-qubit registers allows the number of possible states to grow exponentially. It requires us to keep track of the weight (or amplitude) and phase of each possible state.

Weights and measures

Letโ€™s say we have two quantum registers, which we will call (A) and (B), and we add them together and put the result in register (C), so that (C = A + B). (These registers would each have more than one qubit, but for our purposes here we can treat them as a single numeric value.)

Letโ€™s assume we begin with (A) in a superposition of all of the numbers 0 to 3. We can write this using our dial representation, but in this case a simple table will do. Our values for (A):

A
0
1
2
3

and (B) the same:

B
0
1
2
3

Then when we add them together, obviously (C) will be the superposition of the numbers 0 to 6. But itโ€™s not quite as simple as that.

Since there are more different ways to get 3 when you add two numbers (0+3, 1+2, 2+1, 3+0) than to get 6 (only 3+3), there will be a different weight in the register set for the value (C=3) than for the value (C=6).

Moreover, our (A), (B) and (C) registers are now entangled, so we can no longer write down their values independently. There are four possible values for (A), four for (B), and seven for (C), so we might need as many as (4 times 4 times 7 = 112) different clock dial vectors! This shows the amazing growth in the classical resources necessary to represent the state of a quantum computer; although we are using only a few quantum values here, it is already impractical to write down the entire state. Fortunately, out of the 112 possibilities, only sixteen of them are non-zero. Letโ€™s list them:

A B C
0 0 0
0 1 1
0 2 2
0 3 3
1 0 1
1 1 2
1 2 3
1 3 4
2 0 2
2 1 3
2 2 4
2 3 5
3 0 3
3 1 4
3 2 5
3 3 6

If we reorganize our list, sorting according to the values of (C), we get this:

A B C
0 0 0
0 1 1
1 0 1
0 2 2
1 1 2
2 0 2
0 3 3
1 2 3
2 1 3
3 0 3
1 3 4
2 2 4
3 1 4
2 3 5
3 2 5
3 3 6

Itโ€™s now obvious that (C=3) has four times the weight of (C=6) or (C=0). When we measure (C), with some probability we will find each of the possible outcomes. The probability of finding 3 is (1/4), four times the probability of finding 0, which is only (1/16).

Let us assume that we do, in fact, find (C=3). When this happens, the superposition collapses, and we are left with only the terms that included a value of 3 for (C):

A B C
0 3 3
1 2 3
2 1 3
3 0 3

After measuring (C), it is no longer entangled with (A) and (B), but in this case (A) and (B) are still entangled with each other.

The ket notation

Of course, writing down tables this way is relatively clear but clumsy, which is why we use the ket notation. We can also track the weights a little more clearly. The initial superpositions for (|Arangle) and (|Brangle) would be

[|Arangle = frac{|0rangle + |1rangle + |2rangle + |3rangle}{2}] [|Brangle = frac{|0rangle + |1rangle + |2rangle + |3rangle}{2}]

To write down the combination of (|Arangle) and (|Brangle), we can put them together inside one ket, separated by a comma. For example, (|1,3rangle) would be (A=1, B=3). Since our two registers are independent and each has four terms, itโ€™s now obvious that we have sixteen values to write down, one corresponding to each line in the table above.

Letโ€™s skip forward a couple of steps and write down all three of our registers after measuring (C) and finding 3:

[|A,B,Crangle = frac{|0,3,3rangle + |1,2,3rangle + |2,1,3rangle + |3,0,3rangle}{2}]

Since all of the values for (C) are the same here, now we can factor (|Crangle) out:

[|A,B,Crangle = frac{(|0,3rangle + |1,2rangle + |2,1rangle + |3,0rangle)|3rangle}{2}]

Since (C) is no longer entangled with (A) and (B), we can ignore it if itโ€™s convenient, and just write (A) and (B). Of course, the vector lengths are adjusted at every step in this process so that the whole set remains normalized, but as long as all of the terms are the same weight and we mentally keep track, we can simplify it and just write down

[|0,3rangle + |1,2rangle + |2,1rangle + |3,0rangle]

This kind of partial collapse of the entire state, leaving some terms and entanglement, is a key to the way quantum algorithms work, and we will see its use in the upcoming Steps.

ใ‚ˆใ‚Šๅคงใใช้‡ๅญใƒฌใ‚ธใ‚นใ‚ฟใฎๅˆฉ็”จ

่ค‡ๆ•ฐใฎ้‡ๅญใƒ“ใƒƒใƒˆใ‚’ไฝฟใฃใŸใƒฌใ‚ธใ‚นใ‚ฟใ‚’ไฝฟใ†ใ“ใจใงใ€ๆ‰ฑใ†ใ“ใจใฎใงใใ‚‹็Šถๆ…‹ใฏๆŒ‡ๆ•ฐ้–ขๆ•ฐ็š„ใซๅข—ๅŠ ใ—ใพใ™ใ€‚ใ“ใฎใ‚ˆใ†ใชๅคงใใช้‡ๅญใƒฌใ‚ธใ‚นใ‚ฟใ‚’ๆดป็”จใ™ใ‚‹ใŸใ‚ใซใฏใ€ๅ–ใ‚Šใ†ใ‚‹ใ™ในใฆใฎ็Šถๆ…‹ใซๅฏพใ—ใฆใ€้‡ใฟ๏ผˆใ‚‚ใ—ใใฏๆŒฏๅน…๏ผ‰ใจไฝ็›ธใ‚’้€ไธ€่จ˜ๆ†ถใ—ใฆใŠใๅฟ…่ฆใŒใ‚ใ‚Šใพใ™ใ€‚

้‡ใฟใจๆธฌๅฎš

(A)ใจ(B)ใฎ2ใคใฎ้‡ๅญใƒฌใ‚ธใ‚นใ‚ฟใŒใ‚ใ‚‹ใจไปฎๅฎšใ—ใ€ใใ—ใฆใใ‚Œใ‚‰ใ‚’ๅŠ ็ฎ—ใ—ใŸ็ตๆžœใ‚’ใƒฌใ‚ธใ‚นใ‚ฟCใซๅ…ฅใ‚Œใ‚‹ใจใ€(C = A + B)ใจใชใ‚Šใพใ™ใ€‚ ๏ผˆใ“ใ‚Œใ‚‰ใฎใƒฌใ‚ธใ‚นใ‚ฟใฏใใ‚Œใžใ‚Œ่ค‡ๆ•ฐใฎ้‡ๅญใƒ“ใƒƒใƒˆใ‚’ๆŒใคๅฏ่ƒฝๆ€งใŒใ‚ใ‚Šใพใ™ใŒใ€ใ“ใ“ใงใฏๅ˜ไธ€ใฎๆ•ฐๅ€คใ‚’ไฟๆŒใ™ใ‚‹ใ“ใจใจใ—ใพใ™๏ผ‰ใ€‚

ใพใšใ€(A)ใŒ0ใ‹ใ‚‰3ใพใงใฎใ™ในใฆใฎๆ•ฐๅญ—ใฎ้‡ใญๅˆใ‚ใ›ใฎ็Šถๆ…‹ใซใ‚ใ‚‹ใจไปฎๅฎšใ—ใพใ™ใ€‚ใƒ€ใ‚คใƒคใƒซ่กจ่จ˜ใ‚’ไฝฟ็”จใ—ใฆใ“ใ‚Œใ‚’ๆ›ธใใ“ใจใ‚‚ใงใใพใ™ใŒใ€ใ“ใฎๅ ดๅˆใฏไปฅไธ‹ใฎใ‚ˆใ†ใชๅ˜็ด”ใช่กจใง่กจ็พใงใใพใ™ใ€‚ (A)ใฎๅ€ค๏ผš

A
0
1
2
3

(B)ใ‚‚ๅŒใ˜๏ผš

B
0
1
2
3

ๆฌกใซใ€(A)ใจ(B)ใ‚’ๅŠ ็ฎ—ใ—ใŸ(C)ใฎๅ€คใฏใ€0ใ‹ใ‚‰6ใพใงใฎๆ•ฐๅญ—ใ‚’้‡ใญๅˆใ‚ใ›ใŸใ‚‚ใฎใซใชใ‚Šใพใ™ใ€‚ใ—ใ‹ใ—ใใ‚Œใปใฉๅ˜็ด”ใงใฏใ‚ใ‚Šใพใ›ใ‚“ใ€‚

2ใคใฎๆ•ฐๅญ—ใ‚’่ถณใ—ใฆ(C = 6)ใ‚’ๅพ—ใ‚‹(3+3ใฎ1้€šใ‚Š)ใ‚ˆใ‚Šใ‚‚(C = 3)ใ‚’ๅพ—ใ‚‹(0+3, 1+2, 2+1, 3+0ใฎ4้€šใ‚Š)ใฎๆ–นใŒใŸใใ•ใ‚“ใฎ็ต„ใฟๅˆใ‚ใ›ใŒใ‚ใ‚Šใพใ™ใ€‚

ใ•ใ‚‰ใซใ„ใˆใฐใ€(A)ใ€(B)ใ€(C)ใฎใƒฌใ‚ธใ‚นใ‚ฟใฏ้‡ๅญใ‚‚ใคใ‚Œ็Šถๆ…‹ใซใ‚ใ‚‹ใฎใงใ€ใใ‚Œใ‚‰ใฎๅ€คใ‚’็‹ฌ็ซ‹ใซๆฑบๅฎšใ™ใ‚‹ใ“ใจใฏใงใใพใ›ใ‚“ใ€‚ (A)ใซใฏ4ใคใจ(B)ใซใฏ4ใคใฎๅ€คใฎๅ€™่ฃœใŒใ‚ใ‚Š(C)ใซใฏ7ใคใฎๅ€คใฎๅ€™่ฃœใŒใ‚ใ‚Šใพใ™ใ€‚ใ—ใŸใŒใฃใฆใ€(4 times 4 times 7 = 112)็จฎ้กžใฎใ‚ฏใƒญใƒƒใ‚ฏใƒ€ใ‚คใƒคใƒซใƒ™ใ‚ฏใƒˆใƒซใŒๅฟ…่ฆใซใชใ‚‹ใ“ใจใซใชใ‚Šใพใ™ใ€‚ใ“ใ‚Œใฏใ€้‡ๅญใ‚ณใƒณใƒ”ใƒฅใƒผใ‚ฟใฎ็Šถๆ…‹ใ‚’่กจ็พใ™ใ‚‹ใŸใ‚ใซๅฟ…่ฆใชๅคๅ…ธ็š„ใชใƒชใ‚ฝใƒผใ‚นใฎ้ฉš็•ฐ็š„ใช้‡ใฎไผธใณใ‚’็คบใ—ใฆใ„ใพใ™ใ€‚ใ—ใ‹ใ—ใ€ใ“ใ“ใงใฏใ„ใใคใ‹ใฎ้‡ๅญๅ€คใ—ใ‹ไฝฟ็”จใ—ใฆใ„ใพใ›ใ‚“ใฎใงใ€็Šถๆ…‹ๅ…จไฝ“ใ‚’ๆ›ธใ็•™ใ‚ใ‚‹ใฎใฏๅฎŸ็”จ็š„ใงใฏใ‚ใ‚Šใพใ›ใ‚“ใ€‚ๅนธใ„ใซใ‚‚ใ€112ใฎๅฏ่ƒฝๆ€งใฎใ†ใกใ€ๅฏ่ƒฝๆ€งใŒใ‚ผใƒญใงใชใ„ใ‚‚ใฎใฏใ€ใ‚ใšใ‹16ใ ใ‘ใงใ™ใฎใงใ€ใพใšใใ‚Œใ‚‰ใ‚’ใƒชใ‚นใƒˆใ‚ขใƒƒใƒ—ใ—ใฆใฟใพใ—ใ‚‡ใ†๏ผš

A B C
0 0 0
0 1 1
0 2 2
0 3 3
1 0 1
1 1 2
1 2 3
1 3 4
2 0 2
2 1 3
2 2 4
2 3 5
3 0 3
3 1 4
3 2 5
3 3 6

ใƒชใ‚นใƒˆใ‚’ๅ†็ทจๆˆใ—ใฆ(C)ใฎๅ€คใซๅพ“ใฃใฆใ‚ฝใƒผใƒˆใ™ใ‚‹ใจใ€ๆฌกใฎใ‚ˆใ†ใซใชใ‚Šใพใ™ใ€‚

A B C
0 0 0
0 1 1
1 0 1
0 2 2
1 1 2
2 0 2
0 3 3
1 2 3
2 1 3
3 0 3
1 3 4
2 2 4
3 1 4
2 3 5
3 2 5
3 3 6

ใ“ใฎ่กจใ‹ใ‚‰ใ€(C = 3)ใฏ(C = 6)ใพใŸใฏ(C = 0)ใฎ4ๅ€ใฎ้‡ใฟใ‚’ๆŒใคใ“ใจใŒใ™ใใซๅˆ†ใ‹ใ‚Šใพใ™ใ€‚ (C)ใ‚’ๆธฌๅฎšใ™ใ‚‹ใจใ€ใ‚ใ‚‹็ขบ็Ž‡ใงใ€ใใ‚Œใžใ‚Œใฎ็ตๆžœใ‚’ๅพ—ใ‚‹ใ“ใจใŒใงใใพใ™ใ€‚ 3ใ‚’ๅพ—ใ‚‹็ขบ็Ž‡ใฏ(1/4)ใงใ‚ใ‚Šใ€0ใ‚’ๅพ—ใ‚‹็ขบ็Ž‡ใฎ4ๅ€ใงใ‚ใ‚Šใ€ใ‚ใšใ‹(1/16)ใงใ™ใ€‚

ๅฎŸ้š›ใซ(C)ใ‚’ๆธฌๅฎšใ—ใฆใ€(C = 3)ใ‚’ๅพ—ใŸใจไปฎๅฎšใ—ใพใ™ใ€‚ใใ‚ŒใจๅŒๆ™‚ใซ้‡ใญๅˆใ‚ใ›ใฏๅŽๆŸใ—ใ€(C)ใฎๅ€คใŒ3ใ‚’ๅซใ‚€้ …ใฎใฟใŒๆฎ‹ใ•ใ‚Œใพใ™ใ€‚

A B C
0 3 3
1 2 3
2 1 3
3 0 3

(C)ใฎๆธฌๅฎšๅพŒใ€(C)ใฏ(A)ใจใ‚‚(B)ใจใ‚‚้‡ๅญใ‚‚ใคใ‚Œใฏใชใใชใ‚Šใพใ™ใŒใ€ใ“ใฎๅ ดๅˆใฏใพใ ใ€(A)ใจ(B)ใฏไบ’ใ„ใซ้‡ๅญใ‚‚ใคใ‚Œใฎ็Šถๆ…‹ใซใ‚ใ‚Šใพใ™ใ€‚

ใƒ–ใƒฉ-ใ‚ฑใƒƒใƒˆ่จ˜ๆณ•

ใ‚‚ใกใ‚ใ‚“ใ€ใ“ใฎใ‚ˆใ†ใซใƒ†ใƒผใƒ–ใƒซใ‚’ๆ›ธใ็•™ใ‚ใ‚‹ใ“ใจใฏใ€ๆฏ”่ผƒ็š„ๆ˜Žๅฟซใงใ™ใŒใ‚ใพใ‚ŠๅŠน็Ž‡ใฏใ‚ˆใใ‚ใ‚Šใพใ›ใ‚“ใ€‚ใใฎใŸใ‚ใ€ใƒ–ใƒฉ-ใ‚ฑใƒƒใƒˆ่กจ่จ˜ใ‚’ไฝฟ็”จใ™ใ‚‹ใ“ใจใงใ€ๆญฃ็ขบใซใ‹ใคใ€‚ใพใŸใ€้‡ใฟใ‚’ๅฐ‘ใ—ใฏใฃใใ‚Šใจ็ขบ่ชใ™ใ‚‹ใ“ใจใ‚‚ใงใใพใ™ใ€‚(|Arangle)ใจ(|Brangle)ใฎๆœ€ๅˆใฎ้‡ใญๅˆใ‚ใ›ใฏใ€

[|Arangle = frac{|0rangle + |1rangle + |2rangle + |3rangle}{2}] [|Brangle = frac{|0rangle + |1rangle + |2rangle + |3rangle}{2}]

(vert Arangle)ใจ(vert Brangle)ใฎ็ต„ใฟๅˆใ‚ใ›ใ‚’่กจ่จ˜ใ™ใ‚‹ใซใฏใ€ใ‚ซใƒณใƒžใงๅŒบๅˆ‡ใฃใฆ1ใคใฎใ‚ฑใƒƒใƒˆๅ†…ใซใพใจใ‚ใ‚‹ใ“ใจใŒใงใใพใ™ใ€‚ใŸใจใˆใฐใ€(vert1,3rangle)ใฏ(A = 1)ใ€(B = 3)ใ‚’็คบใ—ใพใ™ใ€‚2ใคใฎใƒฌใ‚ธใ‚นใ‚ฟใฏ็‹ฌ็ซ‹ใ—ใฆใ„ใฆใใ‚Œใžใ‚ŒใŒ4ใคใฎ้ …ใ‚’ๆŒใฃใฆใ„ใ‚‹ใฎใงใ€ใ“ใ“ใงใฏ16ใฎๅ€คใŒใ‚ใ‚‹ใ“ใจใŒๆ˜Žใ‚‰ใ‹ใซใชใ‚Šใพใ™ใ€‚ใใ‚Œใžใ‚ŒไธŠใฎ่กจใฎๅ„่กŒใซๅฏพๅฟœใ—ใฆใ„ใพใ™ใ€‚

ใ„ใใคใ‹ใฎใ‚นใƒ†ใƒƒใƒ—ใ‚’ใ‚นใ‚ญใƒƒใƒ—ใ—ใ€(C)ใ‚’ๆธฌๅฎšใ—ใฆ3ใ‚’่ฆณๆธฌใ—ใŸๅพŒใฎ3ใคใฎใƒฌใ‚ธใ‚นใ‚ฟใ‚’ใ™ในใฆๆ›ธใ็•™ใ‚ใพใ—ใ‚‡ใ†ใ€‚

[|A,B,Crangle = frac{|0,3,3rangle + |1,2,3rangle + |2,1,3rangle + |3,0,3rangle}{2}]

ใ“ใฎๆฎต้šŽใงใฏใ€(C)ใฎๅ€คใฏใ„ใšใ‚Œใฎๅ ดๅˆใ‚‚ๅŒใ˜3ใชใฎใงใ€ใ“ใ“ใง(vert Crangle)ใ‚’ๅ› ๆ•ฐๅˆ†่งฃใ™ใ‚‹ใ“ใจใŒใงใใพใ™ใ€‚

[|A,B,Crangle = frac{(|0,3rangle + |1,2rangle + |2,1rangle + |3,0rangle)|3rangle}{2}]

(C)ใฏใ‚‚ใฏใ‚„(A)ใจ(B)ใจ้‡ๅญใ‚‚ใคใ‚Œใฎ้–ขไฟ‚ใซใชใ„ใฎใงใ€็„ก่ฆ–ใ—ใฆใ€(A)ใจ(B)ใ‚’ๆ›ธใใ ใ‘ใงใ‚‚ๆง‹ใ„ใพใ›ใ‚“ใ€‚ใ‚‚ใกใ‚ใ‚“ใ€ใƒ™ใ‚ฏใƒˆใƒซใฎ้•ทใ•ใฏใ“ใฎ้Ž็จ‹ใฎใ™ในใฆใฎใ‚นใƒ†ใƒƒใƒ—ใง่ชฟๆ•ดใ•ใ‚Œใ‚‹ใฎใงใ€ๅ…จไฝ“ใŒๆญฃ่ฆๅŒ–ใ•ใ‚Œใฆใ„ใฆใ€‚ใ™ในใฆใฎ้ …ใŒๅŒใ˜้‡ใฟใงใ‚ใ‚‹ใ“ใจใ‚’่ฆšใˆใฆใŠใ‘ใฐใ€ไปฅไธ‹ใฎใ‚ˆใ†ใซๅ˜็ด”ๅŒ–ใ—ใฆ่กจ็พใ™ใ‚‹ใ“ใจใŒใงใใพใ™ใ€‚

[|0,3rangle + |1,2rangle + |2,1rangle + |3,0rangle]

ใ“ใฎใ‚ˆใ†ใซใ€้ƒจๅˆ†็š„ใช็Šถๆ…‹ใฎๅŽๆŸใฏใ€ใ„ใใคใ‹ใฎ้ …ใจใ‚‚ใคใ‚ŒใŸ้‡ๅญใƒ“ใƒƒใƒˆใ‚’ๆฎ‹ใ—ใพใ™ใŒใ€ใ“ใ‚Œใ“ใใŒใ€้‡ๅญใ‚ขใƒซใ‚ดใƒชใ‚บใƒ ใฎใฎๅ‹•ไฝœใฎ้ตใ‚’ๆกใฃใฆใ„ใพใ™ใ€‚ใ“ใ‚Œใ‹ใ‚‰ใฎใ‚นใƒ†ใƒƒใƒ—ใง่ฉณใ—ใ่ฆ‹ใฆใ„ใใพใ—ใ‚‡ใ†ใ€‚

ยฉ Keio University
This article is from the free online

Understanding Quantum Computers

Created by
FutureLearn - Learning For Life

Reach your personal and professional goals

Unlock access to hundreds of expert online courses and degrees from top universities and educators to gain accredited qualifications and professional CV-building certificates.

Join over 18 million learners to launch, switch or build upon your career, all at your own pace, across a wide range of topic areas.

Start Learning now