Single Systems | Understanding Quantum Information & Computation | Lesson 01 — Transcript
Full transcript
- 0:00- Welcome to Understanding Quantum Information
- 0:02and Computation.
- 0:04My name is John Watrous,
- 0:05and I'm the technical director of IBM Quantum Education.
- 0:09The purpose of this series
- 0:10is to provide you with a solid understanding
- 0:12of quantum information and computation,
- 0:14and that means getting into the technical details
- 0:16of quantum information
- 0:18and seeing how quantum computing really works,
- 0:20what it can do and what it can't do.
- 0:24If you haven't already watched the overview video
- 0:25for this series,
- 0:26I encourage you to check that out.
- 0:29In that video,
- 0:29you'll find information about
- 0:31what sort of background preparation is recommended
- 0:33for this series,
- 0:34as well as an outline of the topics to be covered.
- 0:38Also, be sure to check out the Qiskit textbook,
- 0:40which covers the same material as this video series
- 0:43in a written form,
- 0:44and it also includes interactive components
- 0:46and interfaces to hardware and software
- 0:48designed to help you to better understand
- 0:51quantum information and computation.
- 0:53You'll find links to the overview video
- 0:55and the Qiskit textbook in the description.
- 0:58This is lesson one of unit one of the series.
- 1:02Unit one covers the basics of quantum information,
- 1:05and in the first lesson of this unit,
- 1:06we'll focus on how quantum information works
- 1:09for single systems,
- 1:10meaning that we have just one physical system
- 1:13or a device of some sort that stores quantum information
- 1:16and we're considering how that one system or device works
- 1:18in isolation.
- 1:20In the lesson following this one,
- 1:22we'll discuss how quantum information works
- 1:24when we have multiple systems
- 1:26and that will allow us
- 1:27to describe interesting and important concepts
- 1:30such as quantum algorithms
- 1:32that make use of multiple qubits
- 1:34and quantum protocols involving multiple individuals
- 1:37that process quantum information
- 1:39and transmit it back and forth to one another.
- 1:43But before getting into those discussions,
- 1:45it makes sense
- 1:45to start with the comparatively simple setting
- 1:48of a single system in isolation,
- 1:50partly because it's good to start simple,
- 1:53but also because as we will see,
- 1:55the description of how quantum information works
- 1:57for single systems in isolation
- 1:59leads very naturally and logically
- 2:01to the description of how quantum information works
- 2:04for multiple systems.
- 2:07Here's a brief overview of the lesson.
- 2:10We're gonna start by discussing classical information.
- 2:14Now, the purpose of this lesson
- 2:16is not to explain how classical information works,
- 2:19it's to explain how quantum information works,
- 2:22but to explain how quantum information works,
- 2:24it's very helpful to begin with classical information
- 2:27and to use it as a familiar point of reference
- 2:30when we discuss quantum information.
- 2:33At a mathematical level,
- 2:35quantum and classical information
- 2:36actually have pretty similar descriptions
- 2:39with some key differences, of course.
- 2:42In fact, quantum information really isn't separate
- 2:45from classical information at all.
- 2:47It's an extension of classical information.
- 2:50The fact of the matter is, at least in my view,
- 2:53that you really can't understand quantum information
- 2:55if you don't understand classical information,
- 2:58so starting with classical information makes sense.
- 3:02I do expect that this content will be familiar
- 3:05to some viewers,
- 3:06but even if you are familiar with it,
- 3:08I don't recommend that you skip it.
- 3:10In addition to highlighting the aspects
- 3:12of classical information
- 3:13that are most relevant to understanding quantum information,
- 3:16we're gonna introduce the Dirac notation in this part,
- 3:19which is a standard way that we're gonna use
- 3:21to describe vectors and matrices throughout the series.
- 3:25As it turns out,
- 3:26the Dirac notation isn't specific to quantum information.
- 3:30It can equally well be used
- 3:31in the context of classical information
- 3:34as well as many other settings
- 3:35where vectors and matrices arise.
- 3:39We'll then move on to quantum information,
- 3:41and specifically, we'll discuss the representation
- 3:44of quantum states as vectors,
- 3:47a simple type of measurement
- 3:48called a standard basis measurement,
- 3:50and unitary operations,
- 3:53which describe discreet time changes in quantum systems.
- 3:56Again, all in the setting of single systems.
- 4:02Before we get started with lesson itself,
- 4:04it will be helpful to clarify
- 4:06that there are actually two descriptions
- 4:08of quantum information,
- 4:10the simplified description,
- 4:12which is what we'll be focusing on in this lesson
- 4:14and throughout this first unit
- 4:16and the general description,
- 4:17which is covered in a later unit,
- 4:19specifically in the third unit of the series.
- 4:23The simplified description, true to its name,
- 4:25is simpler and it's typically learned first.
- 4:29In the simplified description,
- 4:30as I've already suggested,
- 4:32quantum states are represented by vectors
- 4:34and operations are represented by unitary matrices.
- 4:38This description of quantum information is sufficient
- 4:41for an understanding of most quantum algorithms,
- 4:43for instance,
- 4:44so it isn't oversimplified,
- 4:46it's the real thing.
- 4:48However, as we will discover as we go along,
- 4:51it does have some limitations.
- 4:55For instance, if we wanna model the effects of noise
- 4:57on quantum systems,
- 4:58this description turns out to be lacking.
- 5:03The general description, on the other hand, is more general
- 5:06and ultimately, it's more powerful in a mathematical sense.
- 5:11In this description,
- 5:12quantum states are represented
- 5:14by a special class of matrices called density matrices,
- 5:18and more general class of measurements and operations
- 5:21can be described including noise, for instance.
- 5:25It's entirely consistent with the simplified description
- 5:28and in fact,
- 5:29you can essentially view the simplified description
- 5:32as a special case of the general description,
- 5:34and it also includes classical information
- 5:36as a special case.
- 5:39It's also really quite beautiful in how it all works,
- 5:42so I strongly encourage you
- 5:44to learn about this general description
- 5:46when the time is right,
- 5:47but the simplified description
- 5:48is the more natural place to start,
- 5:50and so that is what we will do.
- 5:53We're going to begin
- 5:54by talking about classical information
- 5:56with an eye on the aspects of classical information
- 5:59that are most relevant to quantum information
- 6:01and the way that it's described mathematically.
- 6:06Imagine that we have a physical system or a device
- 6:08of some sort that stores information.
- 6:12We're gonna give this system the name X,
- 6:14but there's nothing important about this name.
- 6:16We could use any other name if we preferred,
- 6:19but just to pick a name, we're gonna call the system X.
- 6:24We're gonna make an assumption about X,
- 6:25which is that there is a finite set of classical states
- 6:29that X can possibly be in at any given moment.
- 6:33Here, when I refer to a classical state,
- 6:35I mean a configuration of the system
- 6:37that can be recognized and described unambiguously
- 6:41without any uncertainty or error.
- 6:44Really, this is something
- 6:45that you can think about intuitively.
- 6:47At a mathematical level,
- 6:49we simply define the set of classical states,
- 6:51we choose it however we want to
- 6:53or in whatever way best describes the device
- 6:55that we're working with.
- 6:58Let us give the name sigma to this set of classical states,
- 7:02and again, let me emphasize that we're assuming
- 7:04that sigma is a finite set.
- 7:07The set of classical states of this system X
- 7:09is not infinitely large like the set of all natural numbers.
- 7:12It's finite,
- 7:13and that's just an assumption that we're making.
- 7:17For example, it could be that X is a bit,
- 7:21in which case, the classical state set
- 7:23is the set containing two elements: zero and one.
- 7:27Sometimes we refer to this set as the binary alphabet.
- 7:32Another example is that X is an ordinary six-sided die,
- 7:35in which case, the classical states
- 7:37are the numbers one through six.
- 7:40Of course, we're talking about an abstraction here.
- 7:43An actual six-sided die may have many different attributes
- 7:46such as its precise position, its orientation,
- 7:50its temperature, and so on.
- 7:52But with respect to the information
- 7:54that's most typically relevant
- 7:55when we're talking about a six-sided die,
- 7:58the classical states are the numbers one through six
- 8:00indicated by the number of dots
- 8:02on whichever side of the die is facing up.
- 8:07If X is a switch on a standard sort of electric fan
- 8:10that you might have in your home,
- 8:12then perhaps the classical states
- 8:14are the settings high, medium, low and off.
- 8:18These are just examples.
- 8:20We could imagine systems
- 8:21having different classical state sets than these,
- 8:23but hopefully, they convey the idea
- 8:25that this notion of a classical state
- 8:27is something that should be familiar and can be understood
- 8:30in simple and intuitive terms.
- 8:34Mathematically speaking,
- 8:35the set of classical states is just a finite set,
- 8:38and of course, this set must also be non empty as well.
- 8:41There has to be at least one classical state
- 8:43that the system can be in
- 8:44and there has to be at least two classical states
- 8:47if the system is going to be useful at all
- 8:49for storing information.
- 8:53Now, in some situations,
- 8:55we might know that X is in some particular state,
- 8:58but in many situations,
- 8:59that arise in the setting of information processing,
- 9:02there may be uncertainty
- 9:03about the classical state of a system at a particular moment
- 9:07so that each possible classical state
- 9:08has some probability associated with it.
- 9:12For example, if X is a bit,
- 9:14then perhaps it's the case
- 9:16that X is in the classical state zero
- 9:19with probability three quarters
- 9:21and it's in the state one with probability one quarter.
- 9:25We're going to refer to this as a probabilistic state,
- 9:29and we could express this probabilistic state,
- 9:31as you see right here,
- 9:32simply by indicating what the probabilities are
- 9:35for the different classical states.
- 9:38A more succinct way to express this probabilistic state
- 9:42is by a vector,
- 9:44specifically the representation that you see right here
- 9:47is a column vector,
- 9:49and this vector indicates what the probabilities are
- 9:52for the two possible classical states.
- 9:55To be more specific,
- 9:56the first entry indicates what the probability is
- 9:59for X to be in the state zero,
- 10:00and the second entry tells us what the probability is
- 10:03for the system to be in the state one.
- 10:06This is simply the natural way
- 10:08to order the binary alphabet,
- 10:10or at least, it's the way that we are trained to do this.
- 10:12With zero first and one second.
- 10:16Going forward, we're gonna use the term probability vector
- 10:20to indicate a vector like this.
- 10:22Specifically, it's a vector
- 10:24whose entries are all non-negative real numbers
- 10:26and where the sum of the entries is equal to one,
- 10:29so it makes sense to think about these entries
- 10:31as being probabilities.
- 10:34Here in this example,
- 10:35there are just two entries
- 10:37because there's just two classical states of the system
- 10:40we're talking about,
- 10:41but in general, there could be any number of entries
- 10:43with the understanding being that there's one entry
- 10:46for each classical state
- 10:47of whatever system we're talking about.
- 10:52We're going to continue discussing classical information,
- 10:54probability vectors and so on in just a moment,
- 10:57but first, it's gonna be really helpful
- 10:59to introduce some notation for describing vectors
- 11:02known as the Dirac notation.
- 11:05In fact, this is just the first part of the Dirac notation.
- 11:08There are a couple of other aspects of the Dirac notation
- 11:11that we'll see a little bit later in the lesson.
- 11:15This notation is gonna be quite central to the way
- 11:17that we describe quantum information,
- 11:19so it's essential to understand how it works,
- 11:22but fortunately, it's very simple
- 11:25and it really doesn't have anything specifically to do
- 11:27with quantum information,
- 11:29so we can introduce it now in the familiar context
- 11:31of classical information.
- 11:35As before, we assume
- 11:36that we have a set sigma of classical states of some system,
- 11:40and let's assume
- 11:41that we have an ordering of these classical states,
- 11:44just like how we refer to an ordering of the binary alphabet
- 11:47in the previous example.
- 11:49Another way of saying this is that the elements of sigma
- 11:52are placed in correspondence with the integer
- 11:55from one to however many elements are contained in sigma,
- 11:59which is what this notation right here
- 12:01with two bars around sigma means.
- 12:03That's the number of elements in the set sigma.
- 12:06So there's a first state, a second state, and so on.
- 12:11The specific ordering or correspondence that we choose
- 12:14isn't actually gonna matter all that much.
- 12:17What's really important is that we have an ordering
- 12:20and we stick to it.
- 12:23For many classical state sets that we'll encounter,
- 12:25there will be a standard ordering
- 12:27just like we have with the binary alphabet,
- 12:29and if there isn't a standard ordering,
- 12:31we can just choose one.
- 12:33But whatever it is,
- 12:34the understanding is that we stick to it.
- 12:40Now, here's the notation that's being introduced.
- 12:43For any choice of a classical state a from our set sigma,
- 12:47we write this right here,
- 12:49which is read as ket a to mean the column vector
- 12:53that has a one in entry corresponding to a
- 12:56and a zero for all other entries.
- 13:00For example, if we return to the binary alphabet,
- 13:03which, as you might have guessed,
- 13:05is a very important example
- 13:06that we'll return to again and again.
- 13:09Then ket zero and ket one are the vectors
- 13:12that are defined right here.
- 13:14Ket zero is the vector that has a one in the entry
- 13:17corresponding to the classical state zero,
- 13:20which is the first entry,
- 13:22and a zero for all other entries,
- 13:24and in this case, there's only one other entry.
- 13:27Similarly, ket one is this vector right here
- 13:30where we have a one in the entry corresponding to one,
- 13:34which is the second entry,
- 13:35and a zero for all other entries,
- 13:37which, again, is just one entry.
- 13:41Here's another example.
- 13:43In this example, we have a classical state set sigma
- 13:46corresponding to the four suits
- 13:48in a standard deck of playing cards:
- 13:50clubs, diamonds, hearts, and spades.
- 13:54In this case,
- 13:55there really isn't a universally agreed upon ordering
- 13:57of these suits.
- 13:59For many card games,
- 14:00there is no ordering at all.
- 14:02They're just four different suits
- 14:03and that's all that matters,
- 14:05and there are different card games that do order these suits
- 14:07in different ways,
- 14:10but it doesn't really matter.
- 14:11We can just choose an ordering like the one
- 14:13that you see right here.
- 14:15This happens to be alphabetical ordering
- 14:17according to the names of these four suits
- 14:19written in English,
- 14:22Assuming that we've picked this particular ordering,
- 14:24then we define these four vectors:
- 14:27ket clubs, ket diamonds, ket hearts, and ket spades
- 14:31as you see right here,
- 14:32and these vectors correspond to the general description
- 14:36that you see up here.
- 14:38Given that we've chosen this particular ordering
- 14:40for these four suits.
- 14:43We can do the same thing
- 14:44for any classical state set that we choose.
- 14:46Keeping in mind that classical state set always means finite
- 14:49and non empty set.
- 14:52Vectors of this form are called standard basis vectors,
- 14:56and it's a very basic fact about vectors
- 14:58that every vector can be expressed in a unique way
- 15:01as a linear combination of standard basis vectors.
- 15:05For instance, going back to the example
- 15:08from just a moment ago,
- 15:10the probability vector we saw can be expressed
- 15:13as you see right here.
- 15:15It's basically just an alternative way
- 15:17of expressing vectors
- 15:19that's gonna be very handy
- 15:20for several reasons going forward.
- 15:23And with that notation now in our hands,
- 15:25let's return to the discussion of classical information
- 15:28and probabilistic states, in particular.
- 15:31And let's consider what happens when we measure a system
- 15:34while it's in some probabilistic state.
- 15:38We might not ordinarily refer to a measurement
- 15:40or the act of measuring something in a classical setting,
- 15:43but the term makes sense.
- 15:45In essence, when we talk about measuring the system X
- 15:49in this context,
- 15:50we just mean that we look at it
- 15:51and we recognize whatever state it's in.
- 15:55Of course, when we look at the system,
- 15:57we don't see a probabilistic state,
- 16:00we see a classical state,
- 16:02and the particular classical state that we see
- 16:04is one that we can imagine is chosen randomly
- 16:07according to the probabilities.
- 16:08Now, you might object on philosophical grounds to the idea
- 16:12that the classical state we see
- 16:13is somehow chosen at random
- 16:16at the moment that we measure
- 16:17or we look at the system,
- 16:20the system simply was
- 16:21in some particular classical state all along
- 16:23and we just happen to have learned what the state was,
- 16:27but for the sake of thinking
- 16:28about the mathematical framework we're working with,
- 16:31it's okay to think about it this way
- 16:32and doing so will allow us
- 16:34to draw a parallel with quantum information
- 16:37a little bit later.
- 16:39Let's suppose that the classical state that we see
- 16:42is the classical state a,
- 16:43which could be any state in our set sigma.
- 16:46This changes the probabilistic state of X in general,
- 16:50at least from our point of view.
- 16:52The probabilities no longer have any significance
- 16:54because we now know what the classical state of X is.
- 16:58It's a, and there's no longer any uncertainty about this.
- 17:03So we would now say this that the probability
- 17:06that the system is in the state a is one.
- 17:10We know this because we just looked at it
- 17:12and we saw that the classical state is a,
- 17:15so the new probabilistic state of X is one
- 17:18in which the probability of being in the classical state a
- 17:21is equal to one.
- 17:24And that probabilistic state
- 17:26is represented by the probability vector ket a.
- 17:29We have a one in the entry
- 17:31corresponding to the classical state a
- 17:33and a zero in all other entries.
- 17:36For example, if we again consider the situation
- 17:39where X is a bit
- 17:40and we have the same probabilistic state as before,
- 17:43then if we measure X,
- 17:45we can imagine that a transition takes place.
- 17:50With probability three quarters,
- 17:52we see the classical state zero,
- 17:54and by measuring,
- 17:55we transition to ket zero being our probabilistic state,
- 17:59and with probability one quarter,
- 18:01we transition to ket one.
- 18:04You can think about this
- 18:05as a transition of knowledge if you prefer
- 18:07as opposed to an actual physical transition,
- 18:10but what's important for the sake of this lesson
- 18:13is to recognize how the mathematics works.
- 18:16It's kind of trivial actually,
- 18:17but by recognizing this triviality,
- 18:19the analogous description for the quantum setting
- 18:22might seem a little bit less mysterious.
- 18:26One final note is that to another person
- 18:28who didn't happen to see what the classical state of X was
- 18:31when we measured it,
- 18:33the probabilistic state naturally wouldn't change
- 18:35as a result of us having measured it.
- 18:38That's okay.
- 18:39Different individuals can have different knowledge
- 18:42of a particular system
- 18:43and correspondingly choose different probabilistic states
- 18:46to represent their knowledge of that system.
- 18:50In the last part of this discussion
- 18:52of classical information,
- 18:53we'll talk about classical operations
- 18:55that can be performed on a system,
- 18:57starting with deterministic operations.
- 19:01When we perform an operation on a system,
- 19:03its state generally changes as a result,
- 19:06and in this context,
- 19:07the word deterministic means
- 19:09that the result of performing the operation depends
- 19:12entirely on whatever classical state the system was in
- 19:15prior to the operation being performed.
- 19:19In other words, there's no element of chance
- 19:21when a deterministic operation is performed,
- 19:24so there's no randomness or uncertainty involved.
- 19:28In mathematical terms,
- 19:30deterministic operations are described by functions.
- 19:34Every function f of the form that you see right here,
- 19:37which means that both the input
- 19:39and the output of the function
- 19:40correspond to elements of our classical state set sigma
- 19:44describes a deterministic operation.
- 19:46The classical state a is transformed into the state f of a
- 19:50for each choice of a state a.
- 19:53For every function f of this form,
- 19:55there will always be a unique matrix M
- 19:57satisfying this condition that you see right here,
- 20:00and that is that by multiplying M to the vector ket a
- 20:05gives us the vector ket f of a,
- 20:08and that's true for every choice of a classical state a.
- 20:11It's not too hard to write down an explicit description of M
- 20:14given whatever function f of this form we've chosen.
- 20:17It will always have exactly one, one in each column
- 20:20with every other entry equal to zero.
- 20:22And here's the formula.
- 20:25The b, a entry of M is equal to one
- 20:28if b is equal to f of a
- 20:30and otherwise, it's equal to zero,
- 20:32and by this, we mean this is the entry of M
- 20:36whose row corresponds to b
- 20:37and whose column corresponds to a.
- 20:41We'll see a few examples in just a moment,
- 20:43and we'll see why this formula works.
- 20:46Now, it might not be clear
- 20:48why we would want to take a function
- 20:50and express it as a matrix like this,
- 20:53but it does make sense to do this.
- 20:55One of the reasons,
- 20:56and perhaps, it's the main reason,
- 20:58is that if we have a system in a probabilistic state
- 21:01and we perform a deterministic operation on that system,
- 21:04then the resulting probabilistic state can be obtained
- 21:08by matrix-vector multiplication,
- 21:11i.e., if our system is in a probabilistic state
- 21:14that's represented by some probability vector v
- 21:17and we perform the deterministic operation described by M
- 21:20on that system,
- 21:22then the resulting probabilistic state
- 21:24will be given by M times v.
- 21:27Here, by the way,
- 21:28this arrow with a little bar on it like this
- 21:30is just a common notation in mathematics
- 21:32for indicating how one thing gets mapped to
- 21:35or transformed into another thing.
- 21:38You could just use an ordinary arrow,
- 21:40but this is conventional
- 21:41and it's recognizable
- 21:43and maybe it's a little bit more specific
- 21:45than just an arrow,
- 21:46which could mean many different things.
- 21:49Now let's take a look at an example
- 21:51or a collection of examples, really.
- 21:53Let's consider what happens
- 21:54when we take our classical state set sigma
- 21:57to be once again the binary alphabet.
- 22:00There aren't too many different functions
- 22:01of the form we've been discussing
- 22:03when this is our classical state set
- 22:04and to be more precise,
- 22:06there are just four functions of this form.
- 22:08Here, those four functions are described
- 22:10by their so-called tables of values.
- 22:13The first table describes the first function,
- 22:15which we've named f1.
- 22:18For each possible input on the left,
- 22:21we list the corresponding output on the right,
- 22:24so f1 of zero is equal to zero,
- 22:27and f1 of one is, again, equal to zero,
- 22:30and that is to say that f1 is the constant zero function.
- 22:34It always takes the value zero.
- 22:37The second function f2 is the identity function.
- 22:41The output is always equal to the input
- 22:43as you can see from the second table.
- 22:47The third function f3 is described by the third table.
- 22:50f3 of zero is equal to one,
- 22:52and f3 of one is equal to zero.
- 22:55This function is better known as the not function
- 22:58or logical negation.
- 23:01We sometimes also call it a bit flip
- 23:03because it flips zero to one and one to zero.
- 23:07The last function f4 is, again, a constant function
- 23:10just like the first one,
- 23:12but this one is the constant one function
- 23:14because it always takes the value one.
- 23:17And those are the only four functions
- 23:19from the binary alphabet to itself.
- 23:22Here are the four matrices
- 23:24that correspond to these four functions
- 23:26that are described by the formula from before,
- 23:28which you can see right here,
- 23:31and if you're so inclined,
- 23:32you can pause the video and check this.
- 23:35Just remember that with matrices,
- 23:37the order of the indices
- 23:38is always rows first, column second.
- 23:41So the b, a entry corresponds to row b and column a
- 23:46or the row that corresponds to the classical state b
- 23:50and the column that corresponds to the classical state a.
- 23:54So for example, if we look at the first function,
- 23:57we have the f1 of zero is equal to zero
- 24:01and correspondingly, the zero, zero entry of M1
- 24:05is equal to one.
- 24:06Well, the one, zero entry which is right here
- 24:09is equal to zero,
- 24:12and you can do the same thing for the case
- 24:14where the input is equal to one
- 24:16and similarly, for the other three functions.
- 24:19You can also check that this formula from before is true
- 24:23and you can just go one by one
- 24:24through all the different possibilities to verify this.
- 24:28And in fact,
- 24:29if you think about the way that matrix multiplication works,
- 24:32really you can just kind of eyeball this.
- 24:35When you multiply a matrix
- 24:37to a standard basis factor like this,
- 24:41you can imagine that you're taking the input
- 24:43and dropping it into the top of one of the matrices
- 24:46in whichever column corresponds to the classical state
- 24:49inside of the ket,
- 24:50and the output that you get is simply that column
- 24:53as a probability vector.
- 24:56So for example,
- 24:57M3 multiplied to ket zero gives you zero, one
- 25:02as a probability vector, which is ket one.
- 25:06M3 multiplied to ket one gives you one, zero,
- 25:09which is ket zero and so on.
- 25:13We'll discuss operations on probabilistic states more
- 25:15in just a moment,
- 25:16but first, let's introduce the second part
- 25:18of the Dirac notation.
- 25:21This is gonna be helpful for talking about operations
- 25:23and thinking about them as major Cs,
- 25:25and it's also gonna be a standard tool
- 25:27that we'll continue to use going forward.
- 25:30The setup is just like it was before.
- 25:32We have whatever classical state set sigma
- 25:35that we're working with
- 25:36and we assume
- 25:36that we have some way of ordering those classical states.
- 25:40We then write this thing that you see right here
- 25:42where this time the angled bar is on the left
- 25:45rather than the right to mean the row vector having a one
- 25:49in the entry that corresponds to a and a zero
- 25:52for all of the other entries
- 25:53corresponding to all the other classical states.
- 25:56So the difference between this thing and ket a is that
- 25:59this is a row vector and ket a is a column vector,
- 26:03but otherwise, the vectors are defined in a similar way.
- 26:07We read this as bra a,
- 26:09I'm not sure if that's supposed to be funny,
- 26:11but the idea is that the names bra and ket
- 26:14are two halves of the word bracket,
- 26:16and we'll have more to say about that in just a moment.
- 26:19But first, let's take a look at a very quick example.
- 26:23For the binary alphabet,
- 26:25we have that bra zero is this row vector right here
- 26:28analogous to ket a,
- 26:29except it's a row vector instead of a column vector
- 26:32and bra one is this vector right here.
- 26:37Now in general,
- 26:38if we multiply a row vector to a column vector,
- 26:41just thinking about these as matrices
- 26:43that happen to have just one row or just one column,
- 26:47then we get a one by one matrix,
- 26:49which we can think about as being a scaler.
- 26:52Here, by the way, you should think about these stars
- 26:55as representing arbitrary numbers.
- 26:59In particular, if we multiply the row vector bra a
- 27:03to the column vector ket b,
- 27:05then there are two things that can happen.
- 27:09One is that a and b are equal,
- 27:12so they're the same classical state,
- 27:14in which case, the ones will line up
- 27:16and the product will be equal to one
- 27:21or it could be the case the a and b are different,
- 27:25and so the ones don't line up
- 27:27and the product is equal to zero.
- 27:30A simple way of expressing these observations
- 27:32is like this right here.
- 27:35And just to keep things tidy,
- 27:37we write this product like this
- 27:39with just one bar in the middle
- 27:41and it means exactly the same thing as this right here.
- 27:45And now you can see how the bra and the ket go together
- 27:48to form a bracket, which is also called an inner product,
- 27:52and that's something that's quite important
- 27:54that we'll come back to in lesson number three.
- 27:57Multiplying a column vector to a row vector,
- 28:00on the other hand, gives us a matrix
- 28:02as you can see right here.
- 28:05So for example, going back yet again to the binary alphabet,
- 28:09if we multiply ket zero to bra zero,
- 28:12what we get is this matrix right here,
- 28:16and we can go through the other possibilities
- 28:18to see what happens.
- 28:20Ket zero times bra one gives us this matrix right here
- 28:24where the one has now moved over to this position.
- 28:27Ket one, bra zero looks like this
- 28:30and here's ket one, bra one.
- 28:34What we see happening is that
- 28:35there is just a single one in a matrix
- 28:37that's otherwise all zeros,
- 28:40and the position of that one
- 28:41is determined by which classical states we choose
- 28:44in the bra and the ket.
- 28:47More precisely, and this is true in general,
- 28:49for any choice of a classical state set,
- 28:52the matrix that we get by multiplying ket a to bra b
- 28:56is the matrix with a one in the a, b entry
- 28:59and a zero for all other entries.
- 29:02And now that we have both the first and the second parts
- 29:05of the Dirac notation,
- 29:06we have a very handy tool
- 29:07for connecting operations with matrices.
- 29:10So let's go back briefly to deterministic operations
- 29:14and recall that a bit earlier in the lesson,
- 29:17it was stated that
- 29:18for every function f of this form right here,
- 29:21we have a deterministic operation
- 29:23that transforms a into f of a
- 29:25for each possible classical state a.
- 29:28And we said that for any function like this,
- 29:30there's always a unique matrix M that acts like this
- 29:34on standard basis states.
- 29:37Using the Dirac notation,
- 29:39we can now very easily express this matrix
- 29:41like you see right here,
- 29:43and we can see how sometimes it's possible to work
- 29:47with matrices entirely within the framework
- 29:49of the Dirac notation
- 29:50without ever explicitly converting to vectors and matrices,
- 29:54meaning rectangles filled with numbers.
- 29:56In this case,
- 29:57we can check that the required formula is true
- 30:00by multiplying M to ket a.
- 30:04We substitute our expression for M like this
- 30:07and we can remove the parenthesis
- 30:10and snap together the bra b with a ket a like this.
- 30:14And that's because matrix multiplication is linear,
- 30:17in this case, in the first argument
- 30:19and it's associated
- 30:20so we can remove the parentheses.
- 30:23And now, recalling that we have a fixed a
- 30:26that we're talking about
- 30:28as we sum over all of the possible choices of b,
- 30:31this bracket right here is always gonna be equal to zero
- 30:34when b is not equal to a,
- 30:36so there won't be any contribution to the sum,
- 30:39and when b is equal to a,
- 30:41the bracket will be equal to one
- 30:43and so we'll be left with this one term right here.
- 30:47That's the formula we wanted
- 30:49and so we have a very nice and simple way
- 30:51of expressing a function as a matrix.
- 30:54In addition to deterministic operations,
- 30:56we also have operations that themselves introduce randomness
- 30:59or uncertainty about the classical state of a system.
- 31:03We use the term probabilistic operation
- 31:05to mean operations like this,
- 31:07and to be precise,
- 31:08when we say probabilistic operation,
- 31:11we mean operations that might introduce randomness,
- 31:13so deterministic operations
- 31:15are actually a special case of probabilistic operations
- 31:18that just don't happen to introduce any randomness.
- 31:22Here's a simple example where some randomness is introduced.
- 31:26This is an operation on a single bit.
- 31:29The way that it works is that
- 31:30if the classical state of the bit is a zero,
- 31:32then nothing happens.
- 31:33The bit stays as a zero,
- 31:35but if the classical state of the bit is a one,
- 31:37then the operation flips the bit to zero
- 31:39with probability equal to 1/2.
- 31:43There's no special name for this operation,
- 31:44at least not that I'm aware of.
- 31:46It's just an example,
- 31:47but you could imagine performing this operation on a bit.
- 31:52Just like deterministic operations,
- 31:53probabilistic operations can be represented by matrices
- 31:56and their actions on probabilistic states
- 31:59are given by matrix-vector multiplication
- 32:01just like before.
- 32:04This time, it's not necessarily the case
- 32:06that the matrices have exactly one, one
- 32:07in each column and zeros otherwise.
- 32:11Probabilistic operations are more generally represented
- 32:14by stochastic matrices.
- 32:16These are matrices
- 32:17whose entries are all non-negative real numbers
- 32:20and where the entries in each column sum to one.
- 32:23That's equivalent to saying that stochastic matrices
- 32:25are matrices where every column forms a probability vector.
- 32:30That makes sense
- 32:31when you think about the action of a matrix
- 32:33on a standard basis vector.
- 32:35You consider whatever classical state you wish
- 32:37and you imagine dropping that state
- 32:39into the top of the matrix
- 32:40in whatever column corresponds to that classical state,
- 32:42and that column tells you what the probabilistic state is
- 32:45that comes out as a probability vector.
- 32:50The probabilistic operation in our example, for instance,
- 32:53is described by this matrix right here.
- 32:56If we perform this operation on the classical state zero,
- 32:59then the probabilistic state we get
- 33:01is given by the first column,
- 33:03which is, again, the classical state zero
- 33:05or equivalently, the probabilistic state where zero occurs
- 33:09with probability one.
- 33:11If instead, we perform this operation
- 33:13on the classical state one,
- 33:14then we effectively just randomize the bit
- 33:17and correspondingly, we get this probability vector here
- 33:20where the probability for each of the possible states
- 33:22is equal to 1/2.
- 33:27In general, if we perform this operation
- 33:29on any probabilistic state,
- 33:30then the effect is essentially just a weighted average
- 33:32between the two columns
- 33:34because that's how a matrix-vector multiplication works.
- 33:37It's linear,
- 33:39so we just average the two possible outcomes accordingly.
- 33:44When we think about probabilistic operations in this way,
- 33:46it's natural to think about them as potentially introducing
- 33:49or injecting randomness.
- 33:51We can just read the columns one by one
- 33:53and we can see the randomness that they introduce
- 33:55for each possible classical state.
- 33:58You can also think about probabilistic operations
- 34:00in a slightly different way,
- 34:02which is that they're random choices
- 34:04of deterministic operations.
- 34:07For instance, in our example,
- 34:09we can think about this operation
- 34:12as being equivalent to flipping a fair coin
- 34:14and either performing the constant zero function
- 34:16or the identity function each with probability 1/2,
- 34:20and you can see that reflected right here by this equation.
- 34:24That's always possible for any probabilistic operation,
- 34:27and it's pretty intuitive.
- 34:29If you made random choices as part of some process,
- 34:32you could always imagine
- 34:33making those random choices in advance
- 34:35and then hard coding those choices into some collection
- 34:38of deterministic operations.
- 34:41It's sometimes quite helpful
- 34:42to think about probabilistic operations in this way,
- 34:44and we'll see an example of this down the road
- 34:47in a couple of lessons.
- 34:50The last thing to say about classical information
- 34:52for this lesson concerns composing probabilistic operations,
- 34:55which just means performing one after the other.
- 34:59Let's suppose that we have some system named X
- 35:02and M1 through Mn are stochastic matrices
- 35:05representing probabilistic operations on X.
- 35:10Imagine first that we have a probability vector v,
- 35:12which represents a probabilistic state of X at some moment,
- 35:15and then we first apply
- 35:17the first probabilistic operation to X,
- 35:19which is represented by the matrix M1,
- 35:21and then we apply the second probabilistic operation,
- 35:23which is represented by M2.
- 35:27If we do that, then the probability vector we get
- 35:29after applying just the first operation is M1 times v,
- 35:33and then when we apply the second operation,
- 35:36the resulting probability vector is M2
- 35:38multiplied to whatever vector we obtained
- 35:41after applying M1.
- 35:43So it looks like this.
- 35:45Now, matrix multiplication is an associative operation,
- 35:49which means that it doesn't matter
- 35:50where we put these parentheses.
- 35:52So we could just as easily put the parentheses like this.
- 35:56That's very simple,
- 35:57but it's also interesting
- 35:58because it reveals that we can think about the operation
- 36:02where we first apply M1
- 36:03and then we apply M2 as a single operation.
- 36:08In other words, the probabilistic operation we get
- 36:10by composing the first and second probabilistic operation
- 36:14is represented by the matrix product, M2 times M1,
- 36:17and that's the same operation
- 36:19regardless of what probabilistic state we started with.
- 36:22We don't need to know anything
- 36:23about the probability vector v
- 36:24to think about or to describe this composed operation.
- 36:29Notice that the order here is M2 on the left
- 36:31and M1 on the right,
- 36:33which is because the matrix on the right, M1,
- 36:35is the one that gets multiplied to the vector v,
- 36:37whereas M2 gets multiplied to whatever vector we get
- 36:41after multiplying by M1.
- 36:43So we always have to keep in mind
- 36:45that the order in some sense gets reversed.
- 36:49The operation performed first is the one on the right
- 36:51and the operation that gets performed last
- 36:53or in this case, second, is the one on the left.
- 36:57If we don't stop with the second operation
- 36:59and we apply all of them in order starting with the first
- 37:01and ending with the last one, which is Mn,
- 37:04then the composition of all of these operations together
- 37:06is given by this product that you see right here,
- 37:11and you see that the ordering once again is reversed
- 37:13for exactly the same reason as before.
- 37:17So in short, compositions of probabilistic operations
- 37:19are represented by products of stochastic matrices
- 37:22that represent them.
- 37:23Keeping in mind that this is the ordering of the matrices
- 37:26in the product.
- 37:28You will always get a stochastic matrix
- 37:30by taking a product of stochastic matrices like this,
- 37:33and sometimes we express this fact
- 37:34by saying that the stochastic matrices are closed
- 37:37under multiplication,
- 37:38and the way that you can think about this is
- 37:40that you can't get out of the set of stochastic matrices
- 37:43by multiplying them
- 37:44because the set is closed.
- 37:47Getting back to the ordering of the matrices
- 37:49in this product,
- 37:49it's important to note that the ordering really does matter.
- 37:52Matrix multiplication is not commutative.
- 37:55If you change the ordering of the matrices in the product,
- 37:58you might change the result,
- 38:00and we don't need to look any further
- 38:01than the deterministic operations to see this.
- 38:05Here's a simple example of two stochastic matrices,
- 38:09both of which represent deterministic operations
- 38:11where the ordering matters.
- 38:14M1 represents the constant zero function.
- 38:17Assuming, we're imagining
- 38:18that these two operations are on bits,
- 38:20just like in the example from earlier.
- 38:23M2 represents the not operation or a bit flip.
- 38:29If you perform M1 first and then you perform M2,
- 38:32the result is this matrix right here,
- 38:34which represents the constant one function.
- 38:37If you set a bit to zero and then you flip it,
- 38:39it's the same thing as just setting that bit to one.
- 38:43On the other hand,
- 38:44if you perform M2 first and then you perform M1,
- 38:47this is the result right here,
- 38:50and this makes sense
- 38:51because if you flip a bit and then you set it to zero,
- 38:53it's the same thing as just setting it to zero.
- 38:55It didn't matter that you flipped it.
- 38:58Obviously, these two matrices are not the same,
- 39:00and so we have a very simple example revealing
- 39:03that the order does matter.
- 39:05Of course, this is not surprising at all.
- 39:07We all know
- 39:07that the order in which operations are performed matters
- 39:10or at least, it can matter.
- 39:12For example, if you light a match and then you blow on it,
- 39:15the result is very different from blowing on the match first
- 39:18and then lighting it.
- 39:20At this point,
- 39:21we've talked quite a lot about classical information
- 39:23and now it's finally time to discuss quantum information.
- 39:27And what we'll find is that mathematically speaking,
- 39:30quantum information works in a very similar way
- 39:32to classical information with some key differences.
- 39:37The first key difference is right at the start,
- 39:39how we define a state,
- 39:40in this case, a quantum state of a system,
- 39:44and there is a sense
- 39:45in which this one choice how we define a quantum state
- 39:48largely determines how quantum information works.
- 39:53We'll also define how measurements and operations work,
- 39:56and in the next lesson,
- 39:57we'll discuss how quantum information works
- 39:59not just for single systems but for multiple systems,
- 40:03but these things actually follow pretty naturally
- 40:05once the notion of a quantum state
- 40:07of a single system in isolation has been established.
- 40:11Here's the definition.
- 40:13A quantum state of a system is represented
- 40:16by a column vector
- 40:17whose indices are placed
- 40:18in correspondence with the classical states of that system.
- 40:22So we're assuming here that the system we're talking about
- 40:24has some set of classical states,
- 40:26just like when we talked about classical information
- 40:29and probabilistic states.
- 40:32The entries in a quantum state vector are complex numbers
- 40:34as opposed to the probabilistic case
- 40:36where the entries are non-negative real numbers.
- 40:40And this time,
- 40:41the sum of the absolute values squared of the entries
- 40:43must equal one
- 40:45as opposed to the sum being equal to one
- 40:47as we have in the probabilistic case.
- 40:50The complex numbers that appear in a quantum state vector
- 40:53are sometimes called amplitudes
- 40:55and they play a role that's similar to probabilities,
- 40:57but they aren't probabilities
- 40:59and they don't have the same interpretation.
- 41:03Now, I can't give you a good reason
- 41:05for why quantum states should be defined like this
- 41:07other than to say that physicists have discovered
- 41:10that this definition is physically relevant
- 41:13and it allows us
- 41:14to describe and model quantum mechanical systems.
- 41:18In other words,
- 41:19we choose this definition because it works,
- 41:22not because there are any particular reasons
- 41:24why quantum states should be defined like this.
- 41:29With respect to the mathematics of this notion
- 41:31of a quantum state,
- 41:32the first step towards understanding it
- 41:33and working with it is to recall this definition
- 41:36for the Euclidean norm of a vector,
- 41:39which you can think of geometrically
- 41:40as the length of a vector,
- 41:41just like you would think about the length
- 41:43of a two-dimensional real vector
- 41:45if you drew it on a piece of paper as an arrow
- 41:48starting from the origin in the usual way.
- 41:52Specifically, if we have a column vector v like this,
- 41:55which we assume has complex number entries,
- 41:58alpha one through alpha n,
- 42:00then the Euclidean norm of v is defined
- 42:02like you see right here.
- 42:05This is the notation we use for the Euclidean norm
- 42:07putting these double bars around
- 42:09whatever vector we're talking about.
- 42:11In this case, it's v,
- 42:12and the way the Euclidean norm is defined
- 42:15is that it's the square root of the sum
- 42:17of the absolute values squared of the entries of the vector.
- 42:22So another way to define what a quantum state vector is
- 42:26is that a quantum state vector
- 42:27is a column vector having complex number entries
- 42:30whose Euclidean norm is equal to one,
- 42:33which is to say that it's a unit vector
- 42:35with respect to the Euclidean norm.
- 42:38That's because the sum of the absolute value squared
- 42:41is equal to one
- 42:41if and only if the Euclidean norm is equal to one.
- 42:44The square root doesn't change anything
- 42:46when the sum of the absolute values squared is equal to one.
- 42:50So that's what a quantum state vector is.
- 42:53It's a column vector with indices
- 42:55that correspond to the classical states of a system
- 42:57having complex number entries
- 42:59and Euclidean norm equal to one.
- 43:03What that means or what it implies
- 43:05or how we should interpret this notion is a different matter
- 43:09and in some sense,
- 43:10the study of quantum information and computation
- 43:12is an exploration of what this definition implies,
- 43:15at least, in terms of information processing.
- 43:18This is simply the starting point.
- 43:22As an aside,
- 43:23let me mention that there are other so-called norms
- 43:25besides the Euclidean norm
- 43:27and this notation right here with the double bars
- 43:29around a vector doesn't always mean the Euclidean norm.
- 43:33In different contexts,
- 43:34this notation could refer to a different norm.
- 43:38For example, the sum of the absolute values
- 43:41with no squares or square root is a different norm,
- 43:44often called the one norm.
- 43:46There are quite a lot of different norms, in fact.
- 43:50Sometimes you'll see this notation being used
- 43:52with a subscript after the second set of bars
- 43:54that provides more information
- 43:56about what norm we're talking about.
- 43:58And when we do that,
- 43:59it's pretty typical
- 44:00that the number two as a subscript means the Euclidean norm.
- 44:05But in this series,
- 44:07whenever we have a column vector like this,
- 44:09this double bar notation all by itself
- 44:11means the Euclidean norm.
- 44:14Here are a few examples of quantum state vectors
- 44:17and these particular quantum state vectors
- 44:19are qubit state vectors,
- 44:21which means that the classical states of our system
- 44:23are zero and one.
- 44:26The word qubit is short for quantum bit,
- 44:28which is really just a bit that can be in a quantum state.
- 44:34The first two examples are really simple.
- 44:36The standard basis vectors ket zero and ket one
- 44:39are quantum state vectors.
- 44:42They're both column vectors,
- 44:43and the indices correspond to the classical states
- 44:46is zero and one,
- 44:47and the entries of these vectors are complex numbers.
- 44:51For these particular vectors,
- 44:52the entries are zero and one,
- 44:53which are real numbers,
- 44:55and in fact, they're integers,
- 44:56but they're also complex numbers
- 44:58that happen to have imaginary part equal to zero.
- 45:02Each vector has one entry equal to one
- 45:04and one entry equal to zero.
- 45:06So when we sum the absolute values of the entries,
- 45:09we get one in both cases.
- 45:11So the conditions required for these vectors
- 45:14to be quantum state vectors are satisfied.
- 45:19The next two examples
- 45:20are very commonly encountered qubit states
- 45:22called the plus state and the minus state.
- 45:25They're denoted as you see here on the screen,
- 45:28either with a ket plus or a ket minus like this,
- 45:31and they're defined as you can see right here.
- 45:34Again, the entries of these vectors are complex numbers.
- 45:37This time, they're either positive one
- 45:38over square root of two
- 45:39or negative one over square root of two,
- 45:41and when we sum the absolute values squared,
- 45:43we get 1/2 plus 1/2, which is one.
- 45:47By the way, putting a plus sign or a minus sign
- 45:50inside of a ket like this might seem a little strange
- 45:52because these aren't classical states of our system,
- 45:55but this notation is used nevertheless,
- 45:57and we'll come back to this momentarily.
- 46:00But for now, in short,
- 46:02we can use the Dirac notation
- 46:03to put whatever name we want
- 46:05for a vector inside of a ket.
- 46:06The vector doesn't have to be a standard basis vector
- 46:09when we use the Dirac notation.
- 46:13Here's a final qubit state example for the moment, anyway.
- 46:16It's a quantum state vector of a qubit
- 46:18that doesn't have a special name,
- 46:20and it's not particularly significant.
- 46:23The entries of this vector
- 46:24are one plus two times i over three and negative 2/3.
- 46:29These are complex numbers,
- 46:30and if you compute the absolute values squared
- 46:32of these two entries,
- 46:33you'll get 5/9 for the first one
- 46:35and 4/9 for the second one.
- 46:38So the sum of the absolute value squared is equal to one.
- 46:44And here's one last example.
- 46:45This time for a system whose classical states
- 46:48are the four card suits.
- 46:50I don't know why we would have a system
- 46:52whose classical states are the four card suits
- 46:54being in a quantum state,
- 46:56but it is possible in principle
- 46:58and it's just meant as an example.
- 47:01The entries corresponding to the different suits
- 47:03are 1/2 for clubs, negative i over two for diamonds,
- 47:08zero for hearts
- 47:09because it doesn't appear in the sum
- 47:11and one over square root of two for spades.
- 47:14And here's what it looks like as a column vector,
- 47:17assuming that we've ordered the classical states
- 47:19as we did before,
- 47:21which is the order that you see right here.
- 47:24Taking the absolute value squared of these entries
- 47:26gives one quarter for the first one,
- 47:28also one quarter for the next one.
- 47:30The absolute value squared of zero is equal to zero,
- 47:32so that entry doesn't contribute to the sum.
- 47:34And finally, for the last one, we get 1/2.
- 47:37So the sum is equal to one
- 47:38as is required for this vector to be a quantum state vector.
- 47:44Now just a moment ago,
- 47:45we used the notation ket plus and ket minus
- 47:47to referred to two qubit state vectors
- 47:49that aren't standard basis vectors.
- 47:51And I'd like to return to this point briefly
- 47:53and explain how the Dirac notation is used
- 47:56for arbitrary vectors
- 47:57and not just for standard basis vectors.
- 48:01As I've already mentioned,
- 48:02we can use whatever name we want inside of a bra or ket
- 48:05to refer to a vector.
- 48:07Kets are column vectors and bras are row vectors
- 48:09just like before.
- 48:12As an example, the Greek letter psi is very commonly used
- 48:15inside of a ket
- 48:16to refer to some arbitrary vector,
- 48:18and here, we're using it to give a name to the state vector
- 48:21from before that doesn't have a special name.
- 48:25When we do this,
- 48:26the let our psi doesn't necessarily have any meaning
- 48:28all by itself.
- 48:29It's just the name of a vector,
- 48:30and it's inside of a ket
- 48:32to help us to clarify that it's a column vector.
- 48:36This can be a little bit confusing sometimes,
- 48:37and there is a potential for ambiguity
- 48:40if the letter psi could be associated
- 48:42with a classical state of some system for instance,
- 48:44but it generally doesn't cause any problems,
- 48:48and you don't have to use the Dirac notation like this
- 48:50if you don't want to.
- 48:51Using a lower case letter such as u, v, or w without a ket
- 48:55is also a fine way to denote a column vector
- 48:58or more specifically, a quantum state vector.
- 49:01It's your choice what notation you use to express yourself.
- 49:05You just need to make sure that number one,
- 49:07the meaning of what you are trying to express
- 49:09is clear to others.
- 49:10And number two,
- 49:11that you understand what others are trying to express
- 49:13even when their preferences for notation
- 49:15aren't the same as yours.
- 49:18There is one very important rule
- 49:20for using the Dirac notation for arbitrary vectors
- 49:22and that is that if you have a column vector
- 49:24that you've decided to write as ket psi, for instance,
- 49:27or it could be a different name inside of a ket,
- 49:29then the row vector bra psi
- 49:31is understood to be the conjugate transpose
- 49:33of the vector ket psi.
- 49:35And here, this is written as an equation
- 49:37where this dagger right here
- 49:38refers to the conjugate transpose.
- 49:42What that is specifically is the row vector you get by,
- 49:44number one, transposing the vector,
- 49:46meaning that you flip the vector on its side
- 49:47and you change it from a column into a row
- 49:49without actually changing the entries.
- 49:51And number two,
- 49:52taking the complex conjugate of each of the entries.
- 49:56You can actually perform those two operations,
- 49:58the transpose and the entry-wise complex conjugate
- 50:00in either order or those two operations commute.
- 50:04So for the vector in this example,
- 50:06given that we've decided to call this vector ket psi,
- 50:09it's understood that bra psi means this vector right here
- 50:13where we've transposed the vector
- 50:14by turning ket zero and ket one into bra zero and bra one,
- 50:18and we've taken the complex conjugate of each entry,
- 50:20which is why one plus two times i over three
- 50:23turns into one minus two times i over three right here.
- 50:28Here's what these vectors look like
- 50:29when they're written explicitly as a column vector
- 50:31and a row vector.
- 50:33Notice, by the way, that this rule is consistent
- 50:35with the notation we use
- 50:36when we have classical states inside of the bra and the ket.
- 50:40In that case, the entries are all zero except for one, one,
- 50:43and so taking the complex conjugate doesn't do anything
- 50:45in that case.
- 50:49We've now seen how quantum states
- 50:50are represented as vectors,
- 50:52but it's not clear at this point what the meaning
- 50:54or the implications are
- 50:56in terms of what you can do with the system
- 50:58in a quantum state
- 50:59or how you can interact with it.
- 51:01The first thing we need to do
- 51:02to bring these issues into focus is to discuss measurements.
- 51:07Intuitively speaking, measurements provide a mechanism
- 51:10for extracting classical information from quantum systems.
- 51:14When we look at a system when it's in a quantum state,
- 51:16we don't see a quantum state
- 51:18just like we don't see probabilistic states,
- 51:21we see classical states,
- 51:22and this notion of a measurement
- 51:24is what provides the interface.
- 51:27If we, as humans, want to know something
- 51:29about a quantum system,
- 51:30we have to measure it,
- 51:31and in doing so,
- 51:32we'll extract classical information
- 51:34about whatever quantum state that system was in.
- 51:39There are different notions of measurements.
- 51:40The difference is one of generality really,
- 51:43and we're going to start
- 51:44with the simplest and most basic one,
- 51:46which is typically called a standard basis measurement.
- 51:50We will generalize this in subsequent lessons.
- 51:52We'll talk about so-called projective measurements
- 51:54in lesson three,
- 51:55and then later on in the third unit of the series,
- 51:58we'll talk about general measurements,
- 51:59which are also called positive operator valued measures
- 52:02or POVMs for short.
- 52:05But for now, we'll restrict our attention
- 52:07to standard basis measurements.
- 52:10When a measurement is performed on a system,
- 52:12there will be some set of possible outcomes
- 52:14of that measurement,
- 52:15which are classical outcomes,
- 52:18and in the case of a standard basis measurement,
- 52:20those possible outcomes are precisely the classical states
- 52:23of whatever system is being measured.
- 52:25Each of those classical states
- 52:27will be the outcome of the measurement
- 52:28with some probability,
- 52:29and that probability is the absolute value squared
- 52:32of the entry corresponding to that classical state
- 52:34of whatever quantum state vector the system was in
- 52:37immediately prior to being measured.
- 52:41We know that the absolute value squared
- 52:42of any complex number
- 52:43is a non-negative real number,
- 52:45and we know from the definition of quantum state vectors
- 52:47that the sum of the absolute value squared of the entries
- 52:50of a quantum state vector is equal to one.
- 52:53So this makes sense.
- 52:54Each classical state will appear
- 52:56as the outcome of the measurement with some probability
- 52:58and the probabilities sum to one.
- 53:01Here are a few examples.
- 53:03First, suppose we have a qubit in the plus state.
- 53:07If we measure this qubit
- 53:08with respect to a standard basis measurement,
- 53:10we get either a zero or a one as the outcome.
- 53:14The probability of getting a zero
- 53:15is the absolute value squared of one over root two,
- 53:17which is 1/2,
- 53:19and that's the same probability of getting a one.
- 53:22So if you measure a plus state,
- 53:24you'll get a uniform random bit.
- 53:27If the system is in a minus state rather than a plus state,
- 53:30then measuring works in exactly the same way.
- 53:32The probabilities are, again, 1/2
- 53:34for each possible outcome.
- 53:36The only difference here is that
- 53:38the plus sign turned into a minus sign,
- 53:40but when we take the absolute value, nothing changes.
- 53:44If we measure this qubit state,
- 53:46the probability to get the outcome zero
- 53:48is the absolute value squared
- 53:49of one plus two times i over three, which is 5/9,
- 53:53and the probability to get the outcome one
- 53:54is the absolute value squared of negative 2/3, which is 4/9.
- 54:00And finally, measuring the standard basis state,
- 54:02ket zero gives the outcome zero with certainty,
- 54:05and likewise, measuring the state ket one
- 54:07yields the outcome one with certainty.
- 54:10That's because the absolute value squared of one is one.
- 54:14Similar to what we had in the probabilistic setting.
- 54:16We can associate these quantum states, ket zero in ket one,
- 54:19with the system being in those classical states,
- 54:22and this example is consistent with that interpretation.
- 54:26Now, just like we had in the probabilistic setting,
- 54:29if we measure a system when it's in a quantum state,
- 54:33then the state will change, in general,
- 54:35as a result of having performed that measurement.
- 54:38In particular, and again,
- 54:39this is exactly like we had in the probabilistic setting.
- 54:43If we measure a system
- 54:44and the outcome of the measurement is the classical state a,
- 54:47then the new quantum state of the system becomes ket a.
- 54:51So for this state right here, for instance,
- 54:54we see the same kind of behavior that we had
- 54:56in the probabilistic setting.
- 54:58If we measure then with probability 5/9,
- 55:00we obtain the outcome zero,
- 55:02in which case, the state transitions to ket zero,
- 55:05and with probability 4/9, the outcome is one,
- 55:08and the state transitions to ket one.
- 55:11Sometimes this phenomenon
- 55:12is referred to as a collapse of the quantum state,
- 55:15and it's the kind of thing that keeps people
- 55:17that study the foundations of quantum mechanics
- 55:19awake at night.
- 55:21But from a purely mathematical perspective,
- 55:23it's really quite simple and very much analogous
- 55:26to what we have in the probabilistic case.
- 55:29The source of tension here, in some sense,
- 55:31concerns the fundamental nature of quantum states
- 55:33and what they represent and how they differ
- 55:35from probabilistic states.
- 55:37But at a mathematical level,
- 55:38this is perhaps what you might expect.
- 55:42Notice, by the way, that if you measured a second time,
- 55:45then you would get exactly the same result as you did
- 55:47for the first measurement.
- 55:48So there's a limit on how much classical information
- 55:51can be extracted from a quantum state,
- 55:53and we'll come back to this point soon
- 55:55in another lesson.
- 55:57We've talked about quantum states
- 55:59as well as measurements,
- 56:00specifically standard basis measurements,
- 56:03which provide a way to extract classical information
- 56:05from quantum states.
- 56:08The remaining topic for this lesson is operations,
- 56:11specifically unitary operations,
- 56:13which describe how quantum states of systems
- 56:16can be changed.
- 56:19Naturally, given that quantum state vectors are different
- 56:21from probability vectors,
- 56:22you would expect that set of allowable operations
- 56:25on quantum states is different
- 56:26than what we have for classical information,
- 56:29and indeed, that's the case.
- 56:32Whereas operations on probabilistic states
- 56:35are represented by stochastic matrices,
- 56:37operations on quantum state vectors
- 56:39are represented by unitary matrices.
- 56:43Here's the definition of unitary matrices.
- 56:47A square matrix U having complex number entries is unitary
- 56:50if it satisfies the equalities that you see right here.
- 56:55The dagger represents the conjugate transpose,
- 56:57which we already saw for vectors
- 56:58when we talked about the Dirac notation a few moments ago.
- 57:02Here we're performing the conjugate transpose on a matrix
- 57:05rather than a vector,
- 57:06but it's essentially the same thing.
- 57:10We transpose the matrix,
- 57:11which just means that we swap rows and columns,
- 57:14so the JK entry becomes the KJ entry,
- 57:17and also we take the complex conjugate of each entry.
- 57:21Also, this notation right here means the identity matrix.
- 57:26These two equalities right here are actually equivalent.
- 57:29If you have one, then you automatically have the other.
- 57:32They're both equivalent to saying that you is invertible,
- 57:35and the inverse is equal to the conjugate transpose.
- 57:39That's only true for square matrices, by the way.
- 57:41If you have a matrix that isn't square,
- 57:43then one of those two equalities might be true,
- 57:46but then the other one won't be true.
- 57:49But here, we're talking about square matrices.
- 57:53So this is the standard definition for unitary matrices,
- 57:55and it's nice
- 57:56because it's easy to check if a matrix is unitary.
- 57:59You just multiply the matrix
- 58:01to its conjugate transpose on either side,
- 58:03and you see if you get the identity matrix.
- 58:08There's an equivalent way
- 58:08to characterize unitarian matrices,
- 58:10and that is that a square matrix is unitary
- 58:13if and only if it never changes the Euclidean norm
- 58:16of any vector when you multiply.
- 58:19An N by N matrix U is unitary
- 58:21if and only if the Euclidean norm of U times v
- 58:24is equal to the Euclidean norm v
- 58:26for every n-dimensional column vector v
- 58:28with complex number entries.
- 58:31And therefore, if v is a quantum state vector,
- 58:34then U times v is also a quantum state vector
- 58:36because quantum state vectors
- 58:38are simply the vectors having Euclidean norm equal to one.
- 58:43In fact, we can say a little bit more,
- 58:44which is that the unitary matrices
- 58:46are precisely the matrices
- 58:48that always transform quantum state vectors
- 58:50into quantum state vectors.
- 58:52That's a similar situation to what we have
- 58:54for stochastic matrices and probability vectors.
- 58:56The stochastic matrices are precisely the matrices
- 58:59that always transform probability vectors
- 59:01into probability vectors.
- 59:04So once we've decided that operations
- 59:06should be represented by matrices,
- 59:09which is the same as saying
- 59:09that transformations act linearly
- 59:11on vectors representing states,
- 59:13these choices for the sets of allowable operations
- 59:16follow naturally, at least, in a mathematical sense.
- 59:21Now let's take a look at some examples
- 59:22of qubit unitary operations.
- 59:25We'll see many more examples of unitary operations
- 59:28in subsequent lessons,
- 59:29including unitary operations and systems
- 59:31having more than two classical states.
- 59:34But for now, we'll focus just on qubit unitary operations.
- 59:39We're going to be seeing these particular examples arising
- 59:41again and again,
- 59:42so it's definitely worth getting to know these operations.
- 59:46The first collection of examples
- 59:48are the so-called Pauli operations.
- 59:50These are the operations
- 59:51that correspond to the Pauli matrices,
- 59:53which are shown here.
- 59:56They're all unitary,
- 59:57and you can check that for each one
- 59:58according to the definition from before.
- 1:00:02These particular matrices happen to be equal
- 1:00:04to their own conjugate transposes,
- 1:00:07which is to say that they're all Hermitian matrices.
- 1:00:10So checking that they're all unitary, in this case,
- 1:00:12is a matter of squaring each one
- 1:00:14and seeing that the result is the identity matrix.
- 1:00:19The names you see for these matrices are pretty standard,
- 1:00:21and you'll also see sigma x, sigma y, and sigma z
- 1:00:25called simply X, Y, and Z.
- 1:00:28Do be aware, though, that the capital letters X, Y, and Z
- 1:00:31are also commonly used for other purposes,
- 1:00:33even in the context of quantum information,
- 1:00:36but they are very common names for these matrices.
- 1:00:40The sigma x or X operation is also called a bit flip
- 1:00:44or a not operation,
- 1:00:45which we've already seen in the classical context.
- 1:00:48And the sigma z or Z operation is also called a phase flip.
- 1:00:52And here, you can see the action of these operations
- 1:00:55on the standard basis factors,
- 1:00:57which kind of explains where these names come from.
- 1:01:00Certainly, it makes sense to refer to sigma x as a bit flip
- 1:01:04based on this action right here.
- 1:01:05It simply flips the bit from zero to one or one to zero.
- 1:01:10It also makes sense to call sigma z a phase flip
- 1:01:13based on this action right here.
- 1:01:15But if that's not crystal clear at the moment, that's okay.
- 1:01:18We'll encounter this operation over and over
- 1:01:20and the significance of putting a minus sign
- 1:01:22in front of the ket one basis vector and not ket zero
- 1:01:26and why that's called a phase flip
- 1:01:27will be more clear later on.
- 1:01:30The next example is the Hadamard operation,
- 1:01:32which is represented by this matrix right here,
- 1:01:35which is pretty much always named H.
- 1:01:39Checking that H is unitary
- 1:01:40is once again a straightforward calculation,
- 1:01:42which if I step out of the way,
- 1:01:44you can see right here.
- 1:01:47Similar to the Pauli matrices,
- 1:01:48H is its own conjugate transpose.
- 1:01:50So we have this equality right here,
- 1:01:52and when we perform the multiplication,
- 1:01:54we get the identity matrix as is required.
- 1:02:00The third example is really an entire class
- 1:02:02of unitary operations known as phase operations.
- 1:02:05These are operations represented by any matrix
- 1:02:07that takes this form that you see right here
- 1:02:09where theta is any real number.
- 1:02:12So this entry right here will always be some complex number
- 1:02:15on the unit circle.
- 1:02:18Matrices like this are always unitary,
- 1:02:20which I will leave to you to verify.
- 1:02:23This time, the conjugate transpose
- 1:02:24won't be equal to the original matrix
- 1:02:26unless this number here happens to be a one or a minus one,
- 1:02:29in which case, we end up with either the identity matrix
- 1:02:32or sigma z, which we've already encountered.
- 1:02:36Specifically, transposition won't do anything
- 1:02:38to this matrix,
- 1:02:39but taking the complex conjugate of each entry
- 1:02:41changes this entry right here to e to the minus i theta.
- 1:02:47These two particular operations right here
- 1:02:49are particularly important examples of phase operations.
- 1:02:52For the first one, we take theta to be pi over two,
- 1:02:55and we get this matrix right here.
- 1:02:57This is commonly called an S operation or an S gate
- 1:03:00when we're talking about circuits,
- 1:03:02which we won't discuss in this lesson,
- 1:03:03but that's an important topic that's coming up soon.
- 1:03:07The second one is this operation.
- 1:03:09It's a T operation or a T gate.
- 1:03:11And for this one, theta is equal to pi over four.
- 1:03:13And so when we compute the exponential,
- 1:03:15we get this value right here,
- 1:03:17which is one plus i over the square root of two.
- 1:03:20Here are just a few quick examples
- 1:03:22to see a couple of these operations in action.
- 1:03:25Here's the action of the Hadamard operation
- 1:03:27on ket zero and ket one.
- 1:03:30If we go through the matrix-vector multiplication,
- 1:03:33we see that what we obtain
- 1:03:34are the plus state and the minus state respectively.
- 1:03:38If we perform the Hadamard operation
- 1:03:40on the plus state and the minus state, on the other hand,
- 1:03:43we get back to ket zero and ket one.
- 1:03:47So if we clean things up a little bit,
- 1:03:49we can see the action more clearly.
- 1:03:52The Hadamard operation transforms back and forth
- 1:03:54between the zero state and the plus state
- 1:03:57and between the one state and the minus state.
- 1:04:01Concerning these two equations right here,
- 1:04:03notice that this gives us a simple way
- 1:04:05to detect the difference
- 1:04:06between a plus state and a minus state.
- 1:04:09As we saw earlier in the lesson,
- 1:04:11if we measure a plus state and a minus state
- 1:04:13with respect to the standard basis measurement,
- 1:04:16we get a uniform random bit in both cases,
- 1:04:18which doesn't help us to detect the difference.
- 1:04:22But if we perform a Hadamard operation and then we measure,
- 1:04:26we'll see a zero if the original state was a plus state
- 1:04:28and a one if the original state was a minus state.
- 1:04:32So these two states are indeed different,
- 1:04:34and they can be discriminated perfectly by the method
- 1:04:37that I just described,
- 1:04:38which is to first perform a Hadamard operation
- 1:04:41and then to measure.
- 1:04:44Going back to the example of a qubit state we saw before
- 1:04:47that isn't particularly special,
- 1:04:49we can see what the Hadamard operation does to the state
- 1:04:52by converting to the forms that you see right here
- 1:04:55and performing the multiplication.
- 1:04:57And here is the result which we can convert back
- 1:05:00to the Dirac notation if we wish,
- 1:05:03and that's one way to compute these sorts of actions.
- 1:05:07Here's another example that illustrates
- 1:05:09that you don't always have to convert explicitly
- 1:05:11to a matrix vector form.
- 1:05:13You can also perform these computations directly
- 1:05:15using the Dirac notation.
- 1:05:18This example concerns the T operation,
- 1:05:21and here it is right here just for reference.
- 1:05:25This operation has this action right here
- 1:05:27on standard basis states.
- 1:05:30And if we want to compute the action of the T operation
- 1:05:32on a plus state, for instance,
- 1:05:34we can start by expanding the definition of the plus state
- 1:05:38and then use linearity to express the result
- 1:05:40as you see right here.
- 1:05:43We can now just plug in these expressions up here,
- 1:05:46do just a little bit of simplification for the second term,
- 1:05:49and we obtain the result.
- 1:05:53If for whatever reason
- 1:05:54we'd like to apply a Hadamard operation to the result,
- 1:05:57we can do a similar thing.
- 1:06:00First, we substitute the expression for T
- 1:06:03acting on the plus state
- 1:06:04and we use linearity like we did before.
- 1:06:07And now, if we substitute the expressions we already have
- 1:06:10for the Hadamard operation acting on ket zero and ket one,
- 1:06:14we obtain this.
- 1:06:17And now, we can expand the plus state and the minus state
- 1:06:20to get this expression right here,
- 1:06:22which we can simplify just by adding,
- 1:06:24and here is the final result.
- 1:06:27There's nothing particularly special about this example.
- 1:06:30It's just meant to illustrate this alternative
- 1:06:32but equivalent way of calculating the actions
- 1:06:34of these operations.
- 1:06:36You can use whichever way is more convenient
- 1:06:38in the situation at hand.
- 1:06:40One final point about unitary operations is that
- 1:06:43compositions of unitary operations are represented
- 1:06:46by matrix multiplication
- 1:06:48just like in the probabilistic setting,
- 1:06:52i.e., you can compute the action
- 1:06:53of a sequence of unitary operations
- 1:06:55by simply multiplying the matrices together.
- 1:06:58And what you'll get is a single unitary matrix
- 1:07:00representing the combined action
- 1:07:02of the sequence of operations.
- 1:07:05Just like we had for stochastic matrices,
- 1:07:08the unitary matrices are closed under multiplication,
- 1:07:11so you'll always get a unitary matrix
- 1:07:13when you compose unitary operations.
- 1:07:17You have to make sure you multiply the matrices
- 1:07:18in the correct order.
- 1:07:20But the way it works
- 1:07:21is just like it was for stochastic operations
- 1:07:23where the matrix for the first operation you perform
- 1:07:26will always appear
- 1:07:26on the right-hand side of the matrix product,
- 1:07:28and the last one will appear on the left-hand side.
- 1:07:32So just like before,
- 1:07:33the order is reversed in the sense
- 1:07:35that you compose from right to left
- 1:07:37rather than left to right.
- 1:07:41Here's an interesting example
- 1:07:42that gives rise to an operation
- 1:07:44known as the square root of not operation.
- 1:07:48Suppose that we first apply a Hadamard operation
- 1:07:51followed by an S operation,
- 1:07:53followed by another Hadamard operation.
- 1:07:56The combined action of these three operations
- 1:07:58is described by this product.
- 1:08:00Here's the first Hadamard operation,
- 1:08:02here's the S operation,
- 1:08:04and here's the second Hadamard operation.
- 1:08:08If we perform the matrix multiplication,
- 1:08:10which isn't shown here explicitly,
- 1:08:11but you can do this for yourself if you wish,
- 1:08:14the result is this matrix right here.
- 1:08:17It's a unitary matrix,
- 1:08:19and we can either check that directly
- 1:08:20or we can trust in the fact
- 1:08:22that the unitary matrices are closed under multiplication.
- 1:08:25It has to be unitary
- 1:08:27because these three matrices are unitary
- 1:08:29as we've already seen.
- 1:08:32We don't have any particular quantum state vector
- 1:08:34in mind here.
- 1:08:35We can imagine performing this sequence of operations
- 1:08:38on any quantum state vector,
- 1:08:39and this matrix describes the action.
- 1:08:44The reason why this combined operation,
- 1:08:46meaning the one described by this matrix right here
- 1:08:49is called a spirit of not operation,
- 1:08:51is that by performing it twice, we get a not operation,
- 1:08:54or in other words, a sigma x or an X operation.
- 1:08:59Performing the operation twice is represented
- 1:09:01by squaring the matrix or multiplying it to itself.
- 1:09:04And if you do this,
- 1:09:05you'll see that the result is the Pauli x matrix.
- 1:09:09And that's kind of peculiar,
- 1:09:10and it gives you just a hint
- 1:09:12that you can do some interesting things
- 1:09:14with quantum information
- 1:09:15that you can't do with classical information.
- 1:09:18There's no classical operation,
- 1:09:20meaning one represented by a stochastic matrix
- 1:09:23that gives us a not operation if we perform it twice.
- 1:09:26So it's a nice example that reveals
- 1:09:28that quantum operations behave very differently
- 1:09:31from classical operations.
- 1:09:33And that's it for lesson one.
- 1:09:35In this lesson,
- 1:09:36we discussed how quantum information works
- 1:09:38for single systems in isolation,
- 1:09:41and in the next lesson,
- 1:09:42we'll talk about how quantum information works
- 1:09:44for multiple systems.
- 1:09:46Thanks for watching.
- 1:09:47If you have any questions,
- 1:09:48feel free to leave them in the comments section below.
About this transcript
This page contains the full transcript of Single Systems | Understanding Quantum Information & Computation | Lesson 01 by Qiskit, generated from the public captions YouTube serves with the video. The transcript has 11,834 words across 1,677 segments, with the original timestamps preserved so you can click any line to jump to that moment in the embedded player.
What you can do with it
Use the transcript to take notes, quote the speaker, build a study guide, generate a summary with ChatGPT or Claude via the YouTube Summary tool, or export it as a timed subtitle file with YouTube to SRT. You can also re-open it in the transcriber to translate the transcript into 100+ languages.
Free YouTube transcript tool
YouTube2Text is a free YouTube transcript generator — no signup, no daily limit. Paste any YouTube link and get the full transcript instantly, with timestamps, click-to-jump, translation to 100+ languages, AI prompts for ChatGPT, Claude, and Gemini, and exports to TXT, SRT, VTT, or Markdown.