Advanced Computing
Architecture, parallelism, HPC, GPUs, and quantum systems.
1200 learning records across 10 categories. Choose a level and build a plan that fits your next goal.
Your subject plan
Explore and verify
Every lesson opens on its own route with its available explanation, lab, practice, and evidence views. Published depth varies; a plan does not imply research mastery or verified completion.
AUTHORED STUDY COMPANION / 3.3
Observe amplification and overshooting
Prerequisites. Normalized state vectors, reflections and amplitude versus probability.
With one marked state among N possibilities, initialize every amplitude to 1/√N. The oracle changes the marked amplitude's sign, and diffusion reflects all amplitudes about their mean. Repeating this pair rotates the state in the plane spanned by marked and unmarked components.
Let θ=arcsin(1/√N). After k iterations the marked probability is sin²((2k+1)θ). More iterations do not always improve success: the state can rotate past the marked direction. The companion applies the sign flip and mean reflection directly, checks normalization, and compares the result with the analytic formula.
The oracle here is an explicitly selected array index. Constructing an oracle for a real problem has a cost that this fixture does not model. The dense classical simulation is an educational reference, not a search speedup. Multiple marked states, noisy gates and unknown solution count require a changed analysis.
| Element | Model | Interpretation |
|---|---|---|
| Oracle | Flip one amplitude sign | Encodes the marked set |
| Diffusion | aᵢ→2mean(a)−aᵢ | Reflection |
| Iteration count | sin²((2k+1)θ) | Oscillatory success |
Predict, run, compare
For N=8, marked index 5 and two iterations, success is 0.9453125. Try five iterations and observe the reduction instead of assuming monotonic improvement.
Download executable notebooks and source Inspect source ↗
Open grover.ipynb in the package. Run cells in order, compare with the reference, then change the stated input. Restart the kernel to reset.
Computed reference result — local CPU fixture
{
"marked_probability": 0.9453124999999998,
"expected": 0.9453125000000001,
"normalization": 0.9999999999999997,
"probabilities": [
0.007812499999999998,
0.007812499999999998,
0.007812499999999998,
0.007812499999999998,
0.007812499999999998,
0.9453124999999998,
0.007812499999999998,
0.007812499999999998
]
}This is the recorded result of the included code under the package environment. It is not a live service or device measurement.
Extend the experiment
Derive the best nearby integer iteration count for N=4,8,16. Include the cost of evaluating the oracle when comparing an actual algorithm.
Check your reasoning: Why can extra Grover iterations reduce success?
- The state rotates past the target direction — Correct. The amplification dynamics are oscillatory.
- Unitary gates destroy normalization — The state remains normalized.
- The oracle becomes classical — The selected oracle is unchanged between iterations.
This is an explained self-check, not a certification of mastery.
Claim-specific sources
- IBM Quantum Learning — Fundamentals of Quantum Algorithms
- Preskill — Quantum Computation lecture notes
Reviewed 2026-10-02: this worked example and its explicit assumptions. Source links and notebook results do not establish production or hardware validation.
AUTHORED STUDY COMPANION / 3.3
Separate order finding from factoring post-processing
Prerequisites. Modular arithmetic, greatest common divisors and even orders.
For coprime a and N, the multiplicative order is the least positive r with aʳ≡1 mod N. If r is even and a^(r/2) is neither +1 nor −1 modulo N, gcd(a^(r/2)−1,N) and gcd(a^(r/2)+1,N) can reveal nontrivial factors. The conditions are part of the argument, not implementation details to skip.
The companion finds r by classical repeated modular multiplication and performs this post-processing. For a=2,N=15 the powers are 2,4,8,1, so r=4; gcd(3,15)=3 and gcd(5,15)=5. It also handles the easy case where gcd(a,N)>1 before order finding.
Shor's quantum algorithm uses a quantum order-finding procedure and classical reconstruction. This notebook implements the arithmetic bridge, not full Shor, reversible modular exponentiation, continued-fraction recovery from sampled phases, or a cryptographically meaningful computation. A demonstration factoring 15 does not establish practical cryptographic resource requirements.
| Element | Model | Interpretation |
|---|---|---|
| Classical precheck | gcd(a,N) | May immediately find a factor |
| Order | Smallest r with aʳ≡1 | Computed classically here |
| Post-processing | Two gcd calculations | Requires nontrivial even-order case |
Predict, run, compare
Run (a,N)=(2,15): order 4 and factors 3,5. Run (4,15): order 2 and the same factors. Identify a base for which the post-processing conditions fail.
Download executable notebooks and source Inspect source ↗
Open order_finding.ipynb in the package. Run cells in order, compare with the reference, then change the stated input. Restart the kernel to reset.
Computed reference result — local CPU fixture
{
"order": 4,
"sequence": [
2,
4,
8,
1
],
"factors": [
3,
5
],
"method": "classical modular order search and Shor post-processing only"
}This is the recorded result of the included code under the package environment. It is not a live service or device measurement.
Extend the experiment
Enumerate valid bases below 15 and classify which succeed by a direct gcd, a useful even order, or no factor from this attempt.
Check your reasoning: This companion implements:
- A full fault-tolerant Shor circuit — No reversible modular-exponentiation circuit is executed.
- Classical order search and factoring post-processing — Correct. Its scope is the inspectable arithmetic bridge.
- A quantum hardware benchmark — Every calculation runs classically on the CPU.
This is an explained self-check, not a certification of mastery.
Claim-specific sources
- IBM Quantum Learning — Fundamentals of Quantum Algorithms
- Preskill — Quantum Computation lecture notes
Reviewed 2026-10-02: this worked example and its explicit assumptions. Source links and notebook results do not establish production or hardware validation.
AUTHORED STUDY COMPANION / 3.3
Compare a variational energy with exact diagonalization
Prerequisites. Hermitian matrices, expectation values and constrained optimization.
Use H=Z⊗I+I⊗Z+0.5X⊗X and normalized ansatz |ψ(θ)⟩=cosθ|00⟩+sinθ|11⟩. Its energy is E(θ)=2cos(2θ)+0.5sin(2θ). The variational principle says a normalized state's energy cannot fall below the exact ground energy; a lower result indicates a convention, normalization or calculation problem.
The even-parity block is [[2,0.5],[0.5,−2]], with eigenvalues ±√4.25. The odd-parity block has eigenvalues ±0.5, so the full ground energy is −√4.25≈−2.061553. The notebook diagonalizes the full 4×4 matrix and separately searches 2,001 ansatz angles. This ansatz can represent the ground state, but the finite grid usually leaves a small positive optimization error.
This is an exact-expectation variational calculation. It has no shot noise, hardware execution or noisy optimizer. A more expressive ansatz is not automatically easier to train. Separate ansatz limitation, optimization error, finite-shot uncertainty and hardware bias when interpreting a real VQE result.
| Element | Model | Interpretation |
|---|---|---|
| Hamiltonian | ZI+IZ+0.5XX | Four-dimensional Hermitian matrix |
| Ansatz | cosθ|00⟩+sinθ|11⟩ | Normalized even-parity states |
| Reference | Exact diagonalization | Checks the variational bound |
Predict, run, compare
The computed energy should lie at or above −√4.25 and within 2×10⁻⁵ for the default grid. Coarsening the grid changes optimization error without changing the Hamiltonian.
Download executable notebooks and source Inspect source ↗
Open vqe.ipynb in the package. Run cells in order, compare with the reference, then change the stated input. Restart the kernel to reset.
Computed reference result — local CPU fixture
{
"theta": 1.6933184402848986,
"variational_energy": -2.0615528083779155,
"exact_ground_energy": -2.0615528128088303,
"error": 4.430914746222925e-09,
"method": "exact expectations; one-parameter grid minimization"
}This is the recorded result of the included code under the package environment. It is not a live service or device measurement.
Extend the experiment
Add an ansatz restriction or a different Hamiltonian term. Explain whether a remaining energy gap is caused by the search grid or by states the ansatz cannot represent.
Check your reasoning: An energy below the exact ground value suggests:
- A guaranteed quantum advantage — It violates the stated variational bound.
- A calculation or normalization error in this model — Correct. The exact reference is a lower bound for normalized states.
- Perfect optimization — Perfect optimization reaches, rather than undercuts, the ground energy.
This is an explained self-check, not a certification of mastery.
Claim-specific sources
- Peruzzo et al. — A variational eigenvalue solver
- IBM Quantum Learning — Fundamentals of Quantum Algorithms
Reviewed 2026-10-02: this worked example and its explicit assumptions. Source links and notebook results do not establish production or hardware validation.
AUTHORED STUDY COMPANION / 3.3
Decode bit-flip syndromes and expose the limit
Prerequisites. Pauli operators, parity and independent error probabilities.
The three-qubit repetition code encodes |0⟩ as |000⟩ and |1⟩ as |111⟩. Stabilizers Z₀Z₁ and Z₁Z₂ reveal parity differences without directly measuring the encoded logical bit. A single X error on qubit 0,1,2 produces syndrome 10,11,01 respectively, which identifies a corrective X in the single-error model.
Under independent bit-flip probability p, a majority decoder fails when two or three qubits flip: 3p²(1−p)+p³=3p²−2p³. The notebook enumerates all eight error patterns, weights their probabilities and verifies that polynomial. Double errors can share a syndrome with a single error and be miscorrected, so a syndrome is not a uniquely identified arbitrary error.
The code does not protect an arbitrary logical state against phase errors. A phase flip can act logically without changing these Z-type check outcomes. General quantum error correction needs complementary information and a noise-aware fault-tolerant measurement procedure; this perfect-syndrome toy does not establish a surface-code threshold.
| Element | Model | Interpretation |
|---|---|---|
| Checks | Z₀Z₁, Z₁Z₂ | Two parity bits |
| Correctable model | At most one X | Distinct nonzero syndromes |
| Failure | Two or three X errors | 3p²−2p³ |
Predict, run, compare
At p=0.1, the logical bit-error probability is 0.028. Compare with physical p=0.1, then test p=0.6 and explain why repetition is not helpful there.
Download executable notebooks and source Inspect source ↗
Open repetition.ipynb in the package. Run cells in order, compare with the reference, then change the stated input. Restart the kernel to reset.
Computed reference result — local CPU fixture
{
"syndromes": {
"000": "00",
"001": "01",
"010": "11",
"011": "10",
"100": "10",
"101": "11",
"110": "01",
"111": "00"
},
"logical_bit_error": 0.02800000000000001,
"expected": 0.028000000000000004,
"phase_errors_corrected": false
}This is the recorded result of the included code under the package environment. It is not a live service or device measurement.
Extend the experiment
Construct two error patterns with the same syndrome but different logical consequences. Explain why repeated noisy measurements require a decoder over both space and time.
Check your reasoning: What does this repetition code fail to protect against?
- Any single bit flip under perfect checks — That is the error model it corrects.
- General phase errors on an arbitrary logical state — Correct. Z-type parity checks alone do not reveal all phase errors.
- Normalization — Normalization is preserved by the Pauli operations.
This is an explained self-check, not a certification of mastery.
Claim-specific sources
- IBM Quantum Learning — Fundamentals of Quantum Algorithms
- Preskill — Quantum Computation lecture notes
Reviewed 2026-10-02: this worked example and its explicit assumptions. Source links and notebook results do not establish production or hardware validation.
AUTHORED STUDY COMPANION / 3.4
Connect scaling bounds, arithmetic intensity and collectives
Prerequisites. Runtime fractions, rates, units, arrays and reductions.
Amdahl's model gives speedup 1/[(1−p)+p/N] for a fixed workload with parallel fraction p. At p=0.8 and N=8, the ideal speedup is 3.333…, not eight. Communication, synchronization, scheduling and memory contention add costs outside this simple upper bound.
The Roofline model bounds attained compute rate by min(peak FLOP/s, bandwidth×arithmetic intensity). Multiplying 100 GB/s by 2 FLOP/byte gives 200 GFLOP/s; a 1,000 GFLOP/s compute ceiling is not attainable at that intensity. The ridge point is peak/bandwidth, here 10 FLOP/byte. Peak and bandwidth must describe the relevant memory level and precision.
The core notebook simulates partitioning integers 1..100 among ranks and summing partial results sequentially. The optional mpi_sum.py actually calls MPI Allreduce when run under mpiexec with mpi4py installed. These are separate execution statuses. A correctness result of 5,050 is not a measured parallel speedup. For performance, record machine, versions, rank placement, warm-up, repetitions and timing boundaries.
| Element | Model | Interpretation |
|---|---|---|
| Amdahl | Serial and parallel time fractions | Scaling upper bound |
| Roofline | min(peak,B×I) | Compute or memory bound |
| Allreduce | Local sums → shared total | Communication semantics |
Predict, run, compare
Defaults yield ideal speedup 10/3, Roofline bound 200 GFLOP/s and reduction result 5,050. Change intensity from 2 to 20 and observe the compute ceiling cap at 1,000.
Download executable notebooks and source Inspect source ↗
Open hpc.ipynb in the package. Run cells in order, compare with the reference, then change the stated input. Restart the kernel to reset.
Computed reference result — local CPU fixture
{
"amdahl_speedup": 3.333333333333334,
"roofline_gflops": 200.0,
"ridge_flops_per_byte": 10.0,
"simulated_reduce": 5050,
"partial_sums": [
91,
260,
429,
598,
702,
846,
990,
1134
],
"communication": "sequential rank simulation; use mpi_sum.py under mpiexec for actual MPI"
}This is the recorded result of the included code under the package environment. It is not a live service or device measurement.
Extend the experiment
Run the optional MPI program on 1,2,4 ranks in a suitable environment. Separate the correctness result from performance and explain why a tiny workload may slow down.
Check your reasoning: At 2 FLOP/byte and 100 GB/s, the bandwidth bound is:
- 200 GFLOP/s — Correct. The units cancel bytes, yielding a compute rate.
- 1,000 GFLOP/s regardless of intensity — That is the separate peak ceiling.
- 50 GB/s — This divides incompatible quantities for the requested bound.
This is an explained self-check, not a certification of mastery.
Claim-specific sources
Reviewed 2026-10-02: this worked example and its explicit assumptions. Source links and notebook results do not establish production or hardware validation.
AUTHORED STUDY COMPANION / 3.6
Optimize one MaxCut edge with p=1 QAOA
Prerequisites. Pauli operators, phase gates, expectation values and classical search.
For one edge, C=(I−Z⊗Z)/2 rewards different measured bits. Starting in |++⟩, apply exp(−iγC) and then exp(−iβX) to each qubit. The notebook searches a grid of angles and computes the exact expected cut value. This two-qubit objective has a classical maximum of one, giving a direct reference.
QAOA alternates a cost unitary with a mixer and uses a classical optimizer, but a tiny exact-expectation grid search does not establish advantage. Increasing depth changes expressivity and optimization cost. Report graph, depth, angle convention, optimizer, sampling and reference solver before comparing larger results.
| Element | Model | Interpretation |
|---|---|---|
| Cost | (I−ZZ)/2 | Reward a cut edge |
| Mixer | Single-qubit X rotations | Move amplitude between assignments |
| Reference | Exact classical maximum =1 | Bound interpretation |
Predict, run, compare
The default 61×61 grid includes angles achieving an expected cut of one to numerical precision. Every energy evaluation uses a normalized state vector.
Download executable notebooks and source Inspect source ↗
Open qaoa.ipynb in the package. Run cells in order, compare with the reference, then change the stated input. Restart the kernel to reset.
Computed reference result — local CPU fixture
{
"expected_cut": 0.9999999999999998,
"gamma": 1.5707963267948966,
"beta": 0.39269908169872414,
"exact_maximum": 1,
"graph": "one unweighted edge; depth p=1"
}This is the recorded result of the included code under the package environment. It is not a live service or device measurement.
Extend the experiment
Extend to a three-node path and compare with enumeration of all classical bit strings. Keep the p=1 and angle conventions explicit.
Check your reasoning: A perfect result on one edge demonstrates:
- A solved small fixture — Correct. The exact reference makes this test inspectable.
- General quantum advantage — No scaling comparison was performed.
- Fault tolerance — No error-correction process was simulated.
This is an explained self-check, not a certification of mastery.
Claim-specific sources
Reviewed 2026-10-02: this worked example and its explicit assumptions. Source links and notebook results do not establish production or hardware validation.
AUTHORED STUDY COMPANION / 3.6
Measure product-formula error
Prerequisites. Matrix exponentials, noncommuting operators and operator norms.
For H=X+Z, the exact propagator is exp(−itH). Because X and Z do not commute, exp(−itX)exp(−itZ) is generally different. The companion splits time into r steps and compares [exp(−itX/r)exp(−itZ/r)]ʳ with an exact eigen-decomposition reference.
Both propagators are unitary to rounding error, so normalization alone cannot show that the approximate dynamics are accurate. Measure the operator-norm difference and inspect refinement at fixed total time. This first-order product formula is a small reference calculation, not a gate-count estimate for arbitrary many-body simulation.
| Element | Model | Interpretation |
|---|---|---|
| Target | exp(−it(X+Z)) | Exact dynamics |
| Approximation | Repeated separated X and Z steps | Noncommutation creates error |
| Checks | Accuracy and unitarity | Different properties |
Predict, run, compare
At t=0.7, compare 16 and 32 steps. The finer result should reduce operator error while both retain tiny unitarity residuals.
Download executable notebooks and source Inspect source ↗
Open hamiltonian.ipynb in the package. Run cells in order, compare with the reference, then change the stated input. Restart the kernel to reset.
Computed reference result — local CPU fixture
{
"operator_error": 0.025868737517101677,
"unitary_residual": 1.4842134205559975e-15
}This is the recorded result of the included code under the package environment. It is not a live service or device measurement.
Extend the experiment
Reverse the factor order, then implement a symmetric half-X/full-Z/half-X step and compare convergence at equal step size.
Check your reasoning: A unitary approximation is necessarily accurate:
- Yes — Unitarity and closeness to the target are different conditions.
- No; it may preserve norm while evolving the wrong state — Correct. The notebook measures their residuals separately.
- Only for complex matrices — Both exact and approximate propagators are complex.
This is an explained self-check, not a certification of mastery.
Claim-specific sources
- IBM Quantum Learning — Fundamentals of Quantum Algorithms
- Preskill — Quantum Computation lecture notes
Reviewed 2026-10-02: this worked example and its explicit assumptions. Source links and notebook results do not establish production or hardware validation.
AUTHORED STUDY COMPANION / 3.6
Check commuting Pauli parity measurements
Prerequisites. Tensor products, Pauli anticommutation and stabilizer syndromes.
The four-data-qubit toy uses checks XXXX, ZZII and IZZI. Each pair commutes: overlapping X and Z factors anticommute at two positions, yielding a positive net sign. An X error on qubit 1 anticommutes with both Z checks but commutes with the X check, producing syndrome (0,1,1).
This calculation teaches check compatibility and syndrome construction. It is not a full surface-code patch, repeated syndrome circuit or decoder. Surface-code analysis also needs boundaries, logical operators, data and measurement noise, code distance, decoding and resource accounting. A commuting set alone does not establish a threshold or fault-tolerant logical gate.
| Element | Model | Interpretation |
|---|---|---|
| Checks | XXXX, ZZII, IZZI | Compatible Pauli observables |
| Error | IXII | One explicit data error |
| Syndrome | Commutation signs | Locates a check violation |
Predict, run, compare
Construct the 16×16 matrices and verify every commutator has norm zero. Insert one X on qubit 1 and obtain syndrome [0,1,1].
Download executable notebooks and source Inspect source ↗
Open stabilizers.ipynb in the package. Run cells in order, compare with the reference, then change the stated input. Restart the kernel to reset.
Computed reference result — local CPU fixture
{
"maximum_commutator": 0.0,
"x_on_qubit_one_syndrome": [
0,
1,
1
],
"scope": "commutation and Pauli syndrome only; no decoder, measurement noise, threshold, or fault-tolerance estimate"
}This is the recorded result of the included code under the package environment. It is not a live service or device measurement.
Extend the experiment
Find an operator commuting with all checks but acting nontrivially on the codespace. Explain why the syndrome can miss a logical operation.
Check your reasoning: A zero syndrome guarantees no logical error:
- Always — Stabilizer checks cannot distinguish every logical state.
- No; a logical operator can commute with all checks — Correct. Logical operators are the key counterexample.
- Only if the display is green — The algebra, not color, determines the syndrome.
This is an explained self-check, not a certification of mastery.
Claim-specific sources
Reviewed 2026-10-02: this worked example and its explicit assumptions. Source links and notebook results do not establish production or hardware validation.
AUTHORED STUDY COMPANION / 3.6
Use T1 and T2 with an explicit noise convention
Prerequisites. Exponential decay, populations, coherence and time units.
In a simple Markovian relaxation-plus-dephasing model, excited-state population decays as exp(−t/T1), while off-diagonal coherence decays as exp(−t/T2). The rates obey 1/T2=1/(2T1)+1/Tφ, so nonnegative pure dephasing requires T2≤2T1. The notebook rejects parameter combinations outside that model.
These quantities are not interchangeable with gate fidelity, readout error, connectivity or logical error rate. Device modalities also have different control and engineering constraints. This companion uses arbitrary consistent time units and fictional parameters; it does not rank current hardware vendors or substitute historical roadmap claims for measured performance.
| Element | Model | Interpretation |
|---|---|---|
| T1 | Population relaxation | Excited-state survival |
| T2 | Coherence decay | Includes relaxation contribution |
| Tφ | Additional dephasing | Nonnegative rate |
Predict, run, compare
For t=20,T1=100,T2=80, population survival is exp(−0.2) and coherence fraction exp(−0.25). T2=250 is rejected under the stated model.
Download executable notebooks and source Inspect source ↗
Open hardware.ipynb in the package. Run cells in order, compare with the reference, then change the stated input. Restart the kernel to reset.
Computed reference result — local CPU fixture
{
"excited_survival": 0.8187307530779818,
"coherence_fraction": 0.7788007830714049,
"pure_dephasing_rate": 0.007500000000000001,
"time_units": "same arbitrary unit for t, T1, T2"
}This is the recorded result of the included code under the package environment. It is not a live service or device measurement.
Extend the experiment
Build a comparison table for two fictional devices using coherence, gates, readout and topology. Show why one long coherence time cannot alone determine algorithm performance.
Check your reasoning: In this model a valid T2 must satisfy:
- T2≤2T1 — Correct. Relaxation contributes at least 1/(2T1) to decoherence.
- T2 is always equal to T1 — Pure dephasing can vary independently.
- T2 has no relation to relaxation — The stated model includes that contribution.
This is an explained self-check, not a certification of mastery.
Claim-specific sources
- National Academies — Quantum Computing: Progress and Prospects (2019; historical foundations)
- Preskill — Quantum Computation lecture notes
Reviewed 2026-10-02: this worked example and its explicit assumptions. Source links and notebook results do not establish production or hardware validation.
AUTHORED STUDY COMPANION / 3.6
Separate heralding probability from conditional fidelity
Prerequisites. Bell states, mixed states and conditional probability.
A Werner link can be written ρ=w|Φ+⟩⟨Φ+|+(1−w)I/4, with Bell fidelity (1+3w)/4. Under the idealized swapping assumptions in this fixture, two independent identical links give visibility w² and conditional fidelity (1+3w²)/4. A separate simplified heralding model has success probability η²/2.
Conditional quality and probability of success answer different questions. Reporting fidelity only after successful heralding does not reveal link throughput or waiting-time effects. This fixture omits memory decay, scheduling, purification, dark counts and imperfect operations, so it is an algebraic networking exercise rather than an engineering rate forecast.
| Element | Model | Interpretation |
|---|---|---|
| Input state | Werner visibility w | Bell fidelity |
| Swap quality | Visibility w² | Independent ideal links |
| Heralding | η²/2 | Separate conditional success model |
Predict, run, compare
For w=0.9 and η=0.5, input fidelity is 0.925, swapped fidelity 0.8575, and heralded success probability 0.125.
Download executable notebooks and source Inspect source ↗
Open network.ipynb in the package. Run cells in order, compare with the reference, then change the stated input. Restart the kernel to reset.
Computed reference result — local CPU fixture
{
"single_link_fidelity": 0.925,
"swapped_fidelity": 0.8575,
"heralded_success": 0.125,
"assumptions": "independent Werner links; ideal swapping conditional on heralding; simplified linear-optical success model"
}This is the recorded result of the included code under the package environment. It is not a live service or device measurement.
Extend the experiment
Add a waiting-time memory-decay factor and compare average delivered fidelity with conditional instantaneous fidelity.
Check your reasoning: High conditional fidelity alone determines delivery rate:
- Yes — Quality conditional on success omits failures and time.
- No; heralding and timing are separate — Correct. Both quantities are needed for an operational estimate.
- Only for classical networks — The distinction also applies to quantum links.
This is an explained self-check, not a certification of mastery.
Claim-specific sources
Reviewed 2026-10-02: this worked example and its explicit assumptions. Source links and notebook results do not establish production or hardware validation.
AUTHORED STUDY COMPANION / 3.6
Compare GHZ and product probes under dephasing
Prerequisites. Parameter estimation, Fisher information and noise assumptions.
For frequency estimation at fixed interrogation time t, this convention gives product-probe QFI Nt²exp(−2γt) and GHZ-probe QFI N²t²exp(−2Nγt). The GHZ phase accumulates N times faster, but independent dephasing also damps its coherence N times faster. In the noiseless limit the expressions recover N and N² scaling at fixed t.
The comparison fixes interrogation time; optimizing time with a fixed total experimental budget is a different resource question. QFI is an information bound, not a measured estimator variance. Preparation, readout, correlated noise and accessible measurements can further constrain a real sensor. A larger ideal expression alone does not establish a usable sensing advantage.
| Element | Model | Interpretation |
|---|---|---|
| Signal | Frequency-dependent phase | Longer time increases sensitivity |
| Product probes | Nt²e^(−2γt) | Independent information |
| GHZ probes | N²t²e^(−2Nγt) | Enhanced signal and fragility |
Predict, run, compare
For N=4,γ=0.1,t=1, compare 4e⁻⁰·² with 16e⁻⁰·⁸. Then increase time and observe how the GHZ dephasing penalty grows.
Download executable notebooks and source Inspect source ↗
Open sensing.ipynb in the package. Run cells in order, compare with the reference, then change the stated input. Restart the kernel to reset.
Computed reference result — local CPU fixture
{
"product_qfi": 3.2749230123119273,
"ghz_qfi": 7.189263425875545,
"scope": "frequency-estimation QFI with independent Markovian dephasing; fixed interrogation time"
}This is the recorded result of the included code under the package environment. It is not a live service or device measurement.
Extend the experiment
Optimize interrogation time for each probe family when total laboratory time is fixed. State how the number of independent repetitions changes the comparison.
Check your reasoning: What is held fixed in the displayed comparison?
- Interrogation time — Correct. Both formulas use the same specified t.
- All possible laboratory resource budgets — Preparation and repetition budgets are not included.
- Measured estimator variance — The output is a QFI bound, not measured variance.
This is an explained self-check, not a certification of mastery.
Claim-specific sources
Reviewed 2026-10-02: this worked example and its explicit assumptions. Source links and notebook results do not establish production or hardware validation.
AUTHORED STUDY COMPANION / 3.6
Use a distillation scaling law within its limits
Prerequisites. Error probabilities, asymptotic approximations and logical resource accounting.
An idealized 15-to-1 magic-state distillation protocol has leading small-input-error behavior approximately 35p³ for its output error. The companion applies that leading-order recurrence for one to three rounds and counts 15ʳ input states before accounting for rejected attempts.
This cubic suppression is not a complete factory cost or a threshold calculation. It assumes the relevant ideal Clifford operations and suitable independent input error model. Rejection probabilities, correlations, faulty logical operations, layout, routing, storage and scheduling all change practical resources. Keep the distinction between physical qubits, logical qubits, distilled states and algorithm-level failure probability explicit.
| Element | Model | Interpretation |
|---|---|---|
| Input | Small independent error p | Model assumption |
| Leading term | 35p³ | Asymptotic suppression |
| Resources | 15ʳ nominal inputs | Incomplete factory accounting |
Predict, run, compare
For p=0.01, the leading-order output is 35×10⁻⁶=0.000035 after one round, using 15 nominal inputs per output before rejection overhead.
Download executable notebooks and source Inspect source ↗
Open fault_tolerance.ipynb in the package. Run cells in order, compare with the reference, then change the stated input. Restart the kernel to reset.
Computed reference result — local CPU fixture
{
"leading_order_output_error": 3.5000000000000004e-05,
"input_states_per_output": 15,
"scope": "idealized 15-to-1 distillation leading-order 35p³ recurrence; ignores rejection, correlated errors, Clifford faults, routing and factory overhead"
}This is the recorded result of the included code under the package environment. It is not a live service or device measurement.
Extend the experiment
Add a declared acceptance probability and expected input cost. Explain which physical and logical error processes remain absent from the estimate.
Check your reasoning: The value 15ʳ includes all practical overhead:
- Yes — It is a nominal input-state count.
- No; rejected attempts and implementation costs are omitted — Correct. The scope explicitly excludes those costs.
- Only if p is small — Small p does not eliminate architectural overhead.
This is an explained self-check, not a certification of mastery.
Claim-specific sources
- Bravyi and Kitaev — Universal quantum computation with ideal Clifford gates and noisy ancillas
- Litinski — Magic State Distillation: Not as Costly as You Think
Reviewed 2026-10-02: this worked example and its explicit assumptions. Source links and notebook results do not establish production or hardware validation.