๐ ๐ฏ๐ฌ ๐๐ฎ๐๐ โข ๐ฏ๐ฌ ๐๐ผ๐ป๐ฐ๐ฒ๐ฝ๐๐ ๐ผ๐ณ ๐ค๐๐ฎ๐ป๐๐๐บ ๐๐ผ๐บ๐ฝ๐๐๐ถ๐ป๐ด | ๐๐ฎ๐ ๐ญ๐ญ
Hi everyone !
โClassical computers process bits. Quantum computers transform quantum states.โ
In the previous post, we learned that a qubit is described by probability amplitudes, not just probabilities. These amplitudes behave like waves and determine the likelihood of measuring 0 or 1.
But this leads to an important questionโฆ
๐ค How does a quantum computer change these amplitudes to perform computation?
The answer is Quantum Gates.
๐ช๐ต๐ฎ๐ ๐ฎ๐ฟ๐ฒ ๐ค๐๐ฎ๐ป๐๐๐บ ๐๐ฎ๐๐ฒ๐?
In a classical computer, logic gates like AND, OR, and NOT manipulate bits.
A quantum computer also uses gates โ but instead of changing bits, they transform the quantum state of qubits.
Rather than simply flipping 0 to 1, quantum gates modify a qubitโs probability amplitudes and phase, allowing it to evolve according to the laws of quantum mechanics.
Think of them as the instructions that guide how a qubit changes over time.
๐ง๐ต๐ฒ ๐๐ฎ๐ฑ๐ฎ๐บ๐ฎ๐ฟ๐ฑ (๐) ๐๐ฎ๐๐ฒ
Imagine a qubit starts in the state:
|0โฉ
Measuring it now always gives 0.
Now apply a Hadamard (H) Gate.
The state becomes:
(|0โฉ + |1โฉ) / โ2
The H gate doesnโt tell the qubit to become 1.
Instead, it transforms the quantum state so that measuring the qubit gives:
Get Lokesh P Dโs stories inย yourย inbox
Join Medium for free to get updates fromย thisย writer.
โข 50% โ |0โฉ
โข 50% โ |1โฉ
It creates superposition, enabling the qubit to explore multiple possibilities simultaneously.
๐ง๐ต๐ฒ ๐ญ ๐๐ฎ๐๐ฒ: ๐๐ต๐ฎ๐ป๐ด๐ถ๐ป๐ด ๐ฃ๐ต๐ฎ๐๐ฒ
Now apply a Z Gate.
The state changes to:
(|0โฉ โ |1โฉ) / โ2
Interestingly, the measurement probabilities remain 50% and 50%.
So what changed?
The phase.
Although invisible during a single measurement, phase determines how qubits interfere with each other after more quantum gates are applied. This interference strengthens some outcomes while weakening others.
๐ช๐ต๐ ๐๐ฟ๐ฒ ๐ค๐๐ฎ๐ป๐๐๐บ ๐๐ฎ๐๐ฒ๐ ๐ฆ๐ผ ๐๐บ๐ฝ๐ผ๐ฟ๐๐ฎ๐ป๐?
A quantum computer doesnโt solve problems by checking every answer one by one.
Instead, it applies carefully designed quantum gates that continuously reshape amplitudes and phases.
Through quantum interference, the probability of correct answers increases while incorrect ones become less likely.
Only after all these transformations are complete does the computer perform a measurement.
This is the foundation of powerful algorithms like Groverโs Search and Shorโs Algorithm.
๐ง๐ต๐ผ๐๐ด๐ต๐ ๐ผ๐ณ ๐๐ต๐ฒ ๐๐ฎ๐
โQuantum gates donโt tell a qubit what answer to give โ they shape the wave that makes the right answer most likely.โ
๐ก๐ฒ๐ ๐ ๐ถ๐ป ๐๐ต๐ฒ ๐ฆ๐ฒ๐ฟ๐ถ๐ฒ๐
๐๐ฎ๐ ๐ญ๐ฎ โข ๐ค๐๐ฎ๐ป๐๐๐บ ๐๐ถ๐ฟ๐ฐ๐๐ถ๐๐: ๐๐ผ๐ ๐ค๐๐ฎ๐ป๐๐๐บ ๐๐ฎ๐๐ฒ๐ ๐ช๐ผ๐ฟ๐ธ ๐ง๐ผ๐ด๐ฒ๐๐ต๐ฒ๐ฟ ๐๐ผ ๐ฆ๐ผ๐น๐๐ฒ ๐๐ผ๐บ๐ฝ๐น๐ฒ๐ ๐ฃ๐ฟ๐ผ๐ฏ๐น๐ฒ๐บ๐.








