Wolfram Language Paclet Repository

Community-contributed installable additions to the Wolfram Language

Primary Navigation

    • Cloud & Deployment
    • Core Language & Structure
    • Data Manipulation & Analysis
    • Engineering Data & Computation
    • External Interfaces & Connections
    • Financial Data & Computation
    • Geographic Data & Computation
    • Geometry
    • Graphs & Networks
    • Higher Mathematical Computation
    • Images
    • Knowledge Representation & Natural Language
    • Machine Learning
    • Notebook Documents & Presentation
    • Scientific and Medical Data & Computation
    • Social, Cultural & Linguistic Data
    • Strings & Text
    • Symbolic & Numeric Computation
    • System Operation & Setup
    • Time-Related Computation
    • User Interface Construction
    • Visualization & Graphics
    • Random Paclet
    • Alphabetical List
  • Using Paclets
    • Get Started
    • Download Definition Notebook
  • Learn More about Wolfram Language

Q3mini

Guides

  • Fermionic Quantum Computation
  • Q3: Symbolic Quantum Simulation
  • Quantum Information Systems
  • Quantum Many-Body Systems
  • Quantum Spin Systems

Tech Notes

  • About Q3
  • Q3: Quick Start
  • Quantum Fourier Transform
  • Quantum Information Systems with Q3
  • Quantum Many-Body Systems with Q3
  • Quantum Operations
  • Quantum Spin Systems with Q3
  • Quantum States
  • Quantum Teleportation
  • Quick Quantum Computing with Q3

Symbols

  • Basis
  • Boson
  • Bra
  • CNOT
  • ControlledGate
  • ExpressionFor
  • Fermion
  • Heisenberg
  • Ket
  • Let
  • Majorana
  • Matrix
  • Multiply
  • NambuGreen
  • NambuHermitian
  • NambuMatrix
  • NambuUnitary
  • Pauli
  • Phase
  • QuantumCircuit
  • Qubit
  • Qudit
  • RandomWickCircuitSimulate
  • Rotation
  • Species
  • Spin
  • SWAP
  • WickCircuit
  • WickEntanglementEntropy
  • WickEntropy
  • WickGreenFunction
  • WickJump
  • WickLindbladSolve
  • WickLogarithmicNegativity
  • WickMeasurement
  • WickMonitor
  • WickMutualInformation
  • WickNonunitary
  • WickSimulate
  • WickState
  • WickUnitary

Overviews

  • The Postulates of Quantum Mechanics
  • Quantum Algorithms
  • Quantum Computation: Models
  • Quantum Computation: Overview
  • Quantum Error-Correction Codes
  • Quantum Information Theory
  • Quantum Noise and Decoherence
QuantumMob`Q3mini`
WickSimulate
​
WickSimulate
[in,ham,jmp,{τ,dt}]
solves the quantum master equation for a non-interacting dissipative fermionic many-body system by using the Monte Carlo simulation method (also known as the quantum jump approach or quantum trajectory method). The model is specified by the single-particle Hamiltonian
ham
in the
WickHermitian
form and the quantum jump operators are specified by
jmp
in the
WickJump
or
WickMeasurement
form. The simulation starts from the initial state
in
in the
WickState
form at time 0 and runs to time
n
τ in steps of size
dt
.
​
​
WickSimulate
[in,ham,jmp,{τ,dt,k}]
collects states in steps of
k×dt
(rather than
dt
), where
k
must be an integer or
All
.
​
Details and Options

Examples  
(3)
Basic Examples  
(3)
Choose how many fermion modes to consider.
In[1]:=
$n=4;
Although unnecessary, consider a specific set of fermion modes for conversion between the Wick and conventional representations.
In[2]:=
Let[Fermion,c]​​cc=c[Range@$n]
Out[2]=
{
c
1
,
c
2
,
c
3
,
c
4
}
Choose a initial state with half filling.
In[3]:=
in=WickState[{1,0},$n]
Out[3]=
WickState
Modes: 4
Prefactor: 1

