劉漾晴
    • Create new note
    • Create a note from template
      • Sharing URL Link copied
      • /edit
      • View mode
        • Edit mode
        • View mode
        • Book mode
        • Slide mode
        Edit mode View mode Book mode Slide mode
      • Customize slides
      • Note Permission
      • Read
        • Only me
        • Signed-in users
        • Everyone
        Only me Signed-in users Everyone
      • Write
        • Only me
        • Signed-in users
        • Everyone
        Only me Signed-in users Everyone
      • Engagement control Commenting, Suggest edit, Emoji Reply
    • Invite by email
      Invitee

      This note has no invitees

    • Publish Note

      Share your work with the world Congratulations! 🎉 Your note is out in the world Publish Note

      Your note will be visible on your profile and discoverable by anyone.
      Your note is now live.
      This note is visible on your profile and discoverable online.
      Everyone on the web can find and read all notes of this public team.
      See published notes
      Unpublish note
      Please check the box to agree to the Community Guidelines.
      View profile
    • Commenting
      Permission
      Disabled Forbidden Owners Signed-in users Everyone
    • Enable
    • Permission
      • Forbidden
      • Owners
      • Signed-in users
      • Everyone
    • Suggest edit
      Permission
      Disabled Forbidden Owners Signed-in users Everyone
    • Enable
    • Permission
      • Forbidden
      • Owners
      • Signed-in users
    • Emoji Reply
    • Enable
    • Versions and GitHub Sync
    • Note settings
    • Note Insights New
    • Engagement control
    • Make a copy
    • Transfer ownership
    • Delete this note
    • Save as template
    • Insert from template
    • Import from
      • Dropbox
      • Google Drive
      • Gist
      • Clipboard
    • Export to
      • Dropbox
      • Google Drive
      • Gist
    • Download
      • Markdown
      • HTML
      • Raw HTML
Menu Note settings Note Insights Versions and GitHub Sync Sharing URL Create Help
Create Create new note Create a note from template
Menu
Options
Engagement control Make a copy Transfer ownership Delete this note
Import from
Dropbox Google Drive Gist Clipboard
Export to
Dropbox Google Drive Gist
Download
Markdown HTML Raw HTML
Back
Sharing URL Link copied
/edit
View mode
  • Edit mode
  • View mode
  • Book mode
  • Slide mode
Edit mode View mode Book mode Slide mode
Customize slides
Note Permission
Read
Only me
  • Only me
  • Signed-in users
  • Everyone
Only me Signed-in users Everyone
Write
Only me
  • Only me
  • Signed-in users
  • Everyone
