{"id":13536082,"url":"https://github.com/Strilanc/Quirk","last_synced_at":"2025-04-02T02:32:15.754Z","repository":{"id":14738237,"uuid":"17459162","full_name":"Strilanc/Quirk","owner":"Strilanc","description":"A drag-and-drop quantum circuit simulator that runs in your browser. A toy for exploring and understanding small quantum circuits.","archived":false,"fork":false,"pushed_at":"2023-01-26T22:54:49.000Z","size":22404,"stargazers_count":880,"open_issues_count":45,"forks_count":153,"subscribers_count":47,"default_branch":"master","last_synced_at":"2024-04-14T12:37:15.932Z","etag":null,"topics":["quantum-circuit","quantum-computing","simulation"],"latest_commit_sha":null,"homepage":"http://algassert.com/quirk","language":"JavaScript","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"apache-2.0","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/Strilanc.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":"CONTRIBUTING.md","funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null}},"created_at":"2014-03-05T23:31:28.000Z","updated_at":"2024-04-11T14:54:11.000Z","dependencies_parsed_at":"2023-02-15T02:32:04.504Z","dependency_job_id":null,"html_url":"https://github.com/Strilanc/Quirk","commit_stats":null,"previous_names":[],"tags_count":16,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Strilanc%2FQuirk","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Strilanc%2FQuirk/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Strilanc%2FQuirk/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Strilanc%2FQuirk/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/Strilanc","download_url":"https://codeload.github.com/Strilanc/Quirk/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":246743880,"owners_count":20826624,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["quantum-circuit","quantum-computing","simulation"],"created_at":"2024-08-01T09:00:34.514Z","updated_at":"2025-04-02T02:32:15.036Z","avatar_url":"https://github.com/Strilanc.png","language":"JavaScript","funding_links":[],"categories":["Quantum SDKs","JavaScript","Quantum simulators"],"sub_categories":[],"readme":"# \u003ca href=\"http://algassert.com/quirk\"\u003eQuirk \u003cimg src=\"doc/favicon.ico\" alt=\"Icon\" title=\"Icon\" /\u003e\u003c/a\u003e\n\n[![Build Status](https://travis-ci.org/Strilanc/Quirk.svg?branch=master)](https://travis-ci.org/Strilanc/Quirk)\n\nQuirk is a toy quantum circuit simulator, intended to help people in learning about quantum computing.\n\nIf you want to quickly explore the behavior of a small quantum circuit, Quirk is the tool for you.\nThere's no installing or configuring or scripting: just go to **[algassert.com/quirk](http://algassert.com/quirk)**, drag gates onto the circuit, and the output displays will update in real time.\n\n(If you're still trying to understand what a quantum circuit *even is*, then I recommend the video series [Quantum Computing for the Determined](https://www.youtube.com/playlist?list=PL1826E60FD05B44E4).\nQuirk assumes you already know background facts like \"each wire represents a qubit\".)\n\n**Defining features**:\n\n- Runs in web browsers.\n- Drag-and-drop circuit editing.\n- Reacts, simulates, and animates in real time.\n- Inline state displays.\n- Bookmarkable / linkable circuits.\n- Up to 16 qubits.\n\n**Notable limitations**:\n\n- Can't recohere measured qubits (because measurement is implemented as a hack based on the [deferred measurement principle](https://en.wikipedia.org/wiki/Deferred_Measurement_Principle)).\n\n**Try it out**:\n\n**[algassert.com/quirk](http://algassert.com/quirk)**\n\n# Examples\n\n**Basic usage demo**:\n\n![Demo](/doc/README_Demo.gif)\n\n**Grover search circuit** with chance and sample displays (showing that the chance of success increases):\n\n![Grover search](/doc/README_Grover.gif)\n\n**Quantum teleportation circuit** with Bloch sphere displays (showing that the qubit at the top has ended up at the bottom):\n\n![Quantum teleportation](/doc/README_Teleportation.gif)\n\n# Building\n\nIf you want to modify Quirk, this is how you get the code and turn your changes into working html/javascript.\n\n1. Have [git](https://git-scm.com/) and [Node.js](https://nodejs.org/en/download/) installed.\n\n    `sudo add-apt-repository universe`\n    \n    `sudo apt-get update`\n    \n    `sudo apt-get install --yes git npm nodejs-legacy`\n\n2. Clone the repository.\n\n    `git clone https://github.com/Strilanc/Quirk.git`\n\n3. Install the dev dependencies.\n\n    `cd Quirk`\n    \n    `npm install`\n\n4. (*Optional*) Make your changes. Run the tests.\n\n    `npm run test-firefox`\n\n5. Build the output.\n\n    `npm run build`\n\n6. Confirm the output works by opening `out/quirk.html` with a web browser.\n\n    `firefox out/quirk.html`\n\n7. Copy `out/quirk.html` to wherever you want.\n\n# Disclaimer\n\nQuirk is not an official Google product.\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2FStrilanc%2FQuirk","html_url":"https://awesome.ecosyste.ms/projects/github.com%2FStrilanc%2FQuirk","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2FStrilanc%2FQuirk/lists"}