-
Notifications
You must be signed in to change notification settings - Fork 49
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Implementing Bivariate Bicycle Codes using 2BGA as the parent via Hecke's Group Algebra #399
Merged
Merged
Changes from 1 commit
Commits
Show all changes
9 commits
Select commit
Hold shift + click to select a range
632ec1f
implement Bivaraite Bicycle codes using 2BGA as parent
Fe-r-oz 554bd24
improve code quality by defining const types for FinGenAbGroup, FinGe…
Fe-r-oz a245163
fix ECC zoo link
Krastanov c63864e
Merge branch 'master' into fa/BBas2BGA
Krastanov 8b5813f
add wonderful codereview suggestion
Fe-r-oz 3082dbd
further simplification
Fe-r-oz 3f93214
formatting fix: use code not Code
Fe-r-oz 0e8c8fb
more consistent use of headers
Krastanov 2f57c53
maybe a more descriptive name, I do not know, I am not knowledgeable …
Krastanov File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,173 @@ | ||
@testitem "ECC Bivaraite Bicycle as 2BGA" begin | ||
using Hecke | ||
using Hecke: group_algebra, GF, abelian_group, gens, one | ||
using QuantumClifford.ECC: bivariate_bicycle_codes, code_k, code_n | ||
|
||
@testset "Reproduce Table 3 bravyi2024high" begin | ||
# [[72, 12, 6]] | ||
l=6; m=6 | ||
GA = group_algebra(GF(2), abelian_group([l, m])) | ||
x, y = gens(GA) | ||
A = [x^3, y, y^2] | ||
B = [y^3, x, x^2] | ||
c = bivariate_bicycle_codes(A,B,GA) | ||
@test code_n(c) == 72 && code_k(c) == 12 | ||
|
||
# [[90, 8, 10]] | ||
l=15; m=3 | ||
GA = group_algebra(GF(2), abelian_group([l, m])) | ||
x, y = gens(GA) | ||
A = [x^9 , y , y^2] | ||
B = [one(x), x^2 , x^7] | ||
c = bivariate_bicycle_codes(A,B,GA) | ||
@test code_n(c) == 90 && code_k(c) == 8 | ||
|
||
# [[108, 8, 10]] | ||
l=9; m=6 | ||
GA = group_algebra(GF(2), abelian_group([l, m])) | ||
x, y = gens(GA) | ||
A = [x^3 , y , y^2] | ||
B = [y^3 , x , x^2] | ||
c = bivariate_bicycle_codes(A,B,GA) | ||
@test code_n(c) == 108 && code_k(c) == 8 | ||
|
||
# [[144, 12, 12]] | ||
l=12; m=6 | ||
GA = group_algebra(GF(2), abelian_group([l, m])) | ||
x, y = gens(GA) | ||
A = [x^3 , y , y^2] | ||
B = [y^3 , x , x^2] | ||
c = bivariate_bicycle_codes(A,B,GA) | ||
@test code_n(c) == 144 && code_k(c) == 12 | ||
|
||
# [[288, 12, 12]] | ||
l=12; m=12 | ||
GA = group_algebra(GF(2), abelian_group([l, m])) | ||
x, y = gens(GA) | ||
A = [x^3 , y^2, y^7] | ||
B = [y^3 , x , x^2] | ||
c = bivariate_bicycle_codes(A,B,GA) | ||
@test code_n(c) == 288 && code_k(c) == 12 | ||
|
||
# [[360, 12, ≤ 24]] | ||
l=30; m=6 | ||
GA = group_algebra(GF(2), abelian_group([l, m])) | ||
x, y = gens(GA) | ||
A = [x^9 , y , y^2] | ||
B = [y^3 , x^25 , x^26] | ||
c = bivariate_bicycle_codes(A,B,GA) | ||
@test code_n(c) == 360 && code_k(c) == 12 | ||
|
||
# [[756, 16, ≤ 34]] | ||
l=21; m=18 | ||
GA = group_algebra(GF(2), abelian_group([l, m])) | ||
x, y = gens(GA) | ||
A = [x^3 , y^10 , y^17] | ||
B = [y^5 , x^3 , x^19] | ||
c = bivariate_bicycle_codes(A,B,GA) | ||
@test code_n(c) == 756 && code_k(c) == 16 | ||
end | ||
|
||
@testset "Reproduce Table 1 berthusen2024toward" begin | ||
# [[72, 8, 6]] | ||
l=12; m=3 | ||
GA = group_algebra(GF(2), abelian_group([l, m])) | ||
x, y = gens(GA) | ||
A = [x^9 , y , y^2] | ||
B = [one(x), x , x^11] | ||
c = bivariate_bicycle_codes(A,B,GA) | ||
@test code_n(c) == 72 && code_k(c) == 8 | ||
|
||
# [[90, 8, 6]] | ||
l=9; m=5 | ||
GA = group_algebra(GF(2), abelian_group([l, m])) | ||
x, y = gens(GA) | ||
A = [x^8 , y^4 , y] | ||
B = [y^5 , x^8 , x^7] | ||
c = bivariate_bicycle_codes(A,B,GA) | ||
@test code_n(c) == 90 && code_k(c) == 8 | ||
|
||
# [[120, 8, 8]] | ||
l=12; m=5 | ||
GA = group_algebra(GF(2), abelian_group([l, m])) | ||
x, y = gens(GA) | ||
A = [x^10 , y^4, y] | ||
B = [one(x), x , x^2] | ||
c = bivariate_bicycle_codes(A,B,GA) | ||
@test code_n(c) == 120 && code_k(c) == 8 | ||
|
||
# [[150, 8, 8]] | ||
l=15; m=5 | ||
GA = group_algebra(GF(2), abelian_group([l, m])) | ||
x, y = gens(GA) | ||
A = [x^5 , y^2 , y^3] | ||
B = [y^2 , x^7 , x^6] | ||
c = bivariate_bicycle_codes(A,B,GA) | ||
@test code_n(c) == 150 && code_k(c) == 8 | ||
|
||
# [[196, 12, 8]] | ||
l=14; m=7 | ||
GA = group_algebra(GF(2), abelian_group([l, m])) | ||
x, y = gens(GA) | ||
A = [x^6 , y^5 , y^6] | ||
B = [one(x), x^4 , x^13] | ||
c = bivariate_bicycle_codes(A,B,GA) | ||
@test code_n(c) == 196 && code_k(c) == 12 | ||
end | ||
|
||
@testset "Reproduce Table 1 wang2024coprime" begin | ||
# [[54, 8, 6]] | ||
l=3; m=9 | ||
GA = group_algebra(GF(2), abelian_group([l, m])) | ||
x, y = gens(GA) | ||
A = [one(x), y^2, y^4] | ||
B = [y^3 , x , x^2] | ||
c = bivariate_bicycle_codes(A,B,GA) | ||
@test code_n(c) == 54 && code_k(c) == 8 | ||
|
||
# [[98, 6, 12]] | ||
l=7; m=7 | ||
GA = group_algebra(GF(2), abelian_group([l, m])) | ||
x, y = gens(GA) | ||
A = [x^3 , y^5 , y^6] | ||
B = [y^2 , x^3 , x^5] | ||
c = bivariate_bicycle_codes(A,B,GA) | ||
@test code_n(c) == 98 && code_k(c) == 6 | ||
|
||
# [[126, 8, 10]] | ||
l=3; m=21 | ||
GA = group_algebra(GF(2), abelian_group([l, m])) | ||
x, y = gens(GA) | ||
A = [one(x), y^2, y^10] | ||
B = [y^3 , x , x^2] | ||
c = bivariate_bicycle_codes(A,B,GA) | ||
@test code_n(c) == 126 && code_k(c) == 8 | ||
|
||
# [[150, 16, 8]] | ||
l=5; m=15 | ||
GA = group_algebra(GF(2), abelian_group([l, m])) | ||
x, y = gens(GA) | ||
A = [one(x), y^6, y^8] | ||
B = [y^5 , x , x^4] | ||
c = bivariate_bicycle_codes(A,B,GA) | ||
@test code_n(c) == 150 && code_k(c) == 16 | ||
|
||
# [[162, 8, 14]] | ||
l=3; m=27 | ||
GA = group_algebra(GF(2), abelian_group([l, m])) | ||
x, y = gens(GA) | ||
A = [one(x), y^10, y^14] | ||
B = [y^12 , x , x^2] | ||
c = bivariate_bicycle_codes(A,B,GA) | ||
@test code_n(c) == 162 && code_k(c) == 8 | ||
|
||
# [[180, 8, 16]] | ||
l=6; m=15 | ||
GA = group_algebra(GF(2), abelian_group([l, m])) | ||
x, y = gens(GA) | ||
A = [x^3 , y , y^2] | ||
B = [y^6 , x^4 , x^5] | ||
c = bivariate_bicycle_codes(A,B,GA) | ||
@test code_n(c) == 180 && code_k(c) == 8 | ||
end | ||
end |
Oops, something went wrong.
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
why write this down as
[x^3 , y^10 , y^17]
instead ofx^3 + y^10 + y^17
and use directlytwo_block_group_algebra_codes
? What is the advantage of the list notation?There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
You are right. For regular abelian groups via Hecke's group algebra, we can use the non-list notation.
The advantage of list notation is when using finitely presented groups from Oscar with specific group presentations which is not related to this PR.