Only me Signed-in users Everyone
Engagement control Commenting, Suggest edit, Emoji Reply
  • Invite by email
    Invitee

    This note has no invitees

  • Publish Note

    Share your work with the world Congratulations! 🎉 Your note is out in the world Publish Note

    Your note will be visible on your profile and discoverable by anyone.
    Your note is now live.
    This note is visible on your profile and discoverable online.
    Everyone on the web can find and read all notes of this public team.
    See published notes
    Unpublish note
    Please check the box to agree to the Community Guidelines.
    View profile
    Engagement control
    Commenting
    Permission
    Disabled Forbidden Owners Signed-in users Everyone
    Enable
    Permission
    • Forbidden
    • Owners
    • Signed-in users
    • Everyone
    Suggest edit
    Permission
    Disabled Forbidden Owners Signed-in users Everyone
    Enable
    Permission
    • Forbidden
    • Owners
    • Signed-in users
    Emoji Reply
    Enable
    Import from Dropbox Google Drive Gist Clipboard
       Owned this note    Owned this note      
    Published Linked with GitHub
    1
    • Any changes
      Be notified of any changes
    • Mention me
      Be notified of mention me
    • Unsubscribe
    # IBM 2022 春季量子挑戰賽回顧part 1 **文/徐育兆** 今年的IBM春季量子挑戰賽是以41年前理查費曼提出量子計算時設想的願景,他希望可以用量子計算模擬我們周圍的量子世界的設備,因此今年的挑戰賽四個題目即為模擬化學和多體系統。 ### 試驗材料和多體系統 在這一次的挑戰中參賽中會對一個問題給出量子答案,金屬該如導電? 從經典物理學的角度來看,金屬具有自由電子,使電流很容易流過原子結構,我們在物理的電磁學裡有馬克士威方程來描述這種情況,但是我們可以更深入。 從量子理論的角度來看,我們看到原子的電子是位於金屬內的離散位點之間,這些站點彼此靠近,並且每個站點都具有與其相鄰站點相同的能級,這使電子可以在它們之間輕鬆移動,但是在現實生活中事情變得有點複雜。 這些站點中的每一個我們稱之為“晶格站點”實際上都具有略微不同的能量層級,我們在整個晶格中觀察到的這些細微差異是隨機分佈的,如果位點之間的差異足夠大,電子將通過稱為安德森定位的過程與該位點結合,並且不會再自由移動。 挑戰賽的參與者將從在真正的量子計算機上模擬這些類型的系統的基礎開始,然後擴展到進行獨特的實驗以研究這些電子在不同情況下的反應,參與者將完成研究人員用來更好地理解材料的相同初始步驟。 ### 第一題Trotterization #### Tight-binding Model ![](https://i.imgur.com/9joynpM.png) 這張緊束縛模型的圖片是量子力學用來描述固體材料中的電子電導,在這個模型中,每個原子都被視為一個格子結構且每個粒子都需要能量 $\epsilon_i$去佔據這個位置。每個電子可以消耗 $J$ 穿隧到隔壁,以下哈密頓量可以描述這個模型。 $$\frac{H_{tb}}{ℏ}=\sum_{i}\epsilon_i Z_i+J\sum_{\langle i,j\rangle}(X_iX_j+Y_iY_j)$$ 哈密頓量中的第一項描述了每個位點的能量,第二項則是描述了相鄰晶格位點之間的相互作用能量。 在存在周期性晶格位能的情況下,給定量子的波函數與相鄰的晶格位置重疊,從而產生擴展的布洛赫波函數,在均勻晶格中所有位點能量都相等($\epsilon_i=0$),電子傳播在時間上是線性的,並由連續時間量子隨機行走來描述,這與經典的擴散傳輸形成對比,後者的傳播在時間上呈二次方慢,系統哈密頓量使我們能夠確定量子態如何隨時間演變,這個時間演化由薛定諤方程控制: $$iℏ\frac{∂}{∂t}\vert\psi(t)\rangle=H\vert\psi(t)\rangle$$ 在時間獨立的哈密頓系統下(即哈密頓量不會隨著時間演變),薛丁格方程的解法是以下形式: $$\vert\psi(t)\rangle=e^{\frac{-iHt}{ℏ}}\ \vert\psi(0)\rangle$$ 這個挑戰是要我們研讀在緊束縛哈密頓量下的時間動態,我們為時間演化建立最小化的電路。 #### Trotterization 為了執行這個 Unitary 時間演進電路在量子電腦上,我們勢必要分解 U~tb~(t) 成多個在量子電腦上原生運行的單、雙量子閘,實現此目的的一種方法是 Trotterization,也稱為 Trotter-Suzuki 分解。 #### Building the individual Pauli unitaries 在這個部份我們要建立 ZZ(t), XX(t), and YY(t) ![](https://i.imgur.com/E7CNuRJ.png) #### Clifford gates ![](https://i.imgur.com/HwCu0MT.png) #### 依照題目給的提示完成挑戰 #### *1-a Build subcircuit for XX(t) from single- and two-qubit gates.* ```python= XX_qr = QuantumRegister(2) XX_qc = QuantumCircuit(XX_qr, name='XX') ###EDIT CODE BELOW (add Clifford operator) XX_qc.h(0) XX_qc.h(1) ###DO NOT EDIT BELOW XX_qc.append(ZZ, [0,1]) ###EDIT CODE BELOW (add Clifford operator) XX_qc.h(0) XX_qc.h(1) #XX_qc.s(1) #XX_qc.x(1) #XX_qc.sdg(1) ###DO NOT EDIT BELOW # Convert custom quantum circuit into a gate XX = XX_qc.to_instruction() XX_qc.draw() ``` ![](https://i.imgur.com/kYSEH9s.png) #### *1-b Build a subcircuit for YY(t) from single- and two-qubit gates* ```python=+ YY_qr = QuantumRegister(2) YY_qc = QuantumCircuit(YY_qr, name='YY') ###EDIT CODE BELOW (add Clifford operator) YY_qc.s(0) YY_qc.s(1) ###DO NOT EDIT BELOW YY_qc.append(XX, [0,1]) ###EDIT CODE BELOW (add Clifford operator) YY_qc.sdg(0) YY_qc.sdg(1) ###DO NOT EDIT BELOW # Convert custom quantum circuit into a gate YY = YY_qc.to_instruction() YY_qc.draw() ``` ![](https://i.imgur.com/gZKeicJ.png) #### Building the trotterizated circuit ![](https://i.imgur.com/CMhKNhW.png) 我們要依照上述提供的公式做出題目要的量子電路 ![](https://i.imgur.com/QjWo3FI.png) #### *1-c Create the trotterized circuit and output the unitary associated with the circuit* ```python=+ def U_trotterize(t_target, trotter_steps): qr = QuantumRegister(3) qc = QuantumCircuit(qr) ###EDIT CODE BELOW (Create the trotterized circuit with various number of trotter steps) for i in range(trotter_steps): for i in range(0, num_qubits - 1): qc.append(YY, [qr[i], qr[i+1]]) qc.append(XX, [qr[i], qr[i+1]]) ###DO NOT EDIT BELOW qc = qc.bind_parameters({t: t_target/trotter_steps}) return qi.Operator(qc) ``` 這題完成的關鍵是因為我們不知道我們的電路中要幾次的**trotterizated circuit,所以完成的關鍵為 <font color="#f00">trotter_steps</font> (44~47行)** ![](https://i.imgur.com/PNB0ylA.png) ### 第二題Quantum Random Walks and Localizaion 在這個練習中我們模擬一個有五個位置的緊束縛晶格,首先我們看這個緊束縛的哈密頓量,其中每個位置的能量都相等,做為提醒具有五個位置的緊束縛晶格的哈密頓量是: $$\frac{H_{tb}}{ℏ}=J\sum_{i=0}^{3}(X_iX_{i+1}+Y_iY_{i+1})$$ 緊束縛系統中的粒子傳遞可以用連續時間的量子隨機行走模擬。 量子隨機行走是量子力學,量子隨機行走是粒子從開始點隨機移動的過程,古典隨機行走中,粒子隨著時間 t在位置 r 的機率是是依照著高斯分布。 $$p_{classical}(r,t)\propto e^{\frac{-\vert r\vert^2}{t}}$$ 標準的機率偏差分布隨著時間變動: $σ_{classical}=\sqrt{t}$,量子的性質就像單粒子疊加和干涉的結果,這就是為甚麼導致量子隨機行走跟古典隨機行走不同的原因。 量子隨機行走,我們要找粒子從起點移動到在位置 $r$ 的機率跟隨 Bessel Function $$p_{quantum}(r,t)\propto \vert J_r(2t)\vert^2$$ 粒子在晶格空間中相對起點的傳遞是被平方平均位移量化的 $(x^2 )=∑_ip_i x_i^2$ 其中 $p_i$ 是粒子在位置 $i$ 的機率,一個古典隨機行走的傳遞在時間 $(x^2 )∝t$,QRW 展示了具有均方位移 $(x^2 )∝t2$ 的彈道傳播,這個次方的速度提升跟 Grover 演算法都是相像的! ![](https://i.imgur.com/QLh41jk.png) #### *2-a Append the XX and YY gates to our circuit to create a trotterize time evolution under the tight-binding Hamiltonian.* ```python=1 num_qubits = 5 ## DO NOT EDIT Trot_tb_qr = QuantumRegister(num_qubits) Trot_tb_qc = QuantumCircuit(Trot_tb_qr, name='Trot') ###EDIT CODE BELOW for i in range(4): if i ==0: Trot_tb_qc.append(YY,[i,i+1]) Trot_tb_qc.append(XX,[i,i+1]) if i ==2: Trot_tb_qc.append(YY,[i,i+1]) Trot_tb_qc.append(XX,[i,i+1]) for i in range(4): if i ==1: Trot_tb_qc.append(YY,[i,i+1]) Trot_tb_qc.append(XX,[i,i+1]) if i ==3: Trot_tb_qc.append(YY,[i,i+1]) Trot_tb_qc.append(XX,[i,i+1]) ###DO NOT EDIT BELOW Trot_tb_gate = Trot_tb_qc.to_instruction() Trot_tb_qc.draw() ``` ![](https://i.imgur.com/GVe9GWk.png) 這題要解決的關鍵是我們要用前面了解到的trotterizated circuit去完成,但在要成功得完成這一項問題是要根據前面得公式, $$U(\Delta t)\approx(\prod_{i∈odd}e^{-i\Delta tX_iX_{i+1}}e^{-i\Delta tY_iY_{i+1}})(\prod_{i∈even}e^{-i\Delta tX_iX_{i+1}}e^{-i\Delta tY_iY_{i+1}})$$ 前面得公式有提到奇偶的問題,所以要考慮到奇偶的順序問題。 #### *2b Next, we want to add a particle in the form of an excitation to qubit 0. This can be accomplished by applying an 𝑋 gate to flip the state of the qubit from |0⟩ to |1⟩ before time evolution under the Hamiltonian.* ```python=+ delta_t=0.15 # DO NOT EDIT time_steps=np.arange(1,20,1) # DO NOT EDIT circuits=[] for n_steps in time_steps: qr = QuantumRegister(num_qubits) cr = ClassicalRegister(num_qubits) qc = QuantumCircuit(qr,cr) ###EDIT CODE BELOW qc.x(0) ###DO NOT EDIT BELOW for _ in range(n_steps): qc.append(Trot_tb_gate, [i for i in range(num_qubits)]) qc = qc.bind_parameters({t: delta_t}) circuits.append(qc) ``` 這題就比較簡單只要根據題目要的放入X閘即可 #### Anderson localization 粒子的傳遞被混亂的能量影像將會導致 Anderson 定位 晶格的不均勻性導致散射跟量子干涉,這往往抑制粒子傳遞,這是一個局部化的特徵。 這個局部的波函數將從起點迅速遞減,有效的限制粒子在晶格的小區域。飛利浦安格森在1958第一個發表無序的晶格散射是可以使粒子傳播完全停止。 在安格森之前的研究,科學家將水晶無序的見磨成隨機的電子散射擾動,把電子視為一個點粒子,這個邏輯導致對布朗運動等介質中的描述,這是歐姆定律的基礎,然而安格森重新審視無序的在其他週期性的晶體中電子傳遞演化對波函數的影響。 安格森分析了量子體制的問題,因此從根本上解釋了電子的波動性,並發現電子的經典擴散運動在廣泛的條件下隨著電子波函數的指數局部化而分解。 當電子一開始被放在一個原子上,他的波函數將隨著時間推移不再擴大到整個晶體了,但是他還是會持續再起點附近。 因此這個材料將停止導電成為絕緣體,這種局部化現像是由晶格缺陷對電子的多次散射引起的不同路徑之間干涉的直接結果,我們可以使用緊束縛哈密頓量研究安格森局部化,在位點能量無序的情況下,Hamltonian 採用以下形式: $$\frac{H_{tb}}{ℏ}=\sum_{i=0}^{3}(X_iX_{i+1}+Y_iY_{i+1})+\sum_{i}\epsilon_i Z_i$$ #### *2c First, extract the probabilities of each qubit being in the |1⟩ at different times using the output state from the statevector_simulator.* 這題的解決方法是提取出statevector_simulator計算後|1⟩的機率 ![](https://i.imgur.com/Rmb790Y.png)

    Import from clipboard

    Paste your markdown or webpage here...

    Advanced permission required

    Your current role can only read. Ask the system administrator to acquire write and comment permission.

    This team is disabled

    Sorry, this team is disabled. You can't edit this note.

    This note is locked

    Sorry, only owner can edit this note.

    Reach the limit

    Sorry, you've reached the max length this note can be.
    Please reduce the content or divide it to more notes, thank you!

    Import from Gist

    Import from Snippet

    or

    Export to Snippet

    Are you sure?

    Do you really want to delete this note?
    All users will lose their connection.

    Create a note from template

    Create a note from template

    Oops...
    This template has been removed or transferred.
    Upgrade
    All
    • All
    • Team
    No template.

    Create a template

    Upgrade

    Delete template

    Do you really want to delete this template?
    Turn this template into a regular note and keep its content, versions, and comments.

    This page need refresh

    You have an incompatible client version.
    Refresh to update.
    New version available!
    See releases notes here
    Refresh to enjoy new features.
    Your user state has changed.
    Refresh to load new user state.

    Sign in

    Forgot password

    or

    By clicking below, you agree to our terms of service.

    Sign in via Facebook Sign in via Twitter Sign in via GitHub Sign in via Dropbox Sign in with Wallet
    Wallet ( )
    Connect another wallet

    New to HackMD? Sign up

    Help

    • English
    • 中文
    • Français
    • Deutsch
    • 日本語
    • Español
    • Català
    • Ελληνικά
    • Português
    • italiano
    • Türkçe
    • Русский
    • Nederlands
    • hrvatski jezik
    • język polski
    • Українська
    • हिन्दी
    • svenska
    • Esperanto
    • dansk

    Documents

    Help & Tutorial

    How to use Book mode

    Slide Example

    API Docs

    Edit in VSCode

    Install browser extension

    Contacts

    Feedback

    Discord

    Send us email

    Resources

    Releases

    Pricing

    Blog

    Policy

    Terms

    Privacy

    Cheatsheet

    Syntax Example Reference
    # Header Header 基本排版
    - Unordered List
    • Unordered List
    1. Ordered List
    1. Ordered List
    - [ ] Todo List
    • Todo List
    > Blockquote
    Blockquote
    **Bold font** Bold font
    *Italics font* Italics font
    ~~Strikethrough~~ Strikethrough
    19^th^ 19th
    H~2~O H2O
    ++Inserted text++ Inserted text
    ==Marked text== Marked text
    [link text](https:// "title") Link
    ![image alt](https:// "title") Image
    `Code` Code 在筆記中貼入程式碼
    ```javascript
    var i = 0;
    ```
    var i = 0;
    :smile: :smile: Emoji list
    {%youtube youtube_id %} Externals
    $L^aT_eX$ LaTeX
    :::info
    This is a alert area.
    :::

    This is a alert area.

    Versions and GitHub Sync
    Get Full History Access

    • Edit version name
    • Delete

    revision author avatar     named on  

    More Less

    Note content is identical to the latest version.
    Compare
      Choose a version
      No search result
      Version not found
    Sign in to link this note to GitHub
    Learn more
    This note is not linked with GitHub
     

    Feedback

    Submission failed, please try again

    Thanks for your support.

    On a scale of 0-10, how likely is it that you would recommend HackMD to your friends, family or business associates?

    Please give us some advice and help us improve HackMD.

     

    Thanks for your feedback

    Remove version name

    Do you want to remove this version name and description?

    Transfer ownership

    Transfer to
      Warning: is a public team. If you transfer note to this team, everyone on the web can find and read this note.

        Link with GitHub

        Please authorize HackMD on GitHub
        • Please sign in to GitHub and install the HackMD app on your GitHub repo.
        • HackMD links with GitHub through a GitHub App. You can choose which repo to install our App.
        Learn more  Sign in to GitHub

        Push the note to GitHub Push to GitHub Pull a file from GitHub

          Authorize again
         

        Choose which file to push to

        Select repo
        Refresh Authorize more repos
        Select branch
        Select file
        Select branch
        Choose version(s) to push
        • Save a new version and push
        • Choose from existing versions
        Include title and tags
        Available push count

        Pull from GitHub

         
        File from GitHub
        File from HackMD

        GitHub Link Settings

        File linked

        Linked by
        File path
        Last synced branch
        Available push count

        Danger Zone

        Unlink
        You will no longer receive notification when GitHub file changes after unlink.

        Syncing

        Push failed

        Push successfully