Skip to main content

Questions tagged [quantum-computing]

Questions about simulation of quantum circuits and quantum algorithms in Mathematica.

Filter by
Sorted by
Tagged with
0 votes
0 answers
52 views
+50

Improving accuracy of neural network for determining qubit rotation angle

The physics example problem (to illustrate the use of a basic neural network using Mathematica) I am looking at is a qubit rotated about the y-axis, where the rotation angle is discretized as $\...
John Doe's user avatar
  • 229
0 votes
0 answers
77 views

SoftmaxLayer with one-hot vectors

The quantum physics problem I am looking at is a rotated qubit. The setup involves a y-rotated qubit measured in the z-basis (hence spin-up and spin-down). This scenario typically includes modeling ...
John Doe's user avatar
  • 229
0 votes
0 answers
44 views

Using CrossEntropyLoss function for basic neural network

Hi I am interested in understanding how to use the neural network functions in Mathematica. I have just started learning hence this is a basic query. The simple example I am looking at is as follows: ...
John Doe's user avatar
  • 229
0 votes
0 answers
43 views

Wolfram Quantum Framework: simple NOT gate: strange matrix of circuit

Please have a look at the attached notebook. It contains a simple NOT circuit. I would expect the matrix of the circuit to be a 2 by 2 matrix. Just like the 2 by 2 matrix of the NOT gate itself. But ...
BertRAMAerts's user avatar
0 votes
2 answers
89 views

Simplification of quantum ladder operators (ideally using Using NCAlgebra)

I want to do math that involves a series of ladder operators. In the past I've tried to get it working with a 20 year old Mathematica package. But my feeling is that this is a very unused package and ...
Steven Sagona's user avatar
0 votes
0 answers
98 views

Modern way to do quantum optics calculations in 2024?

Quantum Optics can often require messy algebraic simplifications of noncommuting operators (usually ladder operators and commutators). I've asked here about how to do it before. What are some modern ...
Steven Sagona's user avatar
3 votes
1 answer
85 views

Make the ```*``` operation the Kronecker product by default for Kets?

So given two "Ket" objects, u = Ket[{-1/2}]; d = Ket[{1/2}]; Is there a way to define multiplication, *, so that by ...
AlkaKadri's user avatar
  • 131
2 votes
0 answers
57 views

Deriving Expressions for R1, R2, and R12 , Normalized Coincident Detection Probability, and LG Mode Formalism

I am currently reviewing a research paper on orbital angular momentum entanglement between two photons (signal and idler) generated from a pump photon via SPDC. The paper introduces the following ...
Qubit's user avatar
  • 45
0 votes
0 answers
38 views

quantum state extraction

Here's a simple circuit with an input state applied: ...
pete3739's user avatar
2 votes
1 answer
224 views

Solving a Lindblad differential equation in matrix form

