From d661051b0f8107a44df16ecb2d1b2bd951a3efa4 Mon Sep 17 00:00:00 2001 From: Mark Date: Sat, 10 Feb 2024 21:03:16 -0800 Subject: [PATCH] Numbering tweak --- Advanced/Introduction to Quantum/main.tex | 17 ++++++++++------- .../Introduction to Quantum/parts/01 bits.tex | 2 +- .../parts/02 two bits.tex | 4 ++-- .../parts/03 half a qubit.tex | 2 +- .../parts/05 logic gates.tex | 4 ++-- .../parts/06 quantum gates.tex | 2 +- resources/ormc_handout.cls | 10 ++++++++++ 7 files changed, 27 insertions(+), 14 deletions(-) diff --git a/Advanced/Introduction to Quantum/main.tex b/Advanced/Introduction to Quantum/main.tex index e186af3..f665a73 100755 --- a/Advanced/Introduction to Quantum/main.tex +++ b/Advanced/Introduction to Quantum/main.tex @@ -30,7 +30,7 @@ \uptitlel{Advanced 2} \uptitler{Winter 2022} -\title{Intro to Quantum Computing} +\title{Intro to Quantum Computing I} \subtitle{Prepared by \githref{Mark} on \today{}} @@ -38,12 +38,15 @@ \maketitle - \input{parts/00.00 bits} - \input{parts/00.01 two bits} - \input{parts/02.00 half a qubit} - \input{parts/02.01 two halves} - \input{parts/03.00 logic gates} - \input{parts/03.01 quantum gates} + \input{parts/00 vectors} + \input{parts/01 bits} + \input{parts/02 two bits} + \input{parts/03 half a qubit} + \input{parts/04 two halves} + \input{parts/05 logic gates} + \input{parts/06 quantum gates} + %\input{parts/03.00 logic gates} + %\input{parts/03.01 quantum gates} %\section{Superdense Coding} %TODO diff --git a/Advanced/Introduction to Quantum/parts/01 bits.tex b/Advanced/Introduction to Quantum/parts/01 bits.tex index 9b7dc16..0c5732b 100644 --- a/Advanced/Introduction to Quantum/parts/01 bits.tex +++ b/Advanced/Introduction to Quantum/parts/01 bits.tex @@ -55,7 +55,7 @@ What is the size of $\mathbb{B}^n$? % NOTE: this is time-travelled later in the handout. % if you edit this, edit that too. -\generic{Remark:} +\cgeneric{Remark} Consider a single classical bit. It takes states in $\{\texttt{0}, \texttt{1}\}$, picking one at a time. \par The states \texttt{0} and \texttt{1} are fully independent. They are completely disjoint; they share no parts. \par We'll therefore say that \texttt{0} and \texttt{1} \textit{orthogonal} (or equivalently, \textit{perpendicular}). \par diff --git a/Advanced/Introduction to Quantum/parts/02 two bits.tex b/Advanced/Introduction to Quantum/parts/02 two bits.tex index a9a7e09..b0be2d0 100644 --- a/Advanced/Introduction to Quantum/parts/02 two bits.tex +++ b/Advanced/Introduction to Quantum/parts/02 two bits.tex @@ -16,7 +16,7 @@ What is the set of possible states of two bits (i.e, $\mathbb{B}^2$)? -\generic{Remark:} +\cgeneric{Remark} When we have two bits, we have four orthogonal states: $\overrightarrow{00}$, $\overrightarrow{01}$, $\overrightarrow{10}$, and $\overrightarrow{11}$. \par We need four dimensions to draw all of these vectors, so I can't provide a picture... \par @@ -42,7 +42,7 @@ with respect to the orthonormal basis $\{\overrightarrow{00}, \overrightarrow{01 -\generic{Remark:} +\cgeneric{Remark} So, we represent each possible state as an axis in an $n$-dimensional space. \par A set of $n$ bits gives us $2^n$ possible states, which forms a basis in $2^n$ dimensions. diff --git a/Advanced/Introduction to Quantum/parts/03 half a qubit.tex b/Advanced/Introduction to Quantum/parts/03 half a qubit.tex index 7a1c6d2..4bdc728 100644 --- a/Advanced/Introduction to Quantum/parts/03 half a qubit.tex +++ b/Advanced/Introduction to Quantum/parts/03 half a qubit.tex @@ -38,7 +38,7 @@ A \textit{normalized vector} (also called a \textit{unit vector}) is a vector wi \end{tcolorbox} -\generic{Remark:} +\cgeneric{Remark} Just like a classical bit, a \textit{quantum bit} (or \textit{qubit}) can take the values $\ket{0}$ and $\ket{1}$. \par However, \texttt{0} and \texttt{1} aren't the only states a qubit may have. diff --git a/Advanced/Introduction to Quantum/parts/05 logic gates.tex b/Advanced/Introduction to Quantum/parts/05 logic gates.tex index 6e1e7b4..abbdbd0 100644 --- a/Advanced/Introduction to Quantum/parts/05 logic gates.tex +++ b/Advanced/Introduction to Quantum/parts/05 logic gates.tex @@ -105,7 +105,7 @@ Find a matrix $A$ so that $A\ket{\texttt{ab}}$ works as expected. \par \vfill \pagebreak -\generic{Remark:} +\cgeneric{Remark} The way a quantum circuit handles information is a bit different than the way a classical circuit does. We usually think of logic gates as \textit{functions}: they consume one set of bits, and return another: @@ -275,7 +275,7 @@ Find the matrix that corresponds to the above transformation. \par \vfill -\generic{Remark:} +\cgeneric{Remark} We could draw the above transformation as a combination $X$ and $I$ (identity) gate: \begin{center} \begin{tikzpicture}[scale=0.8] diff --git a/Advanced/Introduction to Quantum/parts/06 quantum gates.tex b/Advanced/Introduction to Quantum/parts/06 quantum gates.tex index 69b886c..40369c2 100644 --- a/Advanced/Introduction to Quantum/parts/06 quantum gates.tex +++ b/Advanced/Introduction to Quantum/parts/06 quantum gates.tex @@ -127,7 +127,7 @@ If we measure the result of \ref{applycnot}, what are the probabilities of getti \vfill -\generic{Remark:} +\cgeneric{Remark} As we just saw, a quantum gate is fully defined by the place it maps our basis states $\ket{0}$ and $\ket{1}$ \par (or, $\ket{00...0}$ through $\ket{11...1}$ for multi-qubit gates). This directly follows from \ref{qgateislinear}. diff --git a/resources/ormc_handout.cls b/resources/ormc_handout.cls index 12c7fa4..6e97cf0 100755 --- a/resources/ormc_handout.cls +++ b/resources/ormc_handout.cls @@ -576,6 +576,16 @@ \IfNoValueF{#2}{\@customlabel{#2}{#1}} } +% Problem-counter generic object. +% Same format as \problem, \theorem, etc, but has a counter. +\NewDocumentCommand{\cgeneric}{ m d<> }{ + \stepcounter{\@problemcounter} + \par + \vspace{3mm} + {\bf\normalsize #1 \arabic{\@problemcounter}:} \\* + \IfNoValueF{#2}{\@customlabel{#2}{#1}} +} + % Make a new section type. % Args: command, counter, title. \newcommand\@newobj[3]{