{"id":20930175,"url":"https://github.com/dpbm/bloch","last_synced_at":"2026-04-20T21:32:53.156Z","repository":{"id":261344709,"uuid":"884034269","full_name":"Dpbm/bloch","owner":"Dpbm","description":"Understanding Bloch Sphere rotations","archived":false,"fork":false,"pushed_at":"2024-11-06T17:03:24.000Z","size":645,"stargazers_count":0,"open_issues_count":0,"forks_count":0,"subscribers_count":1,"default_branch":"main","last_synced_at":"2025-12-30T03:12:35.116Z","etag":null,"topics":["bloch-sphere","experiment","quantum-computing","quatum","qutip"],"latest_commit_sha":null,"homepage":"https://dpbm.github.io/bloch/","language":"Python","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":null,"status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/Dpbm.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":null,"code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null}},"created_at":"2024-11-06T02:38:21.000Z","updated_at":"2024-11-06T17:03:27.000Z","dependencies_parsed_at":"2025-01-19T19:02:38.538Z","dependency_job_id":null,"html_url":"https://github.com/Dpbm/bloch","commit_stats":null,"previous_names":["dpbm/bloch"],"tags_count":0,"template":false,"template_full_name":null,"purl":"pkg:github/Dpbm/bloch","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Dpbm%2Fbloch","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Dpbm%2Fbloch/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Dpbm%2Fbloch/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Dpbm%2Fbloch/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/Dpbm","download_url":"https://codeload.github.com/Dpbm/bloch/tar.gz/refs/heads/main","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Dpbm%2Fbloch/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":286080680,"owners_count":32067416,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2026-04-20T21:26:33.338Z","status":"ssl_error","status_checked_at":"2026-04-20T21:26:22.081Z","response_time":94,"last_error":"SSL_connect returned=1 errno=0 peeraddr=140.82.121.6:443 state=error: unexpected eof while reading","robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":false,"can_crawl_api":true,"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":["bloch-sphere","experiment","quantum-computing","quatum","qutip"],"created_at":"2024-11-18T21:29:38.339Z","updated_at":"2026-04-20T21:32:53.102Z","avatar_url":"https://github.com/Dpbm.png","language":"Python","funding_links":[],"categories":[],"sub_categories":[],"readme":"# BLOCH SPHERE ROTATIONS\n\n\nhttps://github.com/user-attachments/assets/8e590dea-a3be-4980-ae6c-c86ab52ca006\n\n\n\n\nSince I started in quantum computing, Bloch sphere rotations were a big trouble to me. It was easy to get stuck, or simply don't understand what was happening.\n\nSo, today I decided to test some rotations and understand it better.\n\nFirst of all, `Quirk` was a great deal to me. If you visit [Quirk's website](https://algassert.com/quirk), you'll see a bunch of stuff before you. However, the greatest feature of this simulator, is the gates explanation when you keep your mouse over each operator. In my case, looking at the explanation of `Z`, `X`, `H` and `Y` gates made all the difference to me.\n\n![quirk X gate](./quirk-x.png)\n![quirk Z gate](./quirk-z.png)\n![quirk H gate](./quirk-h.png)\n![quirk Y gate](./quirk-y.png)\n\nThe great thing about those descriptions are those tiny arrows pointing to the rotation direction. This way, was possible to understand how it works.\n\nAlthough the understanding was reached, I needed to test with some some. For that, I prepared a Qutip snippet a plot the vector onto a 3d Bloch Sphere.\n\n![Rotations](./rotations.png)\n\n## Rotations Summary\n\n### RX\n\nThe RX rotation is the same as fixing the vector from the origin to the farthest point in the X axis, then rotating everything around by some angle.\n\n### RY\n\nThe RY rotation is the same as fixing the vector from the origin to the farthest point in the Y axis, then rotating everything around by some angle.\n\n### RZ\n\nThe RZ rotation works the same way as the others, however this time we need to use a initial state in half superposition to visualize the state transition, rotating the states in the horizontal axis unlike its counterparts.\n\n## Setup\n\nFor this experiment, you may start explore the Quirk simulator visiting [algassert.com/quirk](https://algassert.com/quirk). Then, locally you need to install:\n\n* python 3.10\n* pip\n* ffmpeg\n\ninstall the dependencies:\n\n```bash\npip install -r requirements.txt\n```\n\nafter that, You're ready to run:\n\n```bash\npython plots.py\n\n# and\n\npython animate.py\n```\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fdpbm%2Fbloch","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fdpbm%2Fbloch","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fdpbm%2Fbloch/lists"}