I am trying to solve the following Lindblad equation analytically with Mathematica: $$\frac{d\rho}{dt}=-i[H,\rho]+\sum\nolimits_{i=0}^1 K_i\rho K_i^+-\frac12\cdot\{K_i^+K_i,\rho\},$$ where $$H=\begin{...
QC_Pod's user avatar
  • 43
0 votes
0 answers
49 views

On MacOs, I cannot use Needs["QDENSITY`Qdensity`"]

I am trying to get Needs["QDENSITY`Qdensity`"] from (https://library.wolfram.com/infocenter/MathSource/5715/), however, it failed and I get this error: ...
Xui Lao's user avatar
1 vote
0 answers
72 views

Why must the "&" symbol be placed inside function instead of outside? [closed]

The following code is taken from Wolfram Community "Quantum Error Correction: bit flip". ...
am567's user avatar
  • 501
1 vote
2 answers
144 views

Number operator

Suppose CR is my creation operator and AR is my annihilation operator. I have to show that ...
user444's user avatar
  • 2,446
0 votes
0 answers
77 views

Solving a system of complex matrix equation using Reduce function

I am trying to solve a system of four matrix equations using Reduce function. The system arises in Quantum Information. The system is solvable with a solution i.e. phi, but the following code gives ...
Ruthless_Tornado's user avatar
3 votes
2 answers
252 views

Decoupling a system of four linear $1$-st order ODEs

I have a system of four $1$-st order ODEs. $$ \dot{p_1} = -2\beta^2 q_1 - \gamma p_1 + \Delta p_2 $$ $$ \dot{p_2} = -2\beta^2 q_2 - \gamma p_2 + \Delta p_1 $$ $$ \dot{q_1} = 2\alpha^2 p_1 + \gamma q_1 ...
Kazi Abu Rousan's user avatar
1 vote
0 answers
87 views

Gaussian Matrix Model - Large N Expansion Physics with Mathematica

Update: Attempted 2nd time by replica method I'm trying to implement basic large N expansion in Mathematica. I'm trying to understand what this means on the fly as well. The model I am trying to ...
kevin Tah N.'s user avatar
1 vote
0 answers
121 views

How to implement an entangled measurement in mathematica?

Suppose, we have two states $|\phi^+\rangle_{AB},|\phi^+\rangle_{CD}$. Now a Bell basis measurement is performed on the qubits BC. How to code in Mathematica to find out the post-measurement state on ...
SHUBHAYAN SARKAR's user avatar
4 votes
2 answers
359 views

How to generate all permutation matrices for 4 qubits?

In quantum mechanics, a qubit can be understood as a 2 by 1 vector denoted by Dirac notation as $$|0\rangle \equiv \left( \begin{array}{c} 1\\ 0\\ \end{array} \right) ,|1\rangle \equiv \left( \...
narip's user avatar
  • 381
1 vote
0 answers
147 views

Wolfram Quantum Framework Shows Mixed States as Kets

Wolfram Quantum Framework consistently shows the state["Formula"] for mixed states, defined via some density matrix, in terms of simply kets! Is it ...
Aritra Das's user avatar
6 votes
1 answer
156 views

Minimizing computational time for a quantum walk problem

Any suggestions as to how to speed up the computational time for this quantum walk problem which is coded using a normalized SparseArray coin operator as follows: ...
thils's user avatar
  • 3,268
3 votes
1 answer
144 views

Schmidt Measure of a Graph State

Based on the definition of the Schmidt measure in this work https://www.arxiv-vanity.com/papers/quant-ph/0307130/, the following code was set up, but appears to generate errors. Is there a better way ...
thils's user avatar
  • 3,268
1 vote
2 answers
77 views

Defining and executing large matrix operators on vectors efficiently

For an $N$-qubit system, I am interested in coding, in an efficient way, the following set of Kraus operators $\{A_c\}_c$ defined in the computational basis as \begin{align} \hat{A}_c := \sum_{m=...
John Doe's user avatar
  • 229
0 votes
0 answers
35 views

Resetting rules for non comutative multiply

Im currently working on a project that intends to achieve multiple task the first if which rewrite a bra-ket notated triplet tensor product state such as the w state in terms of the pauli matrices. i,...
Parham Azish's user avatar
2 votes
1 answer
74 views

Confusion in Eigenvalue and eigenfunction distribution using NDEigensystem [duplicate]

I have been using NDEigensystem to solve the Schrodinger equation for different potentials. However, whenever the potential has its minimum in the negative y-axis, ...
user444's user avatar
  • 2,446
2 votes
0 answers
37 views

Simulation of Quantum pseudo-telepathy

I would like to mathematically simulate Quantum pseudo-telepathy on The magic square game from Wikipedia. In section Pseudo-telepathic strategies we can read: The trick is for Alice and Bob to share ...
azerbajdzan's user avatar
  • 18.9k
2 votes
1 answer
349 views

Decomposing Hamiltonian in terms of Pauli strings

Does anyone know of a native Mathematica function or a package that allows one to decompose an arbitrary Hamiltonian into Pauli strings? There are a few packages for Python that do this (e.g., one ...
Physics Penguin's user avatar
2 votes
1 answer
182 views

How to find complete QuantumOperator() Matrix

I am defining a quantum operator as X1 = QuantumOperator["PauliX", {3}] This operator is expected to act on qubit 3 and so supposed to be 8x8 matrix. But ...
user1847424's user avatar
1 vote
0 answers
241 views

How to define momentum operator for use with creation and annihilation operators in quantum mechanics

I am having trouble writing the momentum operator in the differential form to complete a piece of code shown here so that I can show a commutator [P,Q] = I . Here is what I have done so far, and I ...
kevin Tah N.'s user avatar
2 votes
0 answers
64 views

QuantumFramework: Error message when calculating a CircuitOperator

I am running the following package and code: ...
user823's user avatar
  • 221
-4 votes
1 answer
115 views

Constructing NxN tridiagonal block diagonal matrix with N is a variable [closed]

Hi please can someone help me writing a program of generating a tridiagonal block matrix with dimension of NxN where N is a variable can be 50, 100, 200, 300...etc , Well I don't know how I'm a ...
Med Ch's user avatar
  • 117
3 votes
1 answer
156 views

Calculating power series of quantum operators on kets

I am using the "Quantum" add-on package to perform some quantum mechanical calculations using SU(1,1) generators. The code that I've developed reads ...
Shasa's user avatar
  • 1,043
0 votes
1 answer
49 views

How to export integration values to a data file? [closed]

I'm calculating quantum mechanical expectation value for a very high order truncation value. But due to low ram, it gets hung each time. So I am trying to write those data to a .dat file into the HDD ...
user444's user avatar
  • 2,446
2 votes
0 answers
192 views

Defining a non-commutative algebra

I'm new to Mathematica, and I'm trying to learn the ropes. I'm trying to write a little boson algebra engine, with basic useful functions such as non-commutative algebra, normal-ordering and vacuum ...
lbello's user avatar
  • 21
9 votes
1 answer
1k views

Where is the QuantumComputing package?

Where is the QuantumComputing package? https://m.youtube.com/watch?v=wHnfWuS0C08
Alexey Golyshev's user avatar
12 votes
3 answers
3k views

Is there a way to do Quantum Computing in Mathematica notebook?

I saw 2 efforts in that direction: WSS17 and WSS16, but I am not sure if there is something in the latest Mathematica that actually allows users to simulate quantum gates. Can anyone please point me ...
0x90's user avatar
  • 599
13 votes
1 answer
1k views

How to draw quantum circuit with mathematica?

How to draw quantum circuit as the following one with mathematica? I only find the quantum package which is designed for MMA 7.0 as the author said. But the version of my Mathematica is 9.0 and when ...
Eden Harder's user avatar
  • 1,145