I'm reading through this paper and on page 14 they define quantum reed muller (QRM) codes using the classical versions. I've seen punctured RM codes used to define quantum CSS codes with good properties; but the paper's definition is with unpunctured codes. I checked the the $X$ and $Z$ stabilizers define a QECC; but the definition of the $X$ and $Z$ logicals doesn't seem right. For one, they don't have the same dimensions. They're also orthogonal...which also doesn't make sense. Is the paper wrong or did I miss something? (the motivation is that these codes allow some transversal non-clifford gates)
I converted the accepted answer to GAP. Here's my version :
Qrm:=function(m,r)local s,mat,layers,Sx,Sz,Lx,Lz,mx,mz,kx,kz,check,verify,code;
mat:=Iterated(List([1..m],x->[[1,1],[0,1]]),KroneckerProduct); # 2^m x 2^m matrix = m-th tensor power of [[1,1],[0,1]]
layers:=List([0..m],x->Filtered(mat,y->Sum(y)=2^(m-x))); # layer[r]=subset of rows with weight = 2^(m-r)
s:=m-r-2;
Sx:=Concatenation(layers{[1..r+1]}); mx:=Length(Sx); # X satbilisers
Sz:=Concatenation(layers{[1..s+1]}); mz:=Length(Sz); # Z satbilisers
Lx:=layers[r+2]; kx:=Length(Lx); # X logicals
Lz:=layers[s+2]; kz:=Length(Lz); # Z logicals
Print("n =",2^m," |Sx|=",mx," |Sz|=",mz," |Lx|=",kx," |Lz|=",kz,"\n");
check:="kx=kz=k; k=Binomial(m,r+1); k=n-(mx+mz);";verify:=kx=kz and kx=Binomial(m,r+1) and 2^m-(mx+mz)=kx;Print(verify," ",check,"\n");
check:="Sx*Sz=0; ";verify:=\mod(Sx*TransposedMat(Sz),2)=NullMat(mx,mz);Print(verify," ",check,"\n");
check:="Lx*Sz=0; ";verify:=\mod(Lx*TransposedMat(Sz),2)=NullMat(kx,mz);Print(verify," ",check,"\n");
check:="Lz*Sx=0; ";verify:=\mod(Lz*TransposedMat(Sx),2)=NullMat(kz,mx);Print(verify," ",check,"\n");
check:="Lx*Lz=I; ";verify:=\mod(Lx*TransposedMat(Reversed(Lz)),2)=IdentityMat(kz);Print(verify," ",check,"\n");
code:=rec();
code.Sx:=Sx;code.Sz:=Sz;code.Lx:=Lx;code.Lz:=Lz;
return code;
end;
I checked with a few other parameters :
gap> code:=Qrm(6,1);;
n =64 |Sx|=7 |Sz|=42 |Lx|=15 |Lz|=15
true kx=kz=k; k=Binomial(m,r+1); k=n-(mx+mz);
true Sx*Sz=0;
true Lx*Sz=0;
true Lz*Sx=0;
true Lx*Lz=I;
gap> code:=Qrm(6,2);;
n =64 |Sx|=22 |Sz|=22 |Lx|=20 |Lz|=20
true kx=kz=k; k=Binomial(m,r+1); k=n-(mx+mz);
true Sx*Sz=0;
true Lx*Sz=0;
true Lz*Sx=0;
true Lx*Lz=I;
gap> code:=Qrm(6,0);;
n =64 |Sx|=1 |Sz|=57 |Lx|=6 |Lz|=6
true kx=kz=k; k=Binomial(m,r+1); k=n-(mx+mz);
true Sx*Sz=0;
true Lx*Sz=0;
true Lz*Sx=0;
true Lx*Lz=I;