pyCTQW.MPI.Line3P

class Line3P(N, d=None, amp=None, interaction=0.0)

Bases: pyCTQW.MPI.ctqw.QuantumWalkP3

Performs and analyses 3 particle continuous-time quantum walks on an infinite line

Parameters:N (int) – an even number of nodes to initialize the walker with. Nodes are labeled \(j\in\{1-N/2,N/2\}\).

Example

To create a CTQW Line object for a 10 node line,

>>> walk = pyCTQW.MPI.Line3P(10)

Method Summary

Line3P.createH([d, amp, interaction]) Generate the Hamiltonian of the graph.
Line3P.createInitState(initState) Generate the initial state of the quantum walk.
Line3P.destroy() Destroys the 3 particle quantum walk object, and all associated PETSc matrices/vectors.
Line3P.exportState(filename, filetype) Exports the final state psi of the quantum walk to a file.
Line3P.importInitState(filename, filetype) Imports the initial state of the quantum walk from a file.
Line3P.plot(filename) Creates a plot of probability vs node.
Line3P.plotEntanglement(filename) Creates a plot of the entanglement over time.
Line3P.plotNode(filename, node[, t]) Creates a plot of the marginal probablities on a specified node over time.
Line3P.plotNodes(filename[, p, t]) Creates a plot of the node probablities over time.
Line3P.propagate(t[, method]) Propagates the quantum walk for time t.
Line3P.psiToInit() Copies the state psi to psi0.
Line3P.watch(nodes[, type]) Creates a handle that watches either marginal probability or walker entanglement during propagation.

Attribute Summary

Attribute Type Description
Line3P.psi0 petsc4py.PETSc.Vec() \(N^3\) element PETSc vector containing the initial state
Line3P.psi petsc4py.PETSc.Vec() \(N^3\) element PETSc vector containing the final state after the last propagation.
Line3P.psiX petsc4py.PETSc.Vec() \(N\) element PETSc vector containing the marginal propability of particle 1
Line3P.psiY petsc4py.PETSc.Vec() \(N\) element PETSc vector containing the marginal propability of particle 2
Line3P.psiZ petsc4py.PETSc.Vec() \(N\) element PETSc vector containing the marginal propability of particle 3
Line3P.H pyCTQW.MPI.ctqw.Hamiltonian() Hamiltonian matrix
Line3P.EigSolver pyCTQW.MPI.ctqw.EigSolver() The Hamiltonian eigensolver
Line3P.handle pyCTQW.MPI.ctqw.nodeHandle() A node handle, created if nodes are being watched for probability.
Line3P.entanglementHandle pyCTQW.MPI.ctqw.entanglementHandle() A node handle, created if the entanglement is being watched.