Initialize Quantum Framework
Initialize Quantum Framework
In[]:=
PacletInstall["https://www.wolframcloud.com/obj/wolframquantumframework/QuantumFramework.paclet",ForceVersionInstall->True]
Out[]=
PacletObject
In[]:=
<<Wolfram`QuantumFramework`
Computation of the Entanglement Entropy: Bell State
Computation of the Entanglement Entropy: Bell State
In[]:=
ψ=QuantumState["PsiPlus"]
Out[]=
QuantumState
In[]:=
ψ["Formula"]
Out[]=
|01〉
2
|10〉
2
In[]:=
ψ["DensityMatrix"]//MatrixForm
Out[]//MatrixForm=
0 | 0 | 0 | 0 |
0 | 1 2 | 1 2 | 0 |
0 | 1 2 | 1 2 | 0 |
0 | 0 | 0 | 0 |
In[]:=
ρ=Simplify[QuantumPartialTrace[ψ,{2}]["DensityMatrix"]]
Out[]=
SparseArray
Compute the Entanglement Entropy:
S
ρ
In[]:=
S=-Tr[ρ.MatrixLog[ρ]]
Out[]=
Log[2]