In[4]:=
ExpressionFor[in,cc]//Chop
Out[4]=

1
c
1
0
c
2
1
c
3
0
c
4

Construct the single-particle Hamiltonian matrix.
In[5]:=
SeedRandom[373];
In[6]:=
ham=RandomWickHermitian[$n];​​ham//ArrayShort
Out[6]//MatrixForm=
0
0.175429
-0.12261
0.0940521
…
-0.175429
0
0.835042
-0.577971
…
0.12261
-0.835042
0
1.18605
…
-0.0940521
0.577971
-1.18605
0
…
…
…
…
…
…
Take quantum jump operators.
In[7]:=
$N=2;​​jmp=RandomWickJump[$N,$n]
Out[7]=
WickJump
Modes: 4
Operators: 2

In[8]:=
WickElements[jmp,cc]//TableForm
Out[8]//TableForm=
(-0.953177+2.02279)
c
1
-(0.944939+1.39112)
c
2
-(0.664869-1.1731)
c
3
+(0.307998+0.0442964)
c
4
-(1.07639-0.195508)
†
c
1
-(0.0741405+0.779836)
†
c
2
-(1.73555-1.01225)
†
c
3
-(1.51653+2.66703)
†
c
4
(-2.21583-0.00918327)
c
1
+(1.73101+0.0532143)
c
2
-(0.181957+0.303511)
c
3
-(1.73714-3.44668)
c
4
+(1.15649-0.66377)
†
c
1
-(0.0962902-1.55543)
†
c
2
+(0.899827+0.541808)
†
c
3
+(1.04338+2.47408)
†
c
4
Now, perform the Monte Carlo simulation.
In[9]:=
EchoTiming[​​data=WickSimulate[in,ham,jmp,{$T=0.5,dt=0.01},"Samples"100];​​]
⌚
7.40636
Check the size of the data.
In[10]:=
Dimensions[data]
Out[10]=
{100,51}
Check a few state in the first trajectory.
In[11]:=
data〚1,;;3〛
Out[11]=
WickState
Modes: 4
Prefactor: 1
,WickState
Modes: 4
Prefactor: 1
,WickState
Modes: 4
Prefactor: 1

​
Let us now examine various entanglement properties. Take the first half of the fermion modes as a subsystem.
In[1]:=
kk=Range[$n/2]
Out[1]=
{1,2}
Calculate the entanglement entropy (EE) between the subsystem and the rest.
In[2]:=
EchoTiming[​​ee=WickEntanglementEntropy[data,kk]​​];
⌚
0.596549
Plot the entanglement entropy averaged over the quantum trajectories. Here, γ refers to the damping rate, which equals to 1 in our unit system.
In[3]:=
ListLinePlot[Mean[ee],​​DataRange{0,$T},​​PlotMarkers{Automatic,12},​​FrameLabel{"γt","〈EE (​
L
​,
L
/2)〉"}]
Out[3]=
Calculate the mutual information (MI) between the subsystem and the rest.
In[4]:=
EchoTiming[​​mi=WickMutualInformation[data,kk]​​];
⌚
2.20996
Plot the entanglement entropy averaged over the quantum trajectories. Here, γ refers to the damping rate, which equals to 1 in our unit system.
In[5]:=
ListLinePlot[Mean[Re@mi],​​DataRange{0,$T},​​PlotMarkers{Automatic,12},​​FrameLabel{"γt","〈MI (L, L/2)〉"}]
Out[5]=
Calculate the logarithmic entanglement negativity (LN) between the subsystem and the rest.
Plot the entanglement entropy averaged over the quantum trajectories. Here, γ refers to the damping rate, which equals to 1 in our unit system.
Finally, calculate the logarithmic entanglement negativity (LN) in the mixed states (density matrices).
Plot the entanglement entropy averaged over the quantum trajectories. Here, γ refers to the damping rate, which equals to 1 in our unit system.
​

© 2025 Wolfram. All rights reserved.

  • Legal & Privacy Policy
  • Contact Us
  • WolframAlpha.com
  • WolframCloud.com