Skip to content

Instantly share code, notes, and snippets.

@lucainnocenti
Last active July 28, 2022 09:40
Show Gist options
  • Save lucainnocenti/1f341fdc14e9c48b449163586ec8f3ea to your computer and use it in GitHub Desktop.
Save lucainnocenti/1f341fdc14e9c48b449163586ec8f3ea to your computer and use it in GitHub Desktop.
Examples of scrambling (cit) dynamics
(* this one gives maximally negative tripartite *)
superScrambling2qutritsUnitary := Table[
Normal @ Flatten @ KroneckerProduct[
SparseArray[{Mod[i + j, 3] + 1 -> 1}, 3],
SparseArray[{Mod[i - j, 3] + 1 -> 1}, 3]
],
{i, {0, 1, 2}}, {j, {0, 1, 2}}
] // ArrayReshape[#, {9, 9}] & // Transpose;
(* unitary changing local bases to Fourier bases *)
changeOfBasisUnitary = With[{\[Omega] = Exp[2 Pi I/3]},
Table[
Flatten @ KroneckerProduct[
{1, \[Omega]^n, \[Omega]^(2 n)},
{1, \[Omega]^m, \[Omega]^(2 m)}
],
{n, {0, 1, 2}}, {m, {0, 1, 2}}
] / 3 // ArrayReshape[#, {9, 9}] & // Transpose
];
(* the following gives a permutation matix *)
Dot[
ConjugateTranspose @ changeOfBasisUnitary,
superScrambling2qutritsUnitary,
changeOfBasisUnitary
] // MatrixForm // FullSimplify
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment