# Pyquil Easy, Hybrid Quantum Programming | Scipy 2018 | Guenevere Prawiroatmodjo

Down the chips to these absolute zero temperatures there’s a little more to qubits than just these zeros and ones actually a qubit can be anywhere between a 0 and a 1 so we can actually represent a qubit on a sphere where the z-axis is the energy of the qubit so the.

0 or the 1 and the x and y axis represent the phase information so you can see here a sphere Sirocco coordinates where the ZX is the positive sizes at the ground state and.

The negative z axis is the excited state.

So this is typically how you would explain a qubit it’s like a normal bit except that it can be 0 & 1 at the same time so this is.

How you would Express a qubit in direct notation using theta the the polar coordinates and Phi so.

You might wonder what does that mean why would a cubed b + 0 + 1 at the same time with how do I measure that so this is for example a qubit in this in the state superposition state 0 and 1 at the same time actually we can only measure the qubit on the z axis so we have to collapse the state onto the z axis so we can only measure either a 0 or.

1 so what we do when we measure qubits is we actually measure them many times so for.

Example we take 10,000 shots and then half the time we measure 0 and half the time we measure 1 so the result itself in classical space is still binary so I still get Siras or once but the quantum state itself is non binary so it has this continuum of states and so now you might wonder how do.

We actually control qubits so how do I tell the qubit that it’s in the ground state or in the excited.

Do computation so it’s so to do this we send the qubit a microwave pulse this pulse.

Is configured to be exactly at.

The resonance frequency of this 0 to 1 transition of the cubed or artificial atom pretty similar to what you would expect for example in an atom if I would radiate it it would go into the excited state and what happens it oscillate with a Rabi frequency between 0 & 1 now the cool thing is I can engineer this pulse I can actually send the pulse with a deliberate amplitude.

And time and I can say ok I’m going to now send a pulse that rotates a qubit onto the equator so into this superposition C or I can send a bit of a longer pulse and then flip the qubits from 0 to 1 this is what we call a quantum gate so if I if I don’t you season even more than I can go all around the Bloch sphere so to actually program a quantum computer or program these quantum.

Bits we have developed a language will the quantum instruction language and similar to a kewpie or CPU have a engaged such as and NAND or and so forth a quantum processing unit or qpu has quantum gates so the X does not gate which is the gate you get when you.

Flip a qubit from the ground to the excited state so a pi rotation around the x-axis then there’s also gates such as y&z which rotate and the qubit and phase space are can rotate it around the y axis are around the z axis and there’s the Hadamard gate which is a combination of a pi rotation around X and a PI over 2 rotation of Y so that rotates the qubit onto the equator and city superposition and then race to these three and tangling.