passagemath-gap-pkg-semigroups 10.6.29__cp312-abi3-macosx_14_0_arm64.whl
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Potentially problematic release.
This version of passagemath-gap-pkg-semigroups might be problematic. Click here for more details.
- gap/pkg/semigroups/CHANGELOG.md +1699 -0
- gap/pkg/semigroups/CONTRIBUTING.md +91 -0
- gap/pkg/semigroups/GNUmakefile +110 -0
- gap/pkg/semigroups/GNUmakefile.in +110 -0
- gap/pkg/semigroups/GPL +674 -0
- gap/pkg/semigroups/LICENSE +16 -0
- gap/pkg/semigroups/Makefile +26 -0
- gap/pkg/semigroups/Makefile.gappkg +225 -0
- gap/pkg/semigroups/PackageInfo.g +529 -0
- gap/pkg/semigroups/README.md +102 -0
- gap/pkg/semigroups/VERSIONS +112 -0
- gap/pkg/semigroups/aclocal.m4 +375 -0
- gap/pkg/semigroups/autogen.sh +25 -0
- gap/pkg/semigroups/bin/aarch64-apple-darwin23-default64-kv10/semigroups.so +0 -0
- gap/pkg/semigroups/config.guess +1807 -0
- gap/pkg/semigroups/config.log +1157 -0
- gap/pkg/semigroups/config.status +1132 -0
- gap/pkg/semigroups/config.sub +1960 -0
- gap/pkg/semigroups/configure +9742 -0
- gap/pkg/semigroups/configure.ac +71 -0
- gap/pkg/semigroups/data/doc/greens.pickle +1 -0
- gap/pkg/semigroups/data/gens/fullbool-8.pickle.gz +0 -0
- gap/pkg/semigroups/data/gens/fullbool.pickle.gz +0 -0
- gap/pkg/semigroups/data/gens/hall.pickle.gz +0 -0
- gap/pkg/semigroups/data/gens/reflex-6.pickle.gz +0 -0
- gap/pkg/semigroups/data/gens/reflex.pickle.gz +0 -0
- gap/pkg/semigroups/data/tst/bipart4 +10 -0
- gap/pkg/semigroups/data/tst/pperm10 +1 -0
- gap/pkg/semigroups/data/tst/tables.gz +0 -0
- gap/pkg/semigroups/data/tst/testdata +1 -0
- gap/pkg/semigroups/data/tst/testinstall.pickle +1 -0
- gap/pkg/semigroups/data/tst/trans3 +7 -0
- gap/pkg/semigroups/data/tst/trans3-old +7 -0
- gap/pkg/semigroups/environment.yml +7 -0
- gap/pkg/semigroups/gap/attributes/acting.gd +15 -0
- gap/pkg/semigroups/gap/attributes/acting.gi +297 -0
- gap/pkg/semigroups/gap/attributes/attr.gd +91 -0
- gap/pkg/semigroups/gap/attributes/attr.gi +1214 -0
- gap/pkg/semigroups/gap/attributes/dual.gd +25 -0
- gap/pkg/semigroups/gap/attributes/dual.gi +209 -0
- gap/pkg/semigroups/gap/attributes/factor.gd +17 -0
- gap/pkg/semigroups/gap/attributes/factor.gi +453 -0
- gap/pkg/semigroups/gap/attributes/homomorph.gd +84 -0
- gap/pkg/semigroups/gap/attributes/homomorph.gi +591 -0
- gap/pkg/semigroups/gap/attributes/inverse.gd +38 -0
- gap/pkg/semigroups/gap/attributes/inverse.gi +708 -0
- gap/pkg/semigroups/gap/attributes/isomorph.gd +16 -0
- gap/pkg/semigroups/gap/attributes/isomorph.gi +377 -0
- gap/pkg/semigroups/gap/attributes/isorms.gd +49 -0
- gap/pkg/semigroups/gap/attributes/isorms.gi +1383 -0
- gap/pkg/semigroups/gap/attributes/maximal.gd +16 -0
- gap/pkg/semigroups/gap/attributes/maximal.gi +1876 -0
- gap/pkg/semigroups/gap/attributes/properties.gd +109 -0
- gap/pkg/semigroups/gap/attributes/properties.gi +1658 -0
- gap/pkg/semigroups/gap/attributes/rms-translat.gd +39 -0
- gap/pkg/semigroups/gap/attributes/rms-translat.gi +1078 -0
- gap/pkg/semigroups/gap/attributes/semifp.gd +12 -0
- gap/pkg/semigroups/gap/attributes/semifp.gi +84 -0
- gap/pkg/semigroups/gap/attributes/translat.gd +474 -0
- gap/pkg/semigroups/gap/attributes/translat.gi +1779 -0
- gap/pkg/semigroups/gap/congruences/cong.gd +154 -0
- gap/pkg/semigroups/gap/congruences/cong.gi +351 -0
- gap/pkg/semigroups/gap/congruences/conginv.gd +38 -0
- gap/pkg/semigroups/gap/congruences/conginv.gi +589 -0
- gap/pkg/semigroups/gap/congruences/conglatt.gd +101 -0
- gap/pkg/semigroups/gap/congruences/conglatt.gi +886 -0
- gap/pkg/semigroups/gap/congruences/congpairs.gd +21 -0
- gap/pkg/semigroups/gap/congruences/congpairs.gi +272 -0
- gap/pkg/semigroups/gap/congruences/congpart.gd +90 -0
- gap/pkg/semigroups/gap/congruences/congpart.gi +449 -0
- gap/pkg/semigroups/gap/congruences/congrees.gd +20 -0
- gap/pkg/semigroups/gap/congruences/congrees.gi +313 -0
- gap/pkg/semigroups/gap/congruences/congrms.gd +54 -0
- gap/pkg/semigroups/gap/congruences/congrms.gi +1467 -0
- gap/pkg/semigroups/gap/congruences/congsemigraph.gd +28 -0
- gap/pkg/semigroups/gap/congruences/congsemigraph.gi +289 -0
- gap/pkg/semigroups/gap/congruences/congsimple.gd +27 -0
- gap/pkg/semigroups/gap/congruences/congsimple.gi +236 -0
- gap/pkg/semigroups/gap/congruences/conguniv.gd +20 -0
- gap/pkg/semigroups/gap/congruences/conguniv.gi +271 -0
- gap/pkg/semigroups/gap/congruences/congwordgraph.gd +21 -0
- gap/pkg/semigroups/gap/congruences/congwordgraph.gi +250 -0
- gap/pkg/semigroups/gap/elements/bipart.gd +71 -0
- gap/pkg/semigroups/gap/elements/bipart.gi +995 -0
- gap/pkg/semigroups/gap/elements/blocks.gd +31 -0
- gap/pkg/semigroups/gap/elements/blocks.gi +134 -0
- gap/pkg/semigroups/gap/elements/boolmat.gd +74 -0
- gap/pkg/semigroups/gap/elements/boolmat.gi +726 -0
- gap/pkg/semigroups/gap/elements/elements.gd +11 -0
- gap/pkg/semigroups/gap/elements/elements.gi +121 -0
- gap/pkg/semigroups/gap/elements/ffmat.gd +71 -0
- gap/pkg/semigroups/gap/elements/ffmat.gi +311 -0
- gap/pkg/semigroups/gap/elements/maxplusmat.gd +131 -0
- gap/pkg/semigroups/gap/elements/maxplusmat.gi +782 -0
- gap/pkg/semigroups/gap/elements/pbr.gd +51 -0
- gap/pkg/semigroups/gap/elements/pbr.gi +740 -0
- gap/pkg/semigroups/gap/elements/pperm.gd +11 -0
- gap/pkg/semigroups/gap/elements/pperm.gi +14 -0
- gap/pkg/semigroups/gap/elements/semiringmat.gd +136 -0
- gap/pkg/semigroups/gap/elements/semiringmat.gi +717 -0
- gap/pkg/semigroups/gap/elements/star.gd +21 -0
- gap/pkg/semigroups/gap/elements/star.gi +21 -0
- gap/pkg/semigroups/gap/elements/trans.gd +13 -0
- gap/pkg/semigroups/gap/elements/trans.gi +50 -0
- gap/pkg/semigroups/gap/fp/freeband.gd +22 -0
- gap/pkg/semigroups/gap/fp/freeband.gi +502 -0
- gap/pkg/semigroups/gap/fp/freeinverse.gd +30 -0
- gap/pkg/semigroups/gap/fp/freeinverse.gi +465 -0
- gap/pkg/semigroups/gap/fp/tietze.gd +89 -0
- gap/pkg/semigroups/gap/fp/tietze.gi +1578 -0
- gap/pkg/semigroups/gap/fp/word.gd +15 -0
- gap/pkg/semigroups/gap/fp/word.gi +67 -0
- gap/pkg/semigroups/gap/greens/acting-inverse.gi +774 -0
- gap/pkg/semigroups/gap/greens/acting-regular.gi +553 -0
- gap/pkg/semigroups/gap/greens/acting.gd +81 -0
- gap/pkg/semigroups/gap/greens/acting.gi +2433 -0
- gap/pkg/semigroups/gap/greens/froidure-pin.gd +25 -0
- gap/pkg/semigroups/gap/greens/froidure-pin.gi +741 -0
- gap/pkg/semigroups/gap/greens/generic.gd +117 -0
- gap/pkg/semigroups/gap/greens/generic.gi +630 -0
- gap/pkg/semigroups/gap/ideals/acting.gd +17 -0
- gap/pkg/semigroups/gap/ideals/acting.gi +1155 -0
- gap/pkg/semigroups/gap/ideals/froidure-pin.gd +11 -0
- gap/pkg/semigroups/gap/ideals/froidure-pin.gi +105 -0
- gap/pkg/semigroups/gap/ideals/ideals.gd +45 -0
- gap/pkg/semigroups/gap/ideals/ideals.gi +442 -0
- gap/pkg/semigroups/gap/ideals/lambda-rho.gd +16 -0
- gap/pkg/semigroups/gap/ideals/lambda-rho.gi +614 -0
- gap/pkg/semigroups/gap/libsemigroups/cong.gd +24 -0
- gap/pkg/semigroups/gap/libsemigroups/cong.gi +431 -0
- gap/pkg/semigroups/gap/libsemigroups/fpsemi.gd +16 -0
- gap/pkg/semigroups/gap/libsemigroups/fpsemi.gi +53 -0
- gap/pkg/semigroups/gap/libsemigroups/froidure-pin.gd +17 -0
- gap/pkg/semigroups/gap/libsemigroups/froidure-pin.gi +945 -0
- gap/pkg/semigroups/gap/libsemigroups/sims1.gd +38 -0
- gap/pkg/semigroups/gap/libsemigroups/sims1.gi +308 -0
- gap/pkg/semigroups/gap/main/acting.gd +36 -0
- gap/pkg/semigroups/gap/main/acting.gi +779 -0
- gap/pkg/semigroups/gap/main/froidure-pin.gd +72 -0
- gap/pkg/semigroups/gap/main/froidure-pin.gi +655 -0
- gap/pkg/semigroups/gap/main/graded.gd +26 -0
- gap/pkg/semigroups/gap/main/graded.gi +355 -0
- gap/pkg/semigroups/gap/main/lambda-rho.gd +29 -0
- gap/pkg/semigroups/gap/main/lambda-rho.gi +514 -0
- gap/pkg/semigroups/gap/main/orbits.gd +24 -0
- gap/pkg/semigroups/gap/main/orbits.gi +512 -0
- gap/pkg/semigroups/gap/main/semiact.gd +20 -0
- gap/pkg/semigroups/gap/main/semiact.gi +821 -0
- gap/pkg/semigroups/gap/main/setup.gd +61 -0
- gap/pkg/semigroups/gap/main/setup.gi +1094 -0
- gap/pkg/semigroups/gap/obsolete.gd +9 -0
- gap/pkg/semigroups/gap/obsolete.gi +14 -0
- gap/pkg/semigroups/gap/options.g +55 -0
- gap/pkg/semigroups/gap/semigroups/grpperm.gd +12 -0
- gap/pkg/semigroups/gap/semigroups/grpperm.gi +177 -0
- gap/pkg/semigroups/gap/semigroups/semibipart.gd +28 -0
- gap/pkg/semigroups/gap/semigroups/semibipart.gi +570 -0
- gap/pkg/semigroups/gap/semigroups/semiboolmat.gd +20 -0
- gap/pkg/semigroups/gap/semigroups/semiboolmat.gi +104 -0
- gap/pkg/semigroups/gap/semigroups/semicons.gd +52 -0
- gap/pkg/semigroups/gap/semigroups/semicons.gi +1194 -0
- gap/pkg/semigroups/gap/semigroups/semidp.gd +13 -0
- gap/pkg/semigroups/gap/semigroups/semidp.gi +509 -0
- gap/pkg/semigroups/gap/semigroups/semieunit.gd +126 -0
- gap/pkg/semigroups/gap/semigroups/semieunit.gi +889 -0
- gap/pkg/semigroups/gap/semigroups/semiex.gd +104 -0
- gap/pkg/semigroups/gap/semigroups/semiex.gi +1590 -0
- gap/pkg/semigroups/gap/semigroups/semiffmat.gd +37 -0
- gap/pkg/semigroups/gap/semigroups/semiffmat.gi +565 -0
- gap/pkg/semigroups/gap/semigroups/semifp.gd +28 -0
- gap/pkg/semigroups/gap/semigroups/semifp.gi +1364 -0
- gap/pkg/semigroups/gap/semigroups/semigraph.gd +40 -0
- gap/pkg/semigroups/gap/semigroups/semigraph.gi +292 -0
- gap/pkg/semigroups/gap/semigroups/semigrp.gd +165 -0
- gap/pkg/semigroups/gap/semigroups/semigrp.gi +1225 -0
- gap/pkg/semigroups/gap/semigroups/semimaxplus.gd +72 -0
- gap/pkg/semigroups/gap/semigroups/semimaxplus.gi +710 -0
- gap/pkg/semigroups/gap/semigroups/semintmat.gd +13 -0
- gap/pkg/semigroups/gap/semigroups/semintmat.gi +74 -0
- gap/pkg/semigroups/gap/semigroups/semipbr.gd +19 -0
- gap/pkg/semigroups/gap/semigroups/semipbr.gi +139 -0
- gap/pkg/semigroups/gap/semigroups/semipperm.gd +27 -0
- gap/pkg/semigroups/gap/semigroups/semipperm.gi +711 -0
- gap/pkg/semigroups/gap/semigroups/semiquo.gd +14 -0
- gap/pkg/semigroups/gap/semigroups/semiquo.gi +97 -0
- gap/pkg/semigroups/gap/semigroups/semiringmat.gd +16 -0
- gap/pkg/semigroups/gap/semigroups/semiringmat.gi +21 -0
- gap/pkg/semigroups/gap/semigroups/semirms.gd +19 -0
- gap/pkg/semigroups/gap/semigroups/semirms.gi +977 -0
- gap/pkg/semigroups/gap/semigroups/semitrans.gd +49 -0
- gap/pkg/semigroups/gap/semigroups/semitrans.gi +909 -0
- gap/pkg/semigroups/gap/tools/display.gd +24 -0
- gap/pkg/semigroups/gap/tools/display.gi +749 -0
- gap/pkg/semigroups/gap/tools/io.gd +17 -0
- gap/pkg/semigroups/gap/tools/io.gi +543 -0
- gap/pkg/semigroups/gap/tools/iterators.gd +16 -0
- gap/pkg/semigroups/gap/tools/iterators.gi +253 -0
- gap/pkg/semigroups/gap/tools/utils.gd +19 -0
- gap/pkg/semigroups/gap/tools/utils.gi +756 -0
- gap/pkg/semigroups/gapbind14/.ccls +18 -0
- gap/pkg/semigroups/gapbind14/.clang-format +104 -0
- gap/pkg/semigroups/gapbind14/CPPLINT.cfg +5 -0
- gap/pkg/semigroups/gapbind14/LICENSE +674 -0
- gap/pkg/semigroups/gapbind14/README.md +76 -0
- gap/pkg/semigroups/gapbind14/demo/.gitignore +4 -0
- gap/pkg/semigroups/gapbind14/demo/LICENSE +293 -0
- gap/pkg/semigroups/gapbind14/demo/Makefile.gappkg +220 -0
- gap/pkg/semigroups/gapbind14/demo/Makefile.in +19 -0
- gap/pkg/semigroups/gapbind14/demo/PackageInfo.g +87 -0
- gap/pkg/semigroups/gapbind14/demo/README.md +17 -0
- gap/pkg/semigroups/gapbind14/demo/configure +34 -0
- gap/pkg/semigroups/gapbind14/demo/gap/gapbind_demo.gd +19 -0
- gap/pkg/semigroups/gapbind14/demo/gap/gapbind_demo.gi +10 -0
- gap/pkg/semigroups/gapbind14/demo/init.g +16 -0
- gap/pkg/semigroups/gapbind14/demo/makedoc.g +10 -0
- gap/pkg/semigroups/gapbind14/demo/read.g +6 -0
- gap/pkg/semigroups/gapbind14/demo/src/gapbind_demo.cc +142 -0
- gap/pkg/semigroups/gapbind14/demo/tst/testall.g +12 -0
- gap/pkg/semigroups/gapbind14/include/gapbind14/cpp_fn.hpp +223 -0
- gap/pkg/semigroups/gapbind14/include/gapbind14/gap_include.hpp +26 -0
- gap/pkg/semigroups/gapbind14/include/gapbind14/gapbind14.hpp +445 -0
- gap/pkg/semigroups/gapbind14/include/gapbind14/tame_free_fn.hpp +420 -0
- gap/pkg/semigroups/gapbind14/include/gapbind14/tame_mem_fn.hpp +556 -0
- gap/pkg/semigroups/gapbind14/include/gapbind14/to_cpp.hpp +162 -0
- gap/pkg/semigroups/gapbind14/include/gapbind14/to_gap.hpp +158 -0
- gap/pkg/semigroups/gapbind14/src/.clang-format +108 -0
- gap/pkg/semigroups/gapbind14/src/gapbind14.cpp +334 -0
- gap/pkg/semigroups/init.g +150 -0
- gap/pkg/semigroups/m4/ax_append_flag.m4 +50 -0
- gap/pkg/semigroups/m4/ax_check_compile_flag.m4 +53 -0
- gap/pkg/semigroups/m4/ax_check_hpcombi.m4 +121 -0
- gap/pkg/semigroups/m4/ax_check_libsemigroup.m4 +68 -0
- gap/pkg/semigroups/m4/ax_compare_version.m4 +177 -0
- gap/pkg/semigroups/m4/ax_cxx_compile_stdcxx.m4 +1009 -0
- gap/pkg/semigroups/m4/ax_cxx_compile_stdcxx_14.m4 +34 -0
- gap/pkg/semigroups/m4/ax_prefix_config_h.m4 +203 -0
- gap/pkg/semigroups/m4/ax_pthread.m4 +522 -0
- gap/pkg/semigroups/m4/find_gap.m4 +94 -0
- gap/pkg/semigroups/makedoc.g +153 -0
- gap/pkg/semigroups/prerequisites.sh +62 -0
- gap/pkg/semigroups/read.g +105 -0
- gap/pkg/semigroups/release.toml +6 -0
- gap/pkg/semigroups/tst/extreme/README +2 -0
- gap/pkg/semigroups/tst/extreme/attrinv.tst +703 -0
- gap/pkg/semigroups/tst/extreme/bipart.tst +2803 -0
- gap/pkg/semigroups/tst/extreme/closure.tst +652 -0
- gap/pkg/semigroups/tst/extreme/cong.tst +286 -0
- gap/pkg/semigroups/tst/extreme/conginv.tst +43 -0
- gap/pkg/semigroups/tst/extreme/examples.tst +2449 -0
- gap/pkg/semigroups/tst/extreme/freeband.tst +37 -0
- gap/pkg/semigroups/tst/extreme/greens-acting-regular.tst +27 -0
- gap/pkg/semigroups/tst/extreme/greens-acting.tst +1999 -0
- gap/pkg/semigroups/tst/extreme/ideals.tst +858 -0
- gap/pkg/semigroups/tst/extreme/inverse.tst +1025 -0
- gap/pkg/semigroups/tst/extreme/maximal.tst +856 -0
- gap/pkg/semigroups/tst/extreme/misc.tst +4236 -0
- gap/pkg/semigroups/tst/extreme/monoid_pkg.tst +1488 -0
- gap/pkg/semigroups/tst/extreme/properties.tst +914 -0
- gap/pkg/semigroups/tst/extreme/semibipart.tst +2837 -0
- gap/pkg/semigroups/tst/extreme/semieunit.tst +49 -0
- gap/pkg/semigroups/tst/extreme/semiffmat.tst +353 -0
- gap/pkg/semigroups/tst/extreme/semigroups.tst +245 -0
- gap/pkg/semigroups/tst/extreme/semiiter.tst +58 -0
- gap/pkg/semigroups/tst/extreme/semirms.tst +1091 -0
- gap/pkg/semigroups/tst/extreme/transform.tst +305 -0
- gap/pkg/semigroups/tst/extreme/translat.tst +44 -0
- gap/pkg/semigroups/tst/standard/README +2 -0
- gap/pkg/semigroups/tst/standard/attributes/acting.tst +388 -0
- gap/pkg/semigroups/tst/standard/attributes/attr.tst +2404 -0
- gap/pkg/semigroups/tst/standard/attributes/dual.tst +308 -0
- gap/pkg/semigroups/tst/standard/attributes/factor.tst +629 -0
- gap/pkg/semigroups/tst/standard/attributes/homomorph.tst +1134 -0
- gap/pkg/semigroups/tst/standard/attributes/inverse.tst +1521 -0
- gap/pkg/semigroups/tst/standard/attributes/isomorph.tst +435 -0
- gap/pkg/semigroups/tst/standard/attributes/isorms.tst +1147 -0
- gap/pkg/semigroups/tst/standard/attributes/maximal.tst +853 -0
- gap/pkg/semigroups/tst/standard/attributes/properties.tst +2028 -0
- gap/pkg/semigroups/tst/standard/attributes/semifp.tst +53 -0
- gap/pkg/semigroups/tst/standard/attributes/translat.tst +796 -0
- gap/pkg/semigroups/tst/standard/congruences/cong.tst +1044 -0
- gap/pkg/semigroups/tst/standard/congruences/conginv.tst +292 -0
- gap/pkg/semigroups/tst/standard/congruences/conglatt.tst +421 -0
- gap/pkg/semigroups/tst/standard/congruences/congpairs.tst +1011 -0
- gap/pkg/semigroups/tst/standard/congruences/congrees.tst +288 -0
- gap/pkg/semigroups/tst/standard/congruences/congrms.tst +701 -0
- gap/pkg/semigroups/tst/standard/congruences/congsemigraph.tst +422 -0
- gap/pkg/semigroups/tst/standard/congruences/congsimple.tst +311 -0
- gap/pkg/semigroups/tst/standard/congruences/conguniv.tst +259 -0
- gap/pkg/semigroups/tst/standard/congruences/congwordgraph.tst +330 -0
- gap/pkg/semigroups/tst/standard/elements/bipart.tst +783 -0
- gap/pkg/semigroups/tst/standard/elements/blocks.tst +166 -0
- gap/pkg/semigroups/tst/standard/elements/boolmat.tst +608 -0
- gap/pkg/semigroups/tst/standard/elements/elements.tst +117 -0
- gap/pkg/semigroups/tst/standard/elements/ffmat.tst +349 -0
- gap/pkg/semigroups/tst/standard/elements/maxplusmat.tst +613 -0
- gap/pkg/semigroups/tst/standard/elements/pbr.tst +506 -0
- gap/pkg/semigroups/tst/standard/elements/pperm.tst +32 -0
- gap/pkg/semigroups/tst/standard/elements/semiringmat.tst +601 -0
- gap/pkg/semigroups/tst/standard/elements/trans.tst +58 -0
- gap/pkg/semigroups/tst/standard/fp/freeband.tst +311 -0
- gap/pkg/semigroups/tst/standard/fp/freeinverse.tst +147 -0
- gap/pkg/semigroups/tst/standard/fp/tietze.tst +780 -0
- gap/pkg/semigroups/tst/standard/fp/word.tst +106 -0
- gap/pkg/semigroups/tst/standard/greens/acting-inverse.tst +545 -0
- gap/pkg/semigroups/tst/standard/greens/acting-regular.tst +396 -0
- gap/pkg/semigroups/tst/standard/greens/acting.tst +2033 -0
- gap/pkg/semigroups/tst/standard/greens/froidure-pin.tst +1831 -0
- gap/pkg/semigroups/tst/standard/greens/generic.tst +1436 -0
- gap/pkg/semigroups/tst/standard/ideals/acting.tst +279 -0
- gap/pkg/semigroups/tst/standard/ideals/froidure-pin.tst +178 -0
- gap/pkg/semigroups/tst/standard/ideals/ideals.tst +380 -0
- gap/pkg/semigroups/tst/standard/libsemigroups/cong.tst +310 -0
- gap/pkg/semigroups/tst/standard/libsemigroups/froidure-pin.tst +778 -0
- gap/pkg/semigroups/tst/standard/libsemigroups/sims1.tst +379 -0
- gap/pkg/semigroups/tst/standard/main/acting.tst +411 -0
- gap/pkg/semigroups/tst/standard/main/froidure-pin.tst +392 -0
- gap/pkg/semigroups/tst/standard/main/semiact.tst +203 -0
- gap/pkg/semigroups/tst/standard/main/setup.tst +1144 -0
- gap/pkg/semigroups/tst/standard/obsolete.tst +19 -0
- gap/pkg/semigroups/tst/standard/options.tst +54 -0
- gap/pkg/semigroups/tst/standard/semigroups/grpperm.tst +581 -0
- gap/pkg/semigroups/tst/standard/semigroups/semibipart.tst +2635 -0
- gap/pkg/semigroups/tst/standard/semigroups/semiboolmat.tst +1871 -0
- gap/pkg/semigroups/tst/standard/semigroups/semicons.tst +1173 -0
- gap/pkg/semigroups/tst/standard/semigroups/semidp.tst +739 -0
- gap/pkg/semigroups/tst/standard/semigroups/semieunit.tst +339 -0
- gap/pkg/semigroups/tst/standard/semigroups/semiex.tst +2055 -0
- gap/pkg/semigroups/tst/standard/semigroups/semiffmat.tst +746 -0
- gap/pkg/semigroups/tst/standard/semigroups/semifp.tst +2702 -0
- gap/pkg/semigroups/tst/standard/semigroups/semigraph.tst +133 -0
- gap/pkg/semigroups/tst/standard/semigroups/semigrp.tst +1112 -0
- gap/pkg/semigroups/tst/standard/semigroups/semimaxplus.tst +654 -0
- gap/pkg/semigroups/tst/standard/semigroups/semipbr.tst +2142 -0
- gap/pkg/semigroups/tst/standard/semigroups/semipperm.tst +2169 -0
- gap/pkg/semigroups/tst/standard/semigroups/semiquo.tst +278 -0
- gap/pkg/semigroups/tst/standard/semigroups/semirms.tst +3010 -0
- gap/pkg/semigroups/tst/standard/semigroups/semitrans.tst +2758 -0
- gap/pkg/semigroups/tst/standard/tools/display.tst +1040 -0
- gap/pkg/semigroups/tst/standard/tools/io.tst +363 -0
- gap/pkg/semigroups/tst/testinstall.tst +1815 -0
- gap/pkg/semigroups/tst/teststandard.g +22 -0
- gap/pkg/semigroups/tst/workspaces/load-workspace.tst +142 -0
- gap/pkg/semigroups/tst/workspaces/load.g +11 -0
- gap/pkg/semigroups/tst/workspaces/save-workspace.tst +166 -0
- gap/pkg/semigroups/tst/workspaces/save.g +14 -0
- passagemath_gap_pkg_semigroups-10.6.29.dist-info/METADATA +93 -0
- passagemath_gap_pkg_semigroups-10.6.29.dist-info/METADATA.bak +94 -0
- passagemath_gap_pkg_semigroups-10.6.29.dist-info/RECORD +354 -0
- passagemath_gap_pkg_semigroups-10.6.29.dist-info/WHEEL +6 -0
- passagemath_gap_pkg_semigroups-10.6.29.dist-info/top_level.txt +1 -0
- passagemath_gap_pkg_semigroups.dylibs/libsemigroups.2.dylib +0 -0
- sage/all__sagemath_gap_pkg_semigroups.py +1 -0
- sage/libs/all__sagemath_gap_pkg_semigroups.py +1 -0
- sage/libs/gap_pkg_semigroups.abi3.so +0 -0
|
@@ -0,0 +1,11 @@
|
|
|
1
|
+
############################################################################
|
|
2
|
+
##
|
|
3
|
+
## elements/elements.gd
|
|
4
|
+
## Copyright (C) 2016-2022 Wilf A. Wilson
|
|
5
|
+
##
|
|
6
|
+
## Licensing information can be found in the README file of this package.
|
|
7
|
+
##
|
|
8
|
+
#############################################################################
|
|
9
|
+
|
|
10
|
+
DeclareOperation("IndexPeriodOfSemigroupElement", [IsMultiplicativeElement]);
|
|
11
|
+
DeclareAttribute("SmallestIdempotentPower", IsMultiplicativeElement);
|
|
@@ -0,0 +1,121 @@
|
|
|
1
|
+
############################################################################
|
|
2
|
+
##
|
|
3
|
+
## elements/elements.gi
|
|
4
|
+
## Copyright (C) 2016-2022 Wilf A. Wilson
|
|
5
|
+
##
|
|
6
|
+
## Licensing information can be found in the README file of this package.
|
|
7
|
+
##
|
|
8
|
+
#############################################################################
|
|
9
|
+
|
|
10
|
+
SEMIGROUPS.IndexPeriodByRank := function(x, rank)
|
|
11
|
+
local k, p, s, rank_s, powers, min_rank, index, lower, next, mid, y, z,
|
|
12
|
+
period, S;
|
|
13
|
+
|
|
14
|
+
k := rank(x);
|
|
15
|
+
p := 1;
|
|
16
|
+
s := x ^ 2;
|
|
17
|
+
rank_s := rank(s);
|
|
18
|
+
powers := [x, s]; # powers[i] = x ^ (2 ^ (i - 1)), e.g. powers[5] = x ^ 16.
|
|
19
|
+
|
|
20
|
+
# Locate the index between its closest powers of 2
|
|
21
|
+
while rank_s <= k - (2 ^ (p - 1)) do
|
|
22
|
+
k := rank_s;
|
|
23
|
+
p := p + 1;
|
|
24
|
+
s := s ^ 2;
|
|
25
|
+
rank_s := rank(s);
|
|
26
|
+
Add(powers, s);
|
|
27
|
+
od;
|
|
28
|
+
|
|
29
|
+
min_rank := rank_s;
|
|
30
|
+
|
|
31
|
+
if rank(x) = min_rank then
|
|
32
|
+
index := 1;
|
|
33
|
+
else
|
|
34
|
+
# Get the specific values of the closest powers of 2 to index
|
|
35
|
+
if k = min_rank then
|
|
36
|
+
lower := p - 2;
|
|
37
|
+
else
|
|
38
|
+
lower := p - 1;
|
|
39
|
+
fi;
|
|
40
|
+
# (2 ^ lower) < index of x <= (2 ^ (lower + 1))
|
|
41
|
+
|
|
42
|
+
# index is always a lower bound for the true index
|
|
43
|
+
index := (2 ^ lower) + 1;
|
|
44
|
+
next := lower;
|
|
45
|
+
lower := powers[lower + 1];
|
|
46
|
+
|
|
47
|
+
# Perform a 'binary search' to completion to nail down the position of index
|
|
48
|
+
# The index is the *least* number such that x ^ index = min_rank
|
|
49
|
+
while next > 0 do
|
|
50
|
+
mid := lower * powers[next];
|
|
51
|
+
next := next - 1;
|
|
52
|
+
if rank(mid) <> min_rank then
|
|
53
|
+
lower := mid;
|
|
54
|
+
index := index + (2 ^ next);
|
|
55
|
+
fi;
|
|
56
|
+
od;
|
|
57
|
+
fi;
|
|
58
|
+
|
|
59
|
+
y := x ^ index;
|
|
60
|
+
z := y * x;
|
|
61
|
+
if y = z then
|
|
62
|
+
period := 1;
|
|
63
|
+
elif IsMultiplicativeElementWithOne(y) and One(y) <> fail and z = One(y) then
|
|
64
|
+
period := 2;
|
|
65
|
+
else
|
|
66
|
+
S := Semigroup(y, z);
|
|
67
|
+
SetIsGroupAsSemigroup(S, true);
|
|
68
|
+
period := Size(S);
|
|
69
|
+
fi;
|
|
70
|
+
return [index, period];
|
|
71
|
+
end;
|
|
72
|
+
|
|
73
|
+
InstallMethod(IndexPeriodOfSemigroupElement, "for a multiplicative element",
|
|
74
|
+
[IsMultiplicativeElement],
|
|
75
|
+
function(x)
|
|
76
|
+
local index, y, z, period, S;
|
|
77
|
+
|
|
78
|
+
if not IsGeneratorsOfSemigroup([x]) then
|
|
79
|
+
ErrorNoReturn("the argument (a mult. elt.) is not the generator of a ",
|
|
80
|
+
"semigroup");
|
|
81
|
+
fi;
|
|
82
|
+
index := NrDClasses(Semigroup(x));
|
|
83
|
+
y := x ^ index;
|
|
84
|
+
z := y * x;
|
|
85
|
+
if y = z then
|
|
86
|
+
period := 1;
|
|
87
|
+
elif IsMultiplicativeElementWithOne(y) and One(y) <> fail and z = One(y) then
|
|
88
|
+
period := 2;
|
|
89
|
+
else
|
|
90
|
+
S := Semigroup(y, z);
|
|
91
|
+
SetIsGroupAsSemigroup(S, true);
|
|
92
|
+
period := Size(S);
|
|
93
|
+
fi;
|
|
94
|
+
return [index, period];
|
|
95
|
+
end);
|
|
96
|
+
|
|
97
|
+
InstallMethod(SmallestIdempotentPower, "for a multiplicative element",
|
|
98
|
+
[IsMultiplicativeElement],
|
|
99
|
+
function(x)
|
|
100
|
+
local a, index, period, r;
|
|
101
|
+
|
|
102
|
+
if not IsGeneratorsOfSemigroup([x]) then
|
|
103
|
+
ErrorNoReturn("the argument (a mult. elt.) is not the generator of a ",
|
|
104
|
+
"semigroup");
|
|
105
|
+
fi;
|
|
106
|
+
a := IndexPeriodOfSemigroupElement(x);
|
|
107
|
+
index := a[1];
|
|
108
|
+
period := a[2];
|
|
109
|
+
# From Howie 1995, page 11
|
|
110
|
+
r := index mod period;
|
|
111
|
+
if r = 0 then
|
|
112
|
+
return index;
|
|
113
|
+
fi;
|
|
114
|
+
return index + period - r;
|
|
115
|
+
end);
|
|
116
|
+
|
|
117
|
+
InstallMethod(IsMultiplicativeZero,
|
|
118
|
+
"for a semigroup with multiplicative zero and multiplicative element",
|
|
119
|
+
[IsSemigroup and HasMultiplicativeZero, IsMultiplicativeElement],
|
|
120
|
+
SUM_FLAGS,
|
|
121
|
+
{S, x} -> MultiplicativeZero(S) <> fail and x = MultiplicativeZero(S));
|
|
@@ -0,0 +1,71 @@
|
|
|
1
|
+
############################################################################
|
|
2
|
+
##
|
|
3
|
+
## elements/ffmat.gd
|
|
4
|
+
## Copyright (C) 2016-2022 James D. Mitchell
|
|
5
|
+
## Markus Pfeiffer
|
|
6
|
+
##
|
|
7
|
+
## Licensing information can be found in the README file of this package.
|
|
8
|
+
##
|
|
9
|
+
############################################################################
|
|
10
|
+
##
|
|
11
|
+
|
|
12
|
+
# This file contains some minimal declarations that allow us to use the
|
|
13
|
+
# features of IsActingSemigroup with MatrixObj's of finite fields from the GAP
|
|
14
|
+
# library.
|
|
15
|
+
|
|
16
|
+
# We often need to detect whether or not a given mult. elt. is a MatrixObj with
|
|
17
|
+
# entries in a finite field, so we have the following property that answers
|
|
18
|
+
# this question.
|
|
19
|
+
DeclareProperty("IsMatrixObjOverFiniteField", IsMultiplicativeElement);
|
|
20
|
+
|
|
21
|
+
#############################################################################
|
|
22
|
+
# Declarations specifically for finite field vectors
|
|
23
|
+
#############################################################################
|
|
24
|
+
|
|
25
|
+
# The following relate to LambdaOrb and RhoOrb of a semigroup or monoid of
|
|
26
|
+
# matrices over IsMatrixObjOverFiniteField. We do not use GAP library vectors
|
|
27
|
+
# here (if they even exist) because these are essentially internal and are not
|
|
28
|
+
# expected to be created or manipulated directly by the user.
|
|
29
|
+
|
|
30
|
+
# Note that because matrices of dimension 0 are not permitted in the GAP
|
|
31
|
+
# library (possibly for good reasons, such as Is8BitMatrixRep not storing their
|
|
32
|
+
# base domain but using their entries to compute the base domain, which
|
|
33
|
+
# obviously doesn't work for 0-dim matrices which have no entries), everything
|
|
34
|
+
# inside the "acting" data structures (SemigroupData, LambdaOrb, RhoOrb etc)
|
|
35
|
+
# for a semigroup of matrices over a finite field use matrices and row bases
|
|
36
|
+
# etc of dimension 1 greater than the dimension of the matrices that are user
|
|
37
|
+
# facing.
|
|
38
|
+
|
|
39
|
+
DeclareCategory("IsRowBasisOverFiniteField", IsCollection);
|
|
40
|
+
DeclareCategoryCollections("IsRowBasisOverFiniteField");
|
|
41
|
+
DeclareConstructor("NewRowBasisOverFiniteField",
|
|
42
|
+
[IsRowBasisOverFiniteField, IsRing, IsList]);
|
|
43
|
+
|
|
44
|
+
DeclareRepresentation("IsPlistRowBasisOverFiniteFieldRep",
|
|
45
|
+
IsRowBasisOverFiniteField and IsComponentObjectRep and
|
|
46
|
+
IsAttributeStoringRep, ["rows"]);
|
|
47
|
+
|
|
48
|
+
DeclareAttribute("BaseDomain", IsRowBasisOverFiniteField);
|
|
49
|
+
|
|
50
|
+
#############################################################################
|
|
51
|
+
# Declarations specifically for finite field matrices
|
|
52
|
+
#############################################################################
|
|
53
|
+
|
|
54
|
+
# We require a number of operations for IsMatrixObjOverFiniteField that are not
|
|
55
|
+
# provided by the GAP library AFAIK at time of writing in June 2022.
|
|
56
|
+
|
|
57
|
+
# These bases are in normal form
|
|
58
|
+
DeclareAttribute("RowSpaceBasis", IsMatrixObj);
|
|
59
|
+
DeclareAttribute("RowSpaceTransformation", IsMatrixObj);
|
|
60
|
+
DeclareAttribute("RowSpaceTransformationInv", IsMatrixObj);
|
|
61
|
+
|
|
62
|
+
DeclareAttribute("RightInverse", IsMatrixObj);
|
|
63
|
+
DeclareAttribute("LeftInverse", IsMatrixObj);
|
|
64
|
+
|
|
65
|
+
DeclareOperation("OneMutable", [IsFFECollCollColl]);
|
|
66
|
+
|
|
67
|
+
#############################################################################
|
|
68
|
+
# Helper functions
|
|
69
|
+
#############################################################################
|
|
70
|
+
|
|
71
|
+
DeclareGlobalFunction("ComputeRowSpaceAndTransformation");
|
|
@@ -0,0 +1,311 @@
|
|
|
1
|
+
############################################################################
|
|
2
|
+
##
|
|
3
|
+
## elements/ffmat.gi
|
|
4
|
+
## Copyright (C) 2016-2022 James D. Mitchell
|
|
5
|
+
## Markus Pfeiffer
|
|
6
|
+
##
|
|
7
|
+
## Licensing information can be found in the README file of this package.
|
|
8
|
+
##
|
|
9
|
+
#############################################################################
|
|
10
|
+
##
|
|
11
|
+
|
|
12
|
+
#############################################################################
|
|
13
|
+
# This file contains the implementations of the operations etc declared in
|
|
14
|
+
# ffmat.gd for matrix objects over finite fields.
|
|
15
|
+
#############################################################################
|
|
16
|
+
|
|
17
|
+
#############################################################################
|
|
18
|
+
# The file is organised as follows:
|
|
19
|
+
#
|
|
20
|
+
# 1. Random matrices
|
|
21
|
+
# 2. Rows bases etc
|
|
22
|
+
# 3. Attributes etc for IsMatrixObjOverFiniteField
|
|
23
|
+
# 4. Helper functions
|
|
24
|
+
#############################################################################
|
|
25
|
+
|
|
26
|
+
# The following are only used in this file and so are declared here in the gi
|
|
27
|
+
# file.
|
|
28
|
+
|
|
29
|
+
BindGlobal("PlistRowBasisOverFiniteFieldFamily",
|
|
30
|
+
NewFamily("PlistRowBasisOverFiniteFieldFamily",
|
|
31
|
+
IsRowBasisOverFiniteField, CanEasilyCompareElements));
|
|
32
|
+
|
|
33
|
+
BindGlobal("PlistRowBasisOverFiniteFieldType",
|
|
34
|
+
NewType(PlistRowBasisOverFiniteFieldFamily,
|
|
35
|
+
IsRowBasisOverFiniteField
|
|
36
|
+
and IsPlistRowBasisOverFiniteFieldRep));
|
|
37
|
+
|
|
38
|
+
InstallMethod(IsMatrixObjOverFiniteField, "for a matrix obj",
|
|
39
|
+
[IsMultiplicativeElement],
|
|
40
|
+
function(m)
|
|
41
|
+
return IsMatrixObj(m)
|
|
42
|
+
and IsField(BaseDomain(m))
|
|
43
|
+
and IsFinite(BaseDomain(m))
|
|
44
|
+
and NrRows(m) = NrCols(m);
|
|
45
|
+
end);
|
|
46
|
+
|
|
47
|
+
InstallMethod(OneMutable, "for an FFE coll coll coll",
|
|
48
|
+
[IsFFECollCollColl], coll -> One(Representative(coll)));
|
|
49
|
+
|
|
50
|
+
###############################################################################
|
|
51
|
+
# 1. Random matrices
|
|
52
|
+
###############################################################################
|
|
53
|
+
|
|
54
|
+
# Note that: the following methods implement the RandomMatrix interface for
|
|
55
|
+
# IsMatrixOverSemiring in the Semigroups package and do not related to anything
|
|
56
|
+
# similar in the GAP library for IsMatrixObj (if they exist).
|
|
57
|
+
|
|
58
|
+
InstallMethod(RandomMatrixOp, "for a finite field and pos int",
|
|
59
|
+
[IsField and IsFinite, IsPosInt],
|
|
60
|
+
function(field, n)
|
|
61
|
+
local xy, i, j;
|
|
62
|
+
|
|
63
|
+
xy := List([1 .. n], x -> EmptyPlist(n));
|
|
64
|
+
for i in [1 .. n] do
|
|
65
|
+
for j in [1 .. n] do
|
|
66
|
+
xy[i][j] := Random(field);
|
|
67
|
+
od;
|
|
68
|
+
od;
|
|
69
|
+
return Matrix(field, xy);
|
|
70
|
+
end);
|
|
71
|
+
|
|
72
|
+
InstallMethod(RandomMatrixOp,
|
|
73
|
+
"for a finite field, dimension, and list of ranks",
|
|
74
|
+
[IsField and IsFinite, IsPosInt, IsList],
|
|
75
|
+
function(R, n, ranks)
|
|
76
|
+
local z, rk, mat, zv, conj, j;
|
|
77
|
+
|
|
78
|
+
if ForAny(ranks, x -> (x < 0) or (x > n)) then
|
|
79
|
+
ErrorNoReturn("the list of ranks has to consist of numbers > 0 and < n");
|
|
80
|
+
fi;
|
|
81
|
+
|
|
82
|
+
z := Zero(R);
|
|
83
|
+
# Choose a matrix of given rank
|
|
84
|
+
rk := Random(ranks);
|
|
85
|
+
if rk = 0 then
|
|
86
|
+
return ZeroMatrix(R, n, n);
|
|
87
|
+
fi;
|
|
88
|
+
mat := Unpack(Random(GL(rk, R)));
|
|
89
|
+
# Extend it to n x n
|
|
90
|
+
zv := [1 .. n - rk] * z;
|
|
91
|
+
for j in [1 .. rk] do
|
|
92
|
+
Append(mat[j], zv);
|
|
93
|
+
od;
|
|
94
|
+
zv := [1 .. n] * z;
|
|
95
|
+
for j in [1 .. n - rk] do
|
|
96
|
+
Add(mat, zv);
|
|
97
|
+
od;
|
|
98
|
+
# Swirl around
|
|
99
|
+
# Is Permuting rows/columns enough?
|
|
100
|
+
conj := Random(GL(n, R)); # PermutationMat(Random(Sym(n)), n, R);
|
|
101
|
+
return Matrix(R, mat ^ conj);
|
|
102
|
+
end);
|
|
103
|
+
|
|
104
|
+
InstallMethod(RandomMatrixOp,
|
|
105
|
+
"for a finite field, dimension, and pos int",
|
|
106
|
+
[IsField and IsFinite, IsPosInt, IsPosInt],
|
|
107
|
+
{R, n, rank} -> RandomMatrixOp(R, n, [rank]));
|
|
108
|
+
|
|
109
|
+
#############################################################################
|
|
110
|
+
# 2. Rows bases etc
|
|
111
|
+
#############################################################################
|
|
112
|
+
|
|
113
|
+
InstallMethod(NewRowBasisOverFiniteField,
|
|
114
|
+
"for IsPlistRowBasisOverFiniteFieldRep, a ring, and a list",
|
|
115
|
+
[IsPlistRowBasisOverFiniteFieldRep, IsRing, IsList],
|
|
116
|
+
function(_, basedomain, l)
|
|
117
|
+
local b;
|
|
118
|
+
b := Objectify(PlistRowBasisOverFiniteFieldType, rec(rows := l));
|
|
119
|
+
SetBaseDomain(b, basedomain);
|
|
120
|
+
return b;
|
|
121
|
+
end);
|
|
122
|
+
|
|
123
|
+
InstallMethod(Rank, "for a plist rowbasis",
|
|
124
|
+
[IsPlistRowBasisOverFiniteFieldRep],
|
|
125
|
+
v -> Length(v!.rows));
|
|
126
|
+
|
|
127
|
+
InstallMethod(\=, "for an rowbasis",
|
|
128
|
+
[IsPlistRowBasisOverFiniteFieldRep, IsPlistRowBasisOverFiniteFieldRep],
|
|
129
|
+
{x, y} -> BaseDomain(x) = BaseDomain(y) and x!.rows = y!.rows);
|
|
130
|
+
|
|
131
|
+
InstallMethod(\<, "for an rowbasis",
|
|
132
|
+
[IsPlistRowBasisOverFiniteFieldRep, IsPlistRowBasisOverFiniteFieldRep],
|
|
133
|
+
{x, y} -> Rank(x) < Rank(y) or (Rank(x) = Rank(y) and (x!.rows < y!.rows)));
|
|
134
|
+
|
|
135
|
+
InstallMethod(ViewString, "for a plist rowbasis",
|
|
136
|
+
[IsPlistRowBasisOverFiniteFieldRep],
|
|
137
|
+
function(v)
|
|
138
|
+
return STRINGIFY("<rowbasis of rank ",
|
|
139
|
+
Rank(v),
|
|
140
|
+
" over ",
|
|
141
|
+
BaseDomain(v),
|
|
142
|
+
">");
|
|
143
|
+
end);
|
|
144
|
+
|
|
145
|
+
InstallMethod(String, "for a plist rowbasis",
|
|
146
|
+
[IsPlistRowBasisOverFiniteFieldRep],
|
|
147
|
+
function(v)
|
|
148
|
+
return STRINGIFY("NewRowBasisOverFiniteField(",
|
|
149
|
+
"IsPlistRowBasisOverFiniteFieldRep, ",
|
|
150
|
+
BaseDomain(v),
|
|
151
|
+
", ",
|
|
152
|
+
v!.rows, ")");
|
|
153
|
+
end);
|
|
154
|
+
|
|
155
|
+
SEMIGROUPS.HashFunctionForPlistRowBasisOverFiniteField := function(x, data)
|
|
156
|
+
if Rank(x) = 0 then
|
|
157
|
+
return 1;
|
|
158
|
+
fi;
|
|
159
|
+
Assert(1, IsRecord(data));
|
|
160
|
+
return data.func(x!.rows, data.data);
|
|
161
|
+
end;
|
|
162
|
+
|
|
163
|
+
InstallMethod(ChooseHashFunction, "for plist row basis over finite field",
|
|
164
|
+
[IsPlistRowBasisOverFiniteFieldRep, IsInt],
|
|
165
|
+
function(x, hashlen)
|
|
166
|
+
local data;
|
|
167
|
+
if Rank(x) <> 0 then
|
|
168
|
+
data := ChooseHashFunction(x!.rows, hashlen);
|
|
169
|
+
else
|
|
170
|
+
data := hashlen;
|
|
171
|
+
fi;
|
|
172
|
+
return rec(func := SEMIGROUPS.HashFunctionForPlistRowBasisOverFiniteField,
|
|
173
|
+
data := data);
|
|
174
|
+
end);
|
|
175
|
+
|
|
176
|
+
#############################################################################
|
|
177
|
+
# 3. Attributes etc for IsMatrixObjOverFiniteField
|
|
178
|
+
#############################################################################
|
|
179
|
+
|
|
180
|
+
InstallMethod(RowSpaceBasis, "for a matrix obj over finite field",
|
|
181
|
+
[IsMatrixObj],
|
|
182
|
+
function(m)
|
|
183
|
+
if not IsMatrixObjOverFiniteField(m) then
|
|
184
|
+
TryNextMethod();
|
|
185
|
+
fi;
|
|
186
|
+
return ComputeRowSpaceAndTransformation(m)[1];
|
|
187
|
+
end);
|
|
188
|
+
|
|
189
|
+
InstallMethod(RowSpaceTransformation, "for a matrix obj over finite field",
|
|
190
|
+
[IsMatrixObj],
|
|
191
|
+
function(m)
|
|
192
|
+
if not IsMatrixObjOverFiniteField(m) then
|
|
193
|
+
TryNextMethod();
|
|
194
|
+
fi;
|
|
195
|
+
return ComputeRowSpaceAndTransformation(m)[2];
|
|
196
|
+
end);
|
|
197
|
+
|
|
198
|
+
InstallMethod(RowSpaceTransformationInv, "for a matrix obj over finite field",
|
|
199
|
+
[IsMatrixObj],
|
|
200
|
+
function(m)
|
|
201
|
+
if not IsMatrixObjOverFiniteField(m) then
|
|
202
|
+
TryNextMethod();
|
|
203
|
+
fi;
|
|
204
|
+
return ComputeRowSpaceAndTransformation(m)[3];
|
|
205
|
+
end);
|
|
206
|
+
|
|
207
|
+
# Should this go in a helper function, it also works similarly to the thing
|
|
208
|
+
# done below.
|
|
209
|
+
InstallMethod(RightInverse, "for a matrix obj over finite field",
|
|
210
|
+
[IsMatrixObj],
|
|
211
|
+
function(m)
|
|
212
|
+
local deg, u, rsp, zv, se, i;
|
|
213
|
+
|
|
214
|
+
if not IsMatrixObjOverFiniteField(m) then
|
|
215
|
+
TryNextMethod();
|
|
216
|
+
fi;
|
|
217
|
+
|
|
218
|
+
deg := NrRows(m);
|
|
219
|
+
u := One(BaseDomain(m));
|
|
220
|
+
|
|
221
|
+
rsp := Unpack(m);
|
|
222
|
+
zv := [1 .. deg] * Zero(BaseDomain(m));
|
|
223
|
+
for i in [1 .. deg] do
|
|
224
|
+
Append(rsp[i], zv);
|
|
225
|
+
rsp[i][deg + i] := u;
|
|
226
|
+
od;
|
|
227
|
+
se := SemiEchelonMat(rsp);
|
|
228
|
+
|
|
229
|
+
for i in [1 .. Length(se.vectors)] do
|
|
230
|
+
rsp[i] := ShallowCopy(se.vectors[i]);
|
|
231
|
+
od;
|
|
232
|
+
for i in [1 .. deg] do
|
|
233
|
+
if se.heads[i] = 0 then
|
|
234
|
+
rsp[i][i] := u;
|
|
235
|
+
rsp[i][deg + i] := Zero(BaseDomain(m));
|
|
236
|
+
fi;
|
|
237
|
+
od;
|
|
238
|
+
TriangulizeMat(rsp);
|
|
239
|
+
|
|
240
|
+
return Matrix(rsp{[1 .. deg]}{[deg + 1 .. 2 * deg]}, m);
|
|
241
|
+
end);
|
|
242
|
+
|
|
243
|
+
InstallMethod(LeftInverse, "for a matrix obj over finite field",
|
|
244
|
+
[IsMatrixObj],
|
|
245
|
+
function(m)
|
|
246
|
+
if not IsMatrixObjOverFiniteField(m) then
|
|
247
|
+
TryNextMethod();
|
|
248
|
+
fi;
|
|
249
|
+
return TransposedMat(RightInverse(TransposedMat(m)));
|
|
250
|
+
end);
|
|
251
|
+
|
|
252
|
+
#############################################################################
|
|
253
|
+
# 4. Helper functions
|
|
254
|
+
#############################################################################
|
|
255
|
+
|
|
256
|
+
InstallGlobalFunction(ComputeRowSpaceAndTransformation,
|
|
257
|
+
function(m)
|
|
258
|
+
local deg, bd, bas, tr, tri, sinv, rsp, zv, heads, tm, i;
|
|
259
|
+
|
|
260
|
+
Assert(1, IsMatrixObjOverFiniteField(m));
|
|
261
|
+
|
|
262
|
+
deg := NrRows(m);
|
|
263
|
+
bd := BaseDomain(m);
|
|
264
|
+
if IsZero(m) then
|
|
265
|
+
bas := [];
|
|
266
|
+
tr := IdentityMat(deg, bd);
|
|
267
|
+
tri := tr;
|
|
268
|
+
sinv := fail;
|
|
269
|
+
else
|
|
270
|
+
rsp := Unpack(m);
|
|
271
|
+
zv := [1 .. deg] * Zero(bd);
|
|
272
|
+
for i in [1 .. deg] do
|
|
273
|
+
Append(rsp[i], ShallowCopy(zv));
|
|
274
|
+
rsp[i][deg + i] := One(bd);
|
|
275
|
+
od;
|
|
276
|
+
TriangulizeMat(rsp);
|
|
277
|
+
|
|
278
|
+
heads := [];
|
|
279
|
+
bas := rsp{[1 .. deg]}{[1 .. deg]};
|
|
280
|
+
for i in [deg, deg - 1 .. 1] do
|
|
281
|
+
if IsZero(bas[i]) then
|
|
282
|
+
Remove(bas, i);
|
|
283
|
+
else
|
|
284
|
+
heads[PositionNonZero(bas[i])] := i;
|
|
285
|
+
fi;
|
|
286
|
+
od;
|
|
287
|
+
# Check whether this matrix has a semigroup inverse, i.e. a matrix t such
|
|
288
|
+
# that t * m * t = t and m * t * m = m. If it does this matrix is the
|
|
289
|
+
# transformation we computed otherwise we set fail
|
|
290
|
+
tm := TransposedMat(bas);
|
|
291
|
+
sinv := true;
|
|
292
|
+
for i in [1 .. deg] do
|
|
293
|
+
if not IsBound(heads[i]) then
|
|
294
|
+
if not IsZero(tm[i]) then
|
|
295
|
+
sinv := fail;
|
|
296
|
+
fi;
|
|
297
|
+
fi;
|
|
298
|
+
od;
|
|
299
|
+
# This is obviously totally ridiculous to do the same computation twice
|
|
300
|
+
if sinv = true then
|
|
301
|
+
sinv := RightInverse(m);
|
|
302
|
+
fi;
|
|
303
|
+
tr := rsp{[1 .. deg]}{[deg + 1 .. 2 * deg]};
|
|
304
|
+
tri := tr ^ (-1);
|
|
305
|
+
fi;
|
|
306
|
+
|
|
307
|
+
ConvertToVectorRep(bas);
|
|
308
|
+
MakeImmutable(bas);
|
|
309
|
+
bas := NewRowBasisOverFiniteField(IsPlistRowBasisOverFiniteFieldRep, bd, bas);
|
|
310
|
+
return [bas, tr, tri];
|
|
311
|
+
end);
|
|
@@ -0,0 +1,131 @@
|
|
|
1
|
+
############################################################################
|
|
2
|
+
##
|
|
3
|
+
## elements/maxplusmat.gd
|
|
4
|
+
## Copyright (C) 2015-2022 James D. Mitchell
|
|
5
|
+
##
|
|
6
|
+
## Licensing information can be found in the README file of this package.
|
|
7
|
+
##
|
|
8
|
+
#############################################################################
|
|
9
|
+
##
|
|
10
|
+
|
|
11
|
+
# This file contains declarations for max-plus, min-plus, tropical max-plus,
|
|
12
|
+
# tropical min-plus matrices, and natural number matrices.
|
|
13
|
+
|
|
14
|
+
DeclareProperty("IsTorsion", IsMatrixObj);
|
|
15
|
+
DeclareOperation("Matrix", [IsIntegers, IsTransformation]);
|
|
16
|
+
DeclareOperation("Matrix", [IsIntegers, IsTransformation, IsPosInt]);
|
|
17
|
+
|
|
18
|
+
#############################################################################
|
|
19
|
+
## 1. Max-plus matrices
|
|
20
|
+
#############################################################################
|
|
21
|
+
|
|
22
|
+
DeclareCategory("IsMaxPlusMatrix", IsMatrixOverSemiring and
|
|
23
|
+
IsPlistMatrixOverSemiringPositionalRep);
|
|
24
|
+
DeclareCategoryCollections("IsMaxPlusMatrix");
|
|
25
|
+
DeclareCategoryCollections("IsMaxPlusMatrixCollection");
|
|
26
|
+
|
|
27
|
+
BindGlobal("MaxPlusMatrixType",
|
|
28
|
+
NewType(NewFamily("MaxPlusMatrixFamily",
|
|
29
|
+
IsMaxPlusMatrix,
|
|
30
|
+
CanEasilySortElements,
|
|
31
|
+
CanEasilySortElements),
|
|
32
|
+
IsMaxPlusMatrix));
|
|
33
|
+
|
|
34
|
+
DeclareOperation("SpectralRadius", [IsMaxPlusMatrix]);
|
|
35
|
+
DeclareOperation("UnweightedPrecedenceDigraph", [IsMaxPlusMatrix]);
|
|
36
|
+
DeclareOperation("RadialEigenvector", [IsMaxPlusMatrix]);
|
|
37
|
+
|
|
38
|
+
#############################################################################
|
|
39
|
+
## 2. Min-plus matrices
|
|
40
|
+
#############################################################################
|
|
41
|
+
|
|
42
|
+
DeclareCategory("IsMinPlusMatrix",
|
|
43
|
+
IsMatrixOverSemiring
|
|
44
|
+
and IsPlistMatrixOverSemiringPositionalRep);
|
|
45
|
+
DeclareCategoryCollections("IsMinPlusMatrix");
|
|
46
|
+
DeclareCategoryCollections("IsMinPlusMatrixCollection");
|
|
47
|
+
|
|
48
|
+
BindGlobal("MinPlusMatrixType",
|
|
49
|
+
NewType(NewFamily("MinPlusMatrixFamily",
|
|
50
|
+
IsMinPlusMatrix,
|
|
51
|
+
CanEasilySortElements,
|
|
52
|
+
CanEasilySortElements),
|
|
53
|
+
IsMinPlusMatrix));
|
|
54
|
+
|
|
55
|
+
#############################################################################
|
|
56
|
+
## 3. Tropical matrices
|
|
57
|
+
#############################################################################
|
|
58
|
+
|
|
59
|
+
DeclareCategory("IsTropicalMatrix",
|
|
60
|
+
IsMatrixOverSemiring
|
|
61
|
+
and IsPlistMatrixOverSemiringPositionalRep);
|
|
62
|
+
DeclareCategoryCollections("IsTropicalMatrix");
|
|
63
|
+
|
|
64
|
+
DeclareAttribute("ThresholdTropicalMatrix", IsTropicalMatrix);
|
|
65
|
+
|
|
66
|
+
#############################################################################
|
|
67
|
+
## 4. Tropical max-plus matrices
|
|
68
|
+
#############################################################################
|
|
69
|
+
|
|
70
|
+
DeclareCategory("IsTropicalMaxPlusMatrix", IsTropicalMatrix);
|
|
71
|
+
DeclareCategoryCollections("IsTropicalMaxPlusMatrix");
|
|
72
|
+
DeclareCategoryCollections("IsTropicalMaxPlusMatrixCollection");
|
|
73
|
+
|
|
74
|
+
BindGlobal("TropicalMaxPlusMatrixType",
|
|
75
|
+
NewType(NewFamily("TropicalMaxPlusMatrixFamily",
|
|
76
|
+
IsTropicalMaxPlusMatrix,
|
|
77
|
+
CanEasilySortElements,
|
|
78
|
+
CanEasilySortElements),
|
|
79
|
+
IsTropicalMaxPlusMatrix));
|
|
80
|
+
|
|
81
|
+
#############################################################################
|
|
82
|
+
## 5. Tropical min-plus matrices
|
|
83
|
+
#############################################################################
|
|
84
|
+
|
|
85
|
+
DeclareCategory("IsTropicalMinPlusMatrix", IsTropicalMatrix);
|
|
86
|
+
DeclareCategoryCollections("IsTropicalMinPlusMatrix");
|
|
87
|
+
DeclareCategoryCollections("IsTropicalMinPlusMatrixCollection");
|
|
88
|
+
|
|
89
|
+
BindGlobal("TropicalMinPlusMatrixType",
|
|
90
|
+
NewType(NewFamily("TropicalMinPlusMatrixFamily",
|
|
91
|
+
IsTropicalMinPlusMatrix,
|
|
92
|
+
CanEasilySortElements,
|
|
93
|
+
CanEasilySortElements),
|
|
94
|
+
IsTropicalMinPlusMatrix));
|
|
95
|
+
|
|
96
|
+
#############################################################################
|
|
97
|
+
## 6. Projective max-plus matrices
|
|
98
|
+
#############################################################################
|
|
99
|
+
|
|
100
|
+
DeclareCategory("IsProjectiveMaxPlusMatrix",
|
|
101
|
+
IsMatrixOverSemiring
|
|
102
|
+
and IsPlistMatrixOverSemiringPositionalRep);
|
|
103
|
+
DeclareCategoryCollections("IsProjectiveMaxPlusMatrix");
|
|
104
|
+
DeclareCategoryCollections("IsProjectiveMaxPlusMatrixCollection");
|
|
105
|
+
|
|
106
|
+
BindGlobal("ProjectiveMaxPlusMatrixType",
|
|
107
|
+
NewType(NewFamily("ProjectiveMaxPlusMatrixFamily",
|
|
108
|
+
IsProjectiveMaxPlusMatrix,
|
|
109
|
+
CanEasilySortElements,
|
|
110
|
+
CanEasilySortElements),
|
|
111
|
+
IsProjectiveMaxPlusMatrix));
|
|
112
|
+
|
|
113
|
+
#############################################################################
|
|
114
|
+
## 7. NTP (Natural Threshold Period) matrices
|
|
115
|
+
#############################################################################
|
|
116
|
+
|
|
117
|
+
DeclareCategory("IsNTPMatrix",
|
|
118
|
+
IsMatrixOverSemiring
|
|
119
|
+
and IsPlistMatrixOverSemiringPositionalRep);
|
|
120
|
+
DeclareCategoryCollections("IsNTPMatrix");
|
|
121
|
+
DeclareCategoryCollections("IsNTPMatrixCollection");
|
|
122
|
+
|
|
123
|
+
BindGlobal("NTPMatrixType",
|
|
124
|
+
NewType(NewFamily("NTPMatrixFamily",
|
|
125
|
+
IsNTPMatrix,
|
|
126
|
+
CanEasilySortElements,
|
|
127
|
+
CanEasilySortElements),
|
|
128
|
+
IsNTPMatrix));
|
|
129
|
+
|
|
130
|
+
DeclareAttribute("ThresholdNTPMatrix", IsNTPMatrix);
|
|
131
|
+
DeclareAttribute("PeriodNTPMatrix", IsNTPMatrix);
|