Real-time collaboration for Jupyter Notebooks, Linux Terminals, LaTeX, VS Code, R IDE, and more,
all in one place.
Real-time collaboration for Jupyter Notebooks, Linux Terminals, LaTeX, VS Code, R IDE, and more,
all in one place.
| Download
GAP 4.8.9 installation with standard packages -- copy to your CoCalc project to get it
Project: cocalc-sagemath-dev-slelievre
Views: 4183461[1X3 Algorithms of Orbit-Stabilizer Type[0X23We introduce a way to calculate a sufficient part of an orbit and the4stabilizer of a point.567[1X3.1 Orbit Stabilizer for Crystallographic Groups[0X89[1X3.1-1 OrbitStabilizerInUnitCubeOnRight[0m1011[2X> OrbitStabilizerInUnitCubeOnRight( [0X[3Xgroup, x[0X[2X ) _______________________[0Xmethod12[6XReturns:[0X A record containing1314-- [9X.stabilizer[0m: the stabilizer of [3Xx[0m.1516-- [9X.orbit[0m set of vectors from [0,1)^n which represents the17orbit.1819Let [3Xx[0m be a rational vector from [0,1)^n and [3Xgroup[0m a space group in standard20form. The function then calculates the part of the orbit which lies inside21the cube [0,1)^n and the stabilizer of [3Xx[0m. Observe that every element of the22full orbit differs from a point in the returned orbit only by a pure23translation.2425Note that the restriction to points from [0,1)^n makes sense if orbits26should be compared and the vector passed to [10XOrbitStabilizerInUnitCubeOnRight[0m27should be an element of the returned orbit (part).2829[4X--------------------------- Example ----------------------------[0X30[4X [0X31[4Xgap> S:=SpaceGroup(3,5);;[0X32[4Xgap> OrbitStabilizerInUnitCubeOnRight(S,[1/2,0,9/11]); [0X33[4Xrec( orbit := [ [ 0, 1/2, 2/11 ], [ 1/2, 0, 9/11 ] ], [0X34[4X stabilizer := Group([ [ [ 1, 0, 0, 0 ], [ 0, 1, 0, 0 ], [ 0, 0, 1, 0 ], [0X35[4X [ 0, 0, 0, 1 ] ] ]) )[0X36[4Xgap> OrbitStabilizerInUnitCubeOnRight(S,[0,0,0]); [0X37[4Xrec( orbit := [ [ 0, 0, 0 ] ], stabilizer := <matrix group with 2 generators> )[0X38[4X[0X39[4X------------------------------------------------------------------[0X4041If you are interested in other parts of the orbit, you can use [2XVectorModOne[0m42([14X2.1-2[0m) for the base point and the functions [2XShiftedOrbitPart[0m ([14X3.1-9[0m),43[2XTranslationsToOneCubeAroundCenter[0m ([14X3.1-10[0m) and [2XTranslationsToBox[0m ([14X3.1-11[0m)44for the resulting orbit45Suppose we want to calculate the part of the orbit of [10X[4/3,5/3,7/3][0m in the46cube of sidelength [10X1[0m around this point:4748[4X--------------------------- Example ----------------------------[0X49[4Xgap> S:=SpaceGroup(3,5);;[0X50[4Xgap> p:=[4/3,5/3,7/3];;[0X51[4Xgap> o:=OrbitStabilizerInUnitCubeOnRight(S,VectorModOne(p)).orbit;[0X52[4X[ [ 1/3, 2/3, 1/3 ], [ 1/3, 2/3, 2/3 ] ][0X53[4Xgap> box:=p+[[-1,1],[-1,1],[-1,1]];[0X54[4X[ [ 1/3, 8/3, 7/3 ], [ 1/3, 8/3, 7/3 ], [ 1/3, 8/3, 7/3 ] ][0X55[4Xgap> o2:=Concatenation(List(o,i->i+TranslationsToBox(i,box)));;[0X56[4Xgap> # This is what we looked for. But it is somewhat large:[0X57[4Xgap> Size(o2);[0X58[4X54[0X59[4X------------------------------------------------------------------[0X6061[1X3.1-2 OrbitStabilizerInUnitCubeOnRightOnSets[0m6263[2X> OrbitStabilizerInUnitCubeOnRightOnSets( [0X[3Xgroup, set[0X[2X ) _______________[0Xmethod64[6XReturns:[0X A record containing6566-- [9X.stabilizer[0m: the stabilizer of [3Xset[0m.6768-- [9X.orbit[0m set of sets of vectors from [0,1)^n which represents69the orbit.7071Calculates orbit and stabilizer of a set of vectors. Just as72[2XOrbitStabilizerInUnitCubeOnRight[0m ([14X3.1-1[0m), it needs input from [0,1)^n. The73returned orbit part [9X.orbit[0m is a set of sets such that every element of74[9X.orbit[0m has a non-trivial intersection with the cube [0,1)^n. In general,75these sets will not lie inside [0,1)^n completely.7677[4X--------------------------- Example ----------------------------[0X78[4Xgap> S:=SpaceGroup(3,5);;[0X79[4Xgap> OrbitStabilizerInUnitCubeOnRightOnSets(S,[[0,0,0],[0,1/2,0]]);[0X80[4Xrec( orbit := [ [ [ -1/2, 0, 0 ], [ 0, 0, 0 ] ], [0X81[4X [ [ 0, 0, 0 ], [ 0, 1/2, 0 ] ],[0X82[4X [ [ 1/2, 0, 0 ], [ 1, 0, 0 ] ] ],[0X83[4X stabilizer := Group([ [ [ 1, 0, 0, 0 ], [ 0, 1, 0, 0 ], [0X84[4X [ 0, 0, 1, 0 ], [ 0, 0, 0, 1 ] ] ]) )[0X85[4X------------------------------------------------------------------[0X8687[1X3.1-3 OrbitPartInVertexSetsStandardSpaceGroup[0m8889[2X> OrbitPartInVertexSetsStandardSpaceGroup( [0X[3Xgroup, vertexset, allvertices[0X[2X ) [0Xmethod90[6XReturns:[0X Set of subsets of [3Xallvertices[0m.9192If [3Xallvertices[0m is a set of vectors and [3Xvertexset[0m is a subset thereof, then93[2XOrbitPartInVertexSetsStandardSpaceGroup[0m returns that part of the orbit of94[3Xvertexset[0m which consists entirely of subsets of [3Xallvertices[0m. Note95that,unlike the other [10XOrbitStabilizer[0m algorithms, this does not require the96input to lie in some particular part of the space.9798[4X--------------------------- Example ----------------------------[0X99[4Xgap> S:=SpaceGroup(3,5);;[0X100[4Xgap> OrbitPartInVertexSetsStandardSpaceGroup(S,[[0,1,5],[1,2,0]],[0X101[4X> Set([[1,2,0],[2,3,1],[1,2,6],[1,1,0],[0,1,5],[3/5,7,12],[1/17,6,1/2]]));[0X102[4X[ [ [ 0, 1, 5 ], [ 1, 2, 0 ] ], [ [ 1, 2, 6 ], [ 2, 3, 1 ] ] ][0X103[4Xgap> OrbitPartInVertexSetsStandardSpaceGroup(S, [[1,2,0]],[0X104[4X> Set([[1,2,0],[2,3,1],[1,2,6],[1,1,0],[0,1,5],[3/5,7,12],[1/17,6,1/2]]));[0X105[4X[ [ [ 0, 1, 5 ] ], [ [ 1, 1, 0 ] ], [ [ 1, 2, 0 ] ], [ [ 1, 2, 6 ] ], [ [ 2, 3, 1 ] ] ][0X106[4X------------------------------------------------------------------[0X107108[1X3.1-4 OrbitPartInFacesStandardSpaceGroup[0m109110[2X> OrbitPartInFacesStandardSpaceGroup( [0X[3Xgroup, vertexset, faceset[0X[2X ) ____[0Xmethod111[6XReturns:[0X Set of subsets of [3Xfaceset[0m.112113This calculates the orbit of a space group on sets restricted to a set of114faces.115If [3Xfaceset[0m is a set of sets of vectors and [3Xvertexset[0m is an element of116[3Xfaceset[0m, then [2XOrbitPartInFacesStandardSpaceGroup[0m returns that part of the117orbit of [3Xvertexset[0m which consists entirely of elements of [3Xfaceset[0m.118Note that,unlike the other [10XOrbitStabilizer[0m algorithms, this does not require119the input to lie in some particular part of the space.120121[1X3.1-5 OrbitPartAndRepresentativesInFacesStandardSpaceGroup[0m122123[2X> OrbitPartAndRepresentativesInFacesStandardSpaceGroup( [0X[3Xgroup, vertexset, faceset[0X[2X ) [0Xmethod124[6XReturns:[0X A set of face-matrix pairs .125126This is a slight variation of [2XOrbitPartInFacesStandardSpaceGroup[0m ([14X3.1-4[0m)127that also returns a representative for every orbit element.128129[4X--------------------------- Example ----------------------------[0X130[4Xgap> S:=SpaceGroup(3,5);;[0X131[4Xgap> OrbitPartInVertexSetsStandardSpaceGroup(S,[[0,1,5],[1,2,0]],[0X132[4X> Set([[1,2,0],[2,3,1],[1,2,6],[1,1,0],[0,1,5],[3/5,7,12],[1/17,6,1/2]]));[0X133[4X[ [ [ 0, 1, 5 ], [ 1, 2, 0 ] ], [ [ 1, 2, 6 ], [ 2, 3, 1 ] ] ][0X134[4Xgap> OrbitPartInFacesStandardSpaceGroup(S,[[0,1,5],[1,2,0]],[0X135[4X> Set( [ [ [ 0, 1, 5 ], [ 1, 2, 0 ] ], [[1/17,6,1/2],[1,2,7]]]));[0X136[4X[ [ [ 0, 1, 5 ], [ 1, 2, 0 ] ] ][0X137[4Xgap> OrbitPartAndRepresentativesInFacesStandardSpaceGroup(S,[[0,1,5],[1,2,0]],[0X138[4X> Set( [ [ [ 0, 1, 5 ], [ 1, 2, 0 ] ], [[1/17,6,1/2],[1,2,7]]]));[0X139[4X[ [ [ [ 0, 1, 5 ], [ 1, 2, 0 ] ],[0X140[4X [ [ 1, 0, 0, 0 ], [ 0, 1, 0, 0 ], [ 0, 0, 1, 0 ], [ 0, 0, 0, 1 ] ] ] ][0X141[4X------------------------------------------------------------------[0X142143[1X3.1-6 StabilizerOnSetsStandardSpaceGroup[0m144145[2X> StabilizerOnSetsStandardSpaceGroup( [0X[3Xgroup, set[0X[2X ) ___________________[0Xmethod146[6XReturns:[0X finite group of affine matrices (OnRight)147148Given a set [3Xset[0m of vectors and a space group [3Xgroup[0m in standard form, this149method calculates the stabilizer of that set in the full crystallographic150group.151152[4X--------------------------- Example ----------------------------[0X153[4X[0X154[4Xgap> G:=SpaceGroup(3,12);;[0X155[4Xgap> v:=[ 0, 0,0 ];;[0X156[4Xgap> s:=StabilizerOnSetsStandardSpaceGroup(G,[v]);[0X157[4X<matrix group with 2 generators>[0X158[4Xgap> s2:=OrbitStabilizerInUnitCubeOnRight(G,v).stabilizer;[0X159[4X<matrix group with 2 generators>[0X160[4Xgap> s2=s;[0X161[4Xtrue[0X162[4X[0X163[4X------------------------------------------------------------------[0X164165[1X3.1-7 RepresentativeActionOnRightOnSets[0m166167[2X> RepresentativeActionOnRightOnSets( [0X[3Xgroup, set, imageset[0X[2X ) __________[0Xmethod168[6XReturns:[0X Affine matrix.169170Returns an element of the space group S which takes the set [3Xset[0m to the set171[3Ximageset[0m. The group must be in standard form and act on the right.172173[4X--------------------------- Example ----------------------------[0X174[4Xgap> S:=SpaceGroup(3,5);;[0X175[4Xgap> RepresentativeActionOnRightOnSets(G, [[0,0,0],[0,1/2,0]],[0X176[4X> [ [ 0, 1/2, 0 ], [ 0, 1, 0 ] ]);[0X177[4X[ [ 0, -1, 0, 0 ], [ -1, 0, 0, 0 ], [ 0, 0, -1, 0 ], [ 0, 1, 0, 1 ] ][0X178[4X------------------------------------------------------------------[0X179180181[1X3.1-8 Getting other orbit parts[0X182183[5XHAPcryst[0m does not calculate the full orbit but only the part of it having184coefficients between -1/2 and 1/2. The other parts of the orbit can be185calculated using the following functions.186187[1X3.1-9 ShiftedOrbitPart[0m188189[2X> ShiftedOrbitPart( [0X[3Xpoint, orbitpart[0X[2X ) _______________________________[0Xmethod190[6XReturns:[0X Set of vectors191192Takes each vector in [3Xorbitpart[0m to the cube unit cube centered in [3Xpoint[0m.193194[4X--------------------------- Example ----------------------------[0X195[4Xgap> ShiftedOrbitPart([0,0,0],[[1/2,1/2,1/3],-[1/2,1/2,1/2],[19,3,1]]);[0X196[4X[ [ 1/2, 1/2, 1/3 ], [ 1/2, 1/2, 1/2 ], [ 0, 0, 0 ] ][0X197[4Xgap> ShiftedOrbitPart([1,1,1],[[1/2,1/2,1/2],-[1/2,1/2,1/2]]);[0X198[4X[ [ 3/2, 3/2, 3/2 ] ][0X199[4X------------------------------------------------------------------[0X200201[1X3.1-10 TranslationsToOneCubeAroundCenter[0m202203[2X> TranslationsToOneCubeAroundCenter( [0X[3Xpoint, center[0X[2X ) _________________[0Xmethod204[6XReturns:[0X List of integer vectors205206This method returns the list of all integer vectors which translate [3Xpoint[0m207into the box [3Xcenter[0m+[-1/2,1/2]^n208209[4X--------------------------- Example ----------------------------[0X210[4Xgap> TranslationsToOneCubeAroundCenter([1/2,1/2,1/3],[0,0,0]);[0X211[4X[ [ 0, 0, 0 ], [ 0, -1, 0 ], [ -1, 0, 0 ], [ -1, -1, 0 ] ][0X212[4Xgap> TranslationsToOneCubeAroundCenter([1,0,1],[0,0,0]);[0X213[4X[ [ -1, 0, -1 ] ][0X214[4X------------------------------------------------------------------[0X215216[1X3.1-11 TranslationsToBox[0m217218[2X> TranslationsToBox( [0X[3Xpoint, box[0X[2X ) ____________________________________[0Xmethod219[6XReturns:[0X An iterator of integer vectors or the empty iterator220221Given a vector v and a list of pairs, this function returns the translation222vectors (integer vectors) which take v into the box [3Xbox[0m. The box [3Xbox[0m has to223be given as a list of pairs.224225[4X--------------------------- Example ----------------------------[0X226[4Xgap> TranslationsToBox([0,0],[[1/2,2/3],[1/2,2/3]]);[0X227[4X[ ][0X228[4Xgap> TranslationsToBox([0,0],[[-3/2,1/2],[1,4/3]]);[0X229[4X[ [ -1, 1 ], [ 0, 1 ] ][0X230[4Xgap> TranslationsToBox([0,0],[[-3/2,1/2],[2,1]]);[0X231[4XError, Box must not be empty called from[0X232[4X...[0X233[4X------------------------------------------------------------------[0X234235236237