Skip to content

Commit

Permalink
Swap X and Z case
Browse files Browse the repository at this point in the history
In the ZX calculus, Z always comes first.
  • Loading branch information
zickgraf committed Sep 28, 2023
1 parent c83621f commit abe8385
Showing 1 changed file with 4 additions and 4 deletions.
8 changes: 4 additions & 4 deletions gap/Tools.gi
Original file line number Diff line number Diff line change
Expand Up @@ -26,15 +26,15 @@ if IsPackageMarkedForLoading( "json", "2.1.1" ) then

for pos in [ 1 .. Length( labels ) ] do

Check warning on line 27 in gap/Tools.gi

View check run for this annotation

Codecov / codecov/patch

gap/Tools.gi#L27

Added line #L27 was not covered by tests

if labels[pos] = "X" then
if labels[pos] = "Z" then

Check warning on line 29 in gap/Tools.gi

View check run for this annotation

Codecov / codecov/patch

gap/Tools.gi#L29

Added line #L29 was not covered by tests

node_vertices.(pos - 1) := rec( annotation := rec( coord := [ 0, 0 ] ),
data := rec( type := "X" ) );
data := rec( type := "Z" ) );

Check warning on line 32 in gap/Tools.gi

View check run for this annotation

Codecov / codecov/patch

gap/Tools.gi#L31-L32

Added lines #L31 - L32 were not covered by tests

elif labels[pos] = "Z" then
elif labels[pos] = "X" then

Check warning on line 34 in gap/Tools.gi

View check run for this annotation

Codecov / codecov/patch

gap/Tools.gi#L34

Added line #L34 was not covered by tests

node_vertices.(pos - 1) := rec( annotation := rec( coord := [ 0, 0 ] ),
data := rec( type := "Z" ) );
data := rec( type := "X" ) );

Check warning on line 37 in gap/Tools.gi

View check run for this annotation

Codecov / codecov/patch

gap/Tools.gi#L36-L37

Added lines #L36 - L37 were not covered by tests

elif labels[pos] = "H" then

Check warning on line 39 in gap/Tools.gi

View check run for this annotation

Codecov / codecov/patch

gap/Tools.gi#L39

Added line #L39 was not covered by tests

Expand Down

0 comments on commit abe8385

Please sign in to comment.