diff --git a/src/master/COMP90084.md b/src/master/COMP90084.md index 60fc2387..805f475c 100644 --- a/src/master/COMP90084.md +++ b/src/master/COMP90084.md @@ -161,7 +161,7 @@ tag: - 基于量子力学的计算机学说 - 量子化学,量子深度学习 - 后量子密码学 -- Physical Qbits: +- Physical Qubits: - Particles with polarization(photon) 光子 - Trapped ions 离子阱 - Cold Atoms 冷原子 @@ -194,7 +194,19 @@ tag: - being simultaneously in all states - detect the state with probability $x_i = \frac{|c_i|^2}{\sum_{i=0}^{n} |c_i|^2}$ - when observed, it will collapse to one of the basic states -- 设$\Omega$是一个可观测量,$|\psi\rangle$是一个量子态。如果测量的结果是特征值$\lambda$,则测量后的量子态将始终是对应于$\lambda$的特征向量。 + +- 時間反演對稱 + - $UU^\dagger = I$ + - $U^\dagger U = I$ + - $|\psi\rangle = U|\phi\rangle$ + - $\langle\psi| = \langle\phi|U^\dagger$ + - $\langle\phi|\psi\rangle = \langle\phi|U^\dagger U|\psi\rangle$ +- 模不变 + - 量子态的模的表示: $\langle\psi|\psi\rangle$ + - $\langle\psi|\psi\rangle = \langle\phi|U^\dagger U|\phi\rangle = \langle\phi|\phi\rangle$ + - $|\psi\rangle$ 和 $|\phi\rangle$ 的模相等 + +- 设$\Omega$是一个可观测量,$|\psi\rangle$是一个量子态。如果测量的结果是特征值$\lambda$,则测量后的量子态将始终是对应于$\lambda$的特征向量 - superposition 叠加: $|\psi\rangle \longmapsto \alpha|0\rangle + \beta|1\rangle$ - $\alpha$ and $\beta$ are complex amplitudes 复振幅 @@ -207,10 +219,15 @@ tag: - determine how likely a start state will change to an end state (after measurement) - entanglement 纠缠 - connect two qubits using a gate - - Bell state: $|\Phi^+\rangle = \frac{|00\rangle + |11\rangle}{\sqrt{2}}$ - - Bell state: $|\Phi^-\rangle = \frac{|00\rangle - |11\rangle}{\sqrt{2}}$ - - Bell state: $|\Psi^+\rangle = \frac{|01\rangle + |10\rangle}{\sqrt{2}}$ - - Bell state: $|\Psi^-\rangle = \frac{|01\rangle - |10\rangle}{\sqrt{2}}$ +- Bell state + - 量子比特间的强纠缠关系 + - $|\Phi^+\rangle = \frac{|00\rangle + |11\rangle}{\sqrt{2}}$ + - 两个量子比特要么都在状态 $|0\rangle$,要么都在状态 $|1\rangle$,且这两种情况的概率相等 + - 最大纠缠态,两个量子比特的状态之间没有相位差,量子态无法分解成两个量子态的直积 + - $|\Phi^-\rangle = \frac{|00\rangle - |11\rangle}{\sqrt{2}}$ + - 两个量子比特的状态之间存在一个相位差 + - $|\Psi^+\rangle = \frac{|01\rangle + |10\rangle}{\sqrt{2}}$ + - $|\Psi^-\rangle = \frac{|01\rangle - |10\rangle}{\sqrt{2}}$ ## 3. Quantum Architecture, Classical, Reversible and Quantum Gates @@ -222,15 +239,40 @@ tag: - AND: 1 if both are 1 - $\begin{bmatrix} 1 & 1 & 1 & 0 \\ 0 & 0 & 0 & 1 \end{bmatrix}$ - OR: 1 if either is 1 + - $\begin{bmatrix} 1 & 0 & 0 & 0 \\ 0 & 1 & 1 & 1 \end{bmatrix}$ - NAND: 0 if both are 1 + - NOT $\star$ AND + - $\begin{bmatrix} 0 & 1 \\ 1 & 0 \end{bmatrix} \begin{bmatrix} 1 & 1 & 1 & 0 \\ 0 & 0 & 0 & 1 \end{bmatrix} = \begin{bmatrix} 0 & 0 & 0 & 1 \\ 1 & 1 & 1 & 0 \end{bmatrix}$ - XOR: 1 if either is 1, but not both - -- bloch sphere 用于表示量子比特状态的几何图形 + - NOT $\star$ OR + - $\begin{bmatrix} 0 & 1 \\ 1 & 0 \end{bmatrix} \begin{bmatrix} 1 & 0 & 0 & 0 \\ 0 & 1 & 1 & 1 \end{bmatrix} = \begin{bmatrix} 0 & 1 & 1 & 1 \\ 1 & 0 & 0 & 0 \end{bmatrix}$ +- all Quantum gates are reversible +- Toffoli gate: 3 qubits, 2 control and 1 target + - if both control qubits are 1, then the target qubit is flipped + - $\begin{array}{} \ 000 \ 001 \ 010 \ 011 \ 100 \ 101 \ 110 \ 111 \\ \begin{array}{c} 000 \\ 001 \\ 010 \\ 011 \\ 100 \\ 101 \\ 110 \\ 111 \end{array} \begin{bmatrix} 1 & 0 & 0 & 0 & 0 & 0 & 0 & 0 \\ 0 & 1 & 0 & 0 & 0 & 0 & 0 & 0 \\ 0 & 0 & 1 & 0 & 0 & 0 & 0 & 0 \\ 0 & 0 & 0 & 1 & 0 & 0 & 0 & 0 \\ 0 & 0 & 0 & 0 & 1 & 0 & 0 & 0 \\ 0 & 0 & 0 & 0 & 0 & 1 & 0 & 0 \\ 0 & 0 & 0 & 0 & 0 & 0 & 0 & 1 \\ 0 & 0 & 0 & 0 & 0 & 0 & 1 & 0 \end{bmatrix} \end{array}$ + - $$ +- Fredkin gate: 3 qubits, 1 control and 2 target + - if the control qubit is 1, then the target qubits are swapped + - $\begin{array}{} \ 000 \ 001 \ 010 \ 011 \ 100 \ 101 \ 110 \ 111 \\ \begin{array}{c} 000 \\ 001 \\ 010 \\ 011 \\ 100 \\ 101 \\ 110 \\ 111 \end{array} \begin{bmatrix} 1 & 0 & 0 & 0 & 0 & 0 & 0 & 0 \\ 0 & 1 & 0 & 0 & 0 & 0 & 0 & 0 \\ 0 & 0 & 1 & 0 & 0 & 0 & 0 & 0 \\ 0 & 0 & 0 & 1 & 0 & 0 & 0 & 0 \\ 0 & 0 & 0 & 0 & 1 & 0 & 0 & 0 \\ 0 & 0 & 0 & 0 & 0 & 0 & 1 & 0 \\ 0 & 0 & 0 & 0 & 0 & 1 & 0 & 0 \\ 0 & 0 & 0 & 0 & 0 & 0 & 0 & 1 \end{bmatrix} \end{array}$ + +- bloch sphere 布洛赫球: 用于表示量子比特状态的几何图形 - X, Y axis: $0 \leq \theta \leq 2\pi$ - Z axis: $0 \leq \phi \leq \frac{\pi}{2}$ + - Pauli X: 沿 X 轴旋转 180 度 + - Pauli Y: 沿 Y 轴旋转 180 度 + - Pauli Z: 沿 Z 轴旋转 180 度 + +- phase shift gate: + - $R(\theta) = \begin{bmatrix} 1 & 0 \\ 0 & e^{\theta} \end{bmatrix}$ +- Deutch gate: + - if both control qubits are 1, then apply a phase shift on target + - Jyā, koti-jyā and utkrama-jyā 印度的三角函数 - no-cloning theorem: cannot copy an arbitrary unknown quantum state - 证明:假设可以复制,那么可以通过两个相同的量子比特,得到一个新的固定的量子比特。但这是不可能的 +- transportion + - take $|\psi\rangle$ in first system and nothing in second system, then teleport $|x\rangle$ to second system + - $T(|\psi\rangle \bigotimes |0\rangle) = |\psi\rangle \bigotimes |0\rangle$ - CNOT - control qubit, target qubit @@ -244,6 +286,8 @@ tag: - $|\psi'\rangle = CNOT \cdot |\psi\rangle = \begin{bmatrix} 1 & 0 & 0 & 0 \\ 0 & 1 & 0 & 0 \\ 0 & 0 & 0 & 1 \\ 0 & 0 & 1 & 0 \end{bmatrix} \begin{bmatrix} \alpha \ \beta \ \gamma \ \delta \end{bmatrix} = \begin{bmatrix} \alpha \ \beta \ \delta \ \gamma \end{bmatrix}$ - $|\psi'\rangle = \alpha|00\rangle + \beta|01\rangle + \delta|10\rangle + \gamma|11\rangle$ - Hadamard + - 创建和破坏量子比特的叠加态 + - $H = \frac{1}{\sqrt{2}}\begin{bmatrix} 1 & 1 \\ 1 & -1 \end{bmatrix}$ - Pauli X,Y,Z - $X = \begin{bmatrix} 0 & 1 \\ 1 & 0 \end{bmatrix}$ - X is also called NOT gate @@ -265,15 +309,57 @@ tag: - eigenvectors: - up $|\uparrow\rangle = \psi_{z+} = |0\rangle$ - down $|\downarrow\rangle = \psi_{z-} = |1\rangle$ +- S: 添加一个 $\frac{\pi}{2}$ 的相位 + - $S = \begin{bmatrix} 1 & 0 \\ 0 & i \end{bmatrix}$ +- T: 添加一个 $\frac{\pi}{4}$ 的相位 + - $T = \begin{bmatrix} 1 & 0 \\ 0 & e^{i\frac{\pi}{4}} \end{bmatrix}$ ## 4. Simple Quantum Algorithms +- n Hadamand gates: $H^{\bigotimes n}$ + - $|\psi\rangle = \frac{1}{\sqrt{2^n}}\sum_{i=0}^{2^n-1}|i\rangle$ +- reversible function execution: + - control: $|x\rangle$ --> $U_f$ --> $|x\rangle$ + - target: $|0\rangle$ --> $U_f$ --> $|f(x)\rangle$ - quantum parallelism: exponential numbers were inputted simultaneously, result was given in next clock, by quantum function - given a quantum representation, only one result can be given, not all solutions - the point is: what algorithm can take advantage of quantum mechanism? ## 5. QFT and Quantum Phase Estimation + +- quantum mechanics can solve combinatorial optimization problems + - finding optimal objects that satisfy a certain condition +- Knapsack problem + - given a set of items, each with a weight and a value + - determine the number of each item to include in a collection so that the total weight is less than or equal to a given limit and the total value is as large as possible + - n items + - $x_i$ is 1 if the item is included, 0 otherwise + - $v_i$ is the value of the item + - $W$ is the maximum weight + - maximize $\sum_{i=1}^{n} v_i x_i$ + - subject to $\sum_{i=1}^{n} w_i x_i \leq W$ +- max-cut + - edges have weights + - find a cut that maximizes the sum of the weights of the edges that are cut +- minimum vetec cover + - find the minimum number of vertices that cover all edges +- simulated annealing 模拟退火 + - a probabilistic technique for approximating the global optimum of a given function +- local search (Monte Carlo) + - find solution from neighbors +- Metropolis algorithm + - reproduce annealing process + - $E_i$ is the energy of state $i$ + - if $E_i - E_j > 0$, change current state to state $j$ + - if $E_i - E_j < 0$, change current state to state $j$ with probability $e^{\frac{E_i - E_j}{K_b T}}$ +- quadratic unconstrained binary optimization (QUBO) + - $min \ or \ max \sum_{i=1}^{n} \sum_{j=1}^{n} q_{ij} x_i x_j$ + - subject to $x_i \in \{0, 1\}$ + - $Y = X^T Q X$ + - Q is symmetric or upper triangular + - NP problem + ## 6. Quantum Key Distribution . ## 7. Quantum Principal Component Analysis, QAOA ## 8. Variational Quantum Circuits for Machine Learning