Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fix docs/qubits.ipynb as part of docs cleanup for Cirq 1.0 #5179

Merged
merged 3 commits into from
Apr 4, 2022
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
19 changes: 5 additions & 14 deletions docs/qubits.ipynb
Original file line number Diff line number Diff line change
@@ -1,14 +1,5 @@
{
"cells": [
{
"cell_type": "markdown",
"metadata": {
"id": "WZ1G8QHhdHZR"
},
"source": [
"##### Copyright 2020 The Cirq Developers"
]
},
{
"cell_type": "code",
"execution_count": null,
Expand All @@ -18,7 +9,8 @@
},
"outputs": [],
"source": [
"#@title Licensed under the Apache License, Version 2.0 (the \"License\");\n",
"#@title Copyright 2020 The Cirq Developers\n",
"# Licensed under the Apache License, Version 2.0 (the \"License\");\n",
"# you may not use this file except in compliance with the License.\n",
"# You may obtain a copy of the License at\n",
"#\n",
Expand Down Expand Up @@ -75,7 +67,8 @@
"except ImportError:\n",
" print(\"installing cirq...\")\n",
" !pip install --quiet cirq\n",
" print(\"installed cirq.\")"
" print(\"installed cirq.\")\n",
" import cirq"
]
},
{
Expand All @@ -87,7 +80,7 @@
"A qubit is the basic unit of quantum information, a quantum bit: a two level system that can exist in superposition of those two possible states. Cirq also supports higher dimensional systems, so called [qudits](qudits.ipynb) that we won't cover here.\n",
"\n",
"In Cirq, a `Qubit` is nothing else than an abstract object that has an identifier, a `cirq.Qid` and some other potential metadata to represent device specific properties that can be used to validate a circuit.\n",
"In contrast to real qubits, the Cirq qubit does not have any state. The reason for this is that the actual state of the qubit or qubits is maintained in the quantum processor, or, in case of simulation, in the simulated state vector."
"In contrast to real qubits, the Cirq qubit does not have any state. The reason for this is that the actual state of the qubits is maintained in the quantum processor, or, in case of simulation, in the simulated state vector."
]
},
{
Expand All @@ -109,8 +102,6 @@
}
],
"source": [
"import cirq\n",
"\n",
"qubit = cirq.NamedQubit(\"myqubit\")\n",
"\n",
"# creates an equal superposition of |0> and |1> when simulated\n",
Expand Down