Closed mtfishman closed 4 years ago
Proposal to replace initializetomography with more specific functions randomstate and randomprocess. The interface could be something like:
initializetomography
randomstate
randomprocess
randomstate(MPS, N)
randomstate(LPDO, N)
randomstate(MPO, N)
randomprocess(MPO, N)
randomprocess(Choi, N)
Choi{LPDO}
randomprocess(Choi{MPO}, N)
Additionally, these options could be chosen with flags, like:
randomstate(N) = randomstate(MPS, N)
randomstate(N; mixed = true) = randomstate(LPDO, N)
randomstate(N; mixed = true, lpdo = false) = randomstate(MPO, N)
randomprocess(N) = randomprocess(MPO, N)
randomprocess(N; mixed = true) = randomprocess(Choi{LPDO}, N)
randomprocess(N; mixed = true, lpdo = false) = randomprocess(Choi{MPO}, N)
Here I'm assuming lpdo = true is the default, since it is probably most common, but could be chosen the other way.
lpdo = true
Proposal to replace
initializetomography
with more specific functionsrandomstate
andrandomprocess
. The interface could be something like:randomstate(MPS, N)
# Make a random qubit wavefunction for pure state tomographyrandomstate(LPDO, N)
# Make a random mixed state as an LPDOrandomstate(MPO, N)
# Make a random mixed state as an MPOrandomprocess(MPO, N)
# Make a random unitary circuit as an MPOrandomprocess(Choi, N)
# Make a random Choi matrix, defaults toChoi{LPDO}
randomprocess(Choi{MPO}, N)
# Make a random Choi matrix in MPO formAdditionally, these options could be chosen with flags, like:
randomstate(N) = randomstate(MPS, N)
randomstate(N; mixed = true) = randomstate(LPDO, N)
randomstate(N; mixed = true, lpdo = false) = randomstate(MPO, N)
randomprocess(N) = randomprocess(MPO, N)
randomprocess(N; mixed = true) = randomprocess(Choi{LPDO}, N)
randomprocess(N; mixed = true, lpdo = false) = randomprocess(Choi{MPO}, N)
Here I'm assuming
lpdo = true
is the default, since it is probably most common, but could be chosen the other way.