Quellcodebibliothek Statistik Leitseite products/Sources/formale Sprachen/GAP/pkg/semigroups/tst/standard/attributes/   (GAP Algebra Version 4.15.1©)  Datei vom 29.7.2025 mit Größe 14 kB image not shown  

Quelle  acting.tst   Sprache: unbekannt

 
Spracherkennung für: .tst vermutete Sprache: Unknown {[0] [0] [0]} [Methode: Schwerpunktbildung, einfache Gewichte, sechs Dimensionen]

#############################################################################
##
#W  standard/attributes/acting.tst
#Y  Copyright (C) 2015-2022                             James D. Mitchell
##
##  Licensing information can be found in the README file of this package.
##
#############################################################################
##

#@local D, I, L, R, S, Y, acting, an, foo, inj, inv, map, x, y, z
gap> START_TEST("Semigroups package: standard/attributes/acting.tst");
gap> LoadPackage("semigroups", false);;

#
gap> SEMIGROUPS.StartTest();
gap> SEMIGROUPS.DefaultOptionsRec.acting := true;;

# IsMultiplicativeZero
gap> S := InverseSemigroup([PartialPerm([125], [215]),
> PartialPerm([1245], [4213])]);;
gap> IsMultiplicativeZero(S, PartialPerm([]));
true

# IsGreensDGreaterThanFunc
gap> S := Semigroup([PartialPerm([123], [451]),
>                    PartialPerm([124], [154])]);;
gap> x := PartialPerm([13], [41]);;
gap> y := PartialPerm([14], [14]);;
gap> foo := IsGreensDGreaterThanFunc(S);;
gap> foo(x, x);
false
gap> foo(x, y);
false
gap> foo(y, x);
true
gap> S := InverseSemigroup(S);;
gap> foo := IsGreensDGreaterThanFunc(S);
function( x, y ) ... end
gap> foo(y, x);
false
gap> foo(x, y);
false
gap> z := RepresentativeOfMinimalIdeal(S);
<empty partial perm>
gap> foo(x, x);
false
gap> foo(x, z);
true
gap> foo(z, x);
false
gap> foo(z, y);
false
gap> foo(y, z);
true

# MaximalDClasses for non-regular semigroup
gap> S := Monoid([Bipartition([[1, -2], [2, -1], [3, -3]]),
> Bipartition([[1], [2], [3], [-1], [-2, -3]])]);;
gap> MaximalDClasses(S);
[ <Green's D-class: <block bijection: [ 1, -1 ], [ 2, -2 ], [ 3, -3 ]>> ]

# MaximalDClasses for regular semigroup
gap> S := FullTransformationMonoid(3);
<full transformation monoid of degree 3>
gap> MaximalDClasses(S);
[ <Green's D-class: IdentityTransformation> ]

# StructureDescriptionMaximalSubgroups
gap> S := Semigroup([Transformation([13413]),
> Transformation([55113])]);;
gap> StructureDescriptionSchutzenbergerGroups(S);
[ "1", "C2", "C3" ]

# IdempotentGeneratedSubsemigroup, for a semigroup
gap> S := Semigroup([PartialPerm([123], [253]),
> PartialPerm([1234], [2415])]);;
gap> IdempotentGeneratedSubsemigroup(S);
<inverse partial perm monoid of rank 1 with 2 generators>

# IdempotentGeneratedSubsemigroup, for an inverse semigroup
gap> S := InverseSemigroup([PartialPerm([12], [43]),
> PartialPerm([125], [124])]);;
gap> IdempotentGeneratedSubsemigroup(S);
<inverse partial perm semigroup of rank 5 with 5 generators>

# InjectionPrincipalFactor 1/6
gap> D := GreensDClassOfElement(
>  Monoid([Bipartition([[12, -2], [3, -3], [-1]]),
>    Bipartition([[12], [3], [-1, -3], [-2]]),
>    Bipartition([[1, -1, -2], [23], [-3]])]),
> Bipartition([[12], [3], [-1, -3], [-2]]));;
gap> map := InjectionPrincipalFactor(D);
MappingByFunction( <Green's D-class: <bipartition: [ 12 ], [ 3 ], 
  [ -1, -3 ], [ -2 ]>>, <Rees matrix semigroup 3x4 over Group(())>
 , function( x ) ... end, function( x ) ... end )
gap> inv := InverseGeneralMapping(map);;
gap> ForAll(D, x -> (x ^ map) ^ inv = x);
true
gap> Bipartition([[12, -2], [3, -3], [-1]]) ^ map;
fail
gap> Star(Bipartition([[12, -2], [3, -3], [-1]])) ^ map;
fail

# InjectionPrincipalFactor 2/6
gap> R := PrincipalFactor(DClasses(FullTransformationMonoid(5))[2]);
<Rees 0-matrix semigroup 10x5 over Group([ (1,2,3,4), (1,2) ])>
gap> x := RMSElement(R, 9, (1324), 2);;
gap> y := RMSElement(R, 6, (1342), 5);;
gap> S := Semigroup(x, y);
<subsemigroup of 10x5 Rees 0-matrix semigroup with 2 generators>
gap> D := DClass(S, RMSElement(R, 6, (1342), 5));;
gap> InjectionPrincipalFactor(D);
Error, the argument (a Green's D-class) is not regular

# InjectionPrincipalFactor 3/6
gap> R := PrincipalFactor(DClasses(FullTransformationMonoid(5))[2]);
<Rees 0-matrix semigroup 10x5 over Group([ (1,2,3,4), (1,2) ])>
gap> x := RMSElement(R, 1, (1234), 1);;
gap> y := RMSElement(R, 6, (1342), 5);;
gap> S := Semigroup(x, y);;
gap> D := DClass(S, x);;
gap> inj := InjectionPrincipalFactor(D);;
gap> Source(inj) = D;
true
gap> Range(inj);
<Rees matrix semigroup 1x1 over Group([ (1,2,3,4) ])>

# InjectionPrincipalFactor 4/6
gap> D := GreensDClassOfElement(
> Semigroup([
>   Transformation([13413]),
>   Transformation([55113])]),
> Transformation([55113]));;
gap> inj := InjectionPrincipalFactor(D);;
gap> Source(inj) = D;
true
gap> Range(inj);
<Rees matrix semigroup 1x1 over Group([ (1,5,3) ])>
gap> Transformation([51113]) ^ inj;
fail

# InjectionPrincipalFactor 5/6
gap> D := GreensDClassOfElement(
> Semigroup([
>   Transformation([13413]),
>   Transformation([55113])]),
> Transformation([14114]));;
gap> map := InverseGeneralMapping(InjectionPrincipalFactor(D));;
gap> MultiplicativeZero(Source(map)) ^ map;
fail

# InjectionPrincipalFactor 6/6
gap> S := ReesZeroMatrixSemigroup(Group(()), [[(), 0], [0, ()]]);;
gap> S := Semigroup(RMSElement(S, 2, (), 2),
>                   RMSElement(S, 1, (), 2));;
gap> MaximalSubsemigroups(S);;

# InversesOfSemigroupElement, none, 1/2
# This test gives the wrong result in Semigroups 2.7.1!!!
gap> S := Semigroup([Bipartition([[12, -2], [3, -3], [-1]]),
> Bipartition([[1, -1, -2], [23], [-3]])]);;
gap> x := Bipartition([[123], [-1, -2], [-3]]);;
gap> Y := InversesOfSemigroupElement(S, x);
[ <bipartition: [ 123 ], [ -1, -2 ], [ -3 ]>, 
  <bipartition: [ 1 ], [ 23 ], [ -1, -2 ], [ -3 ]>, 
  <bipartition: [ 123 ], [ -1 ], [ -2 ], [ -3 ]>, 
  <bipartition: [ 1 ], [ 23 ], [ -1 ], [ -2 ], [ -3 ]> ]
gap> ForAll(Y, y -> y in S);
true
gap> ForAll(Y, y -> x * y * x = x and y * x * y = y);
true
gap> Set(Y) = Set(Filtered(AsList(S), y -> x * y * x = x and y * x * y = y));
true

# InversesOfSemigroupElement, fail, 2/2
gap> S := Semigroup([PartialPerm([1234], [1253]),
> PartialPerm([1234], [2415]),
> PartialPerm([1245], [2315]),
> PartialPerm([1235], [4135]),
> PartialPerm([1235], [4351])]);;
gap> x := PartialPerm([1235], [5264]);;
gap> InversesOfSemigroupElement(S, x);
Error, the 2nd argument (a mult. element) must belong to the 1st argument (a s\
emigroup)

# InversesOfSemigroupElementNC, closed rho orb
gap> S := Semigroup([
> Transformation([2213143415192217222211121822,
>                 16162122202210]),
> Transformation([222222222222222222222222222222,
>                 2222222222222]),
> Transformation([11569999955699778988,
>                 996])]);;
gap> Size(S);;
gap> x := Transformation([11999999999999999,
>                         999999]);;
gap> InversesOfSemigroupElementNC(S, x);
[ Transformation( [ 2222222222222222222222222222,
      222222222222222 ] ), 
  Transformation( [ 2222222222222222222222222222,
      2222222222222222 ] ), 
  Transformation( [ 1199999999999999999,
      9991 ] ), Transformation( [ 1199999999999,
     9999999999 ] ) ]

# InversesOfSemigroupElementNC, non-closed rho orb
gap> S := Semigroup([
> Transformation([2213143415192217222211121822,
>                 16162122202210]),
> Transformation([222222222222222222222222222222,
>                 2222222222222]),
>  Transformation([11569999955699778988,
>                  996])]);;
gap> x := Transformation([11999999999999999,
>                         999999]);;
gap> InversesOfSemigroupElementNC(S, x);
[ Transformation( [ 2222222222222222222222222222,
      222222222222222 ] ), 
  Transformation( [ 2222222222222222222222222222,
      2222222222222222 ] ), 
  Transformation( [ 1199999999999999999,
      9991 ] ), Transformation( [ 1199999999999,
     9999999999 ] ) ]

# InversesOfSemigroupElementNC non-regular element
gap> S := Semigroup(Transformation([2434]),
>                   Transformation([33233]),
>                   Transformation([55544]),
>                   Transformation([51411]),
>                   Transformation([53345]));;
gap> IsRegularSemigroup(S);
false
gap> x := Transformation([51411]);
Transformation( [ 51411 ] )
gap> IsRegularSemigroupElement(S, x);
false
gap> InversesOfSemigroupElementNC(S, x);
[  ]

# MultiplicativeNeutralElement, 1/4
gap> S := Semigroup(Transformation([231]));
<commutative transformation semigroup of degree 3 with 1 generator>
gap> MultiplicativeNeutralElement(S);
IdentityTransformation

# MultiplicativeNeutralElement, 2/4
gap> S := Semigroup(Transformation([121]), Transformation([223]));;
gap> MultiplicativeNeutralElement(S);
fail

# MultiplicativeNeutralElement, 3/4
gap> S := Semigroup(Transformation([1462537899]),
> Transformation([6327518899]));;
gap> MultiplicativeNeutralElement(S);
Transformation( [ 1234567899 ] )

# MultiplicativeNeutralElement, 4/4
gap> S := Semigroup(Transformation([113]), Transformation([223]));
<transformation semigroup of degree 2 with 2 generators>
gap> MultiplicativeNeutralElement(S);
fail

# MultiplicativeNeutralElement, 5
gap> S := SingularFactorisableDualSymmetricInverseMonoid(3);
<inverse bipartition semigroup ideal of degree 3 with 1 generator>
gap> IsMonoidAsSemigroup(S);
false

# MultiplicativeNeutralElement, 6
gap> S := Semigroup([Transformation([323]),
>                    Transformation([34255])]);
<transformation semigroup of degree 5 with 2 generators>
gap> MultiplicativeNeutralElement(S);
fail
gap> S := SemigroupIdeal(S, S.1);
<non-regular transformation semigroup ideal of degree 5 with 1 generator>
gap> MultiplicativeNeutralElement(S);
fail

# MultiplicativeNeutralElement, 7
gap> S := FullTransformationMonoid(3);
<full transformation monoid of degree 3>
gap> S := SemigroupIdeal(S, IdentityTransformation);
<regular transformation semigroup ideal of degree 3 with 1 generator>
gap> MultiplicativeNeutralElement(S);
IdentityTransformation

# MultiplicativeNeutralElement, 8
gap> S := Semigroup(
>  Transformation([23144]),
>  Transformation([21344]),
>  Transformation([12144]));
<transformation semigroup of degree 5 with 3 generators>
gap> MultiplicativeNeutralElement(S);
Transformation( [ 12344 ] )
gap> S := SemigroupIdeal(S, S.1);
<regular transformation semigroup ideal of degree 5 with 1 generator>
gap> MultiplicativeNeutralElement(S);
Transformation( [ 12344 ] )

# RepresentativeOfMinimalIdeal, 1/3
gap> S := Semigroup(Transformation([121]), Transformation([223]));;
gap> RepresentativeOfMinimalIdeal(S);
Transformation( [ 222 ] )

# RepresentativeOfMinimalIdeal, 2/3
gap> S := Semigroup(
> Bipartition([[1, -2], [2, -1], [3, -3], [4, -4], [5, -5]]),
> Bipartition([[1, -1], [2, -2], [3, -3], [4, -5], [5, -4]]),
> Bipartition([[12, -1], [3, -3], [4, -4], [5, -2], [-5]]),
> Bipartition([[1, -1], [24, -2], [3, -3], [5, -4], [-5]]),
> Bipartition([[12, -3], [3, -1], [4, -4], [5, -2], [-5]]),
> Bipartition([[1, -1], [2, -2], [3, -3], [45, -4], [-5]]),
> Bipartition([[1, -1], [2, -2], [35, -3], [4, -4], [-5]]),
> Bipartition([[12, -3], [3, -1], [4, -4], [5, -5], [-2]]));;
gap> RepresentativeOfMinimalIdeal(S);
<bipartition: [ 1245, -1 ], [ 3, -3 ], [ -2 ], [ -4 ], [ -5 ]>

# RepresentativeOfMinimalIdeal, 3/3
gap> S := Semigroup(
> Bipartition([[1, -2], [2, -1], [3, -3], [4, -4], [5, -5]]),
> Bipartition([[1, -1], [2, -2], [3, -3], [4, -5], [5, -4]]),
> Bipartition([[12, -1], [3, -3], [4, -4], [5, -2], [-5]]),
> Bipartition([[1, -1], [24, -2], [3, -3], [5, -4], [-5]]),
> Bipartition([[12, -3], [3, -1], [4, -4], [5, -2], [-5]]),
> Bipartition([[1, -1], [2, -2], [3, -3], [45, -4], [-5]]),
> Bipartition([[1, -1], [2, -2], [35, -3], [4, -4], [-5]]),
> Bipartition([[12, -3], [3, -1], [4, -4], [5, -5], [-2]]));;
gap> I := SemigroupIdeal(S, RepresentativeOfMinimalIdeal(S));;
gap> RepresentativeOfMinimalIdeal(I);
<bipartition: [ 1245, -1 ], [ 3, -3 ], [ -2 ], [ -4 ], [ -5 ]>

# Left/RightIdentity
gap> S := Semigroup(Transformation([2434]),
>                   Transformation([33233]),
>                   Transformation([55544]),
>                   Transformation([51411]),
>                   Transformation([53345]));;
gap> ForAll(S, x -> RightIdentity(S, x) = fail or x * RightIdentity(S, x) = x);
true
gap> ForAll(S, x -> RightIdentity(S, x) = fail or RightIdentity(S, x) in S);
true
gap> ForAll(S, x -> LeftIdentity(S, x) = fail or LeftIdentity(S, x) * x = x);
true
gap> ForAll(S, x -> LeftIdentity(S, x) = fail or LeftIdentity(S, x) in S);
true
gap> L := Filtered(S, x -> LeftIdentity(S, x) = fail);
[ Transformation( [ 2434 ] ), Transformation( [ 55544 ] ), 
  Transformation( [ 51411 ] ), Transformation( [ 52422 ] ), 
  Transformation( [ 54444 ] ), Transformation( [ 53433 ] ) ]
gap> Length(L) = 6;
true
gap> ForAll(L, y -> ForAll(S, x -> x * y <> y));
true
gap> ForAll(L, y -> ForAll(S, x -> x * y <> y));
true
gap> R := Filtered(S, x -> RightIdentity(S, x) = fail);
[ Transformation( [ 2434 ] ), Transformation( [ 51411 ] ), 
  Transformation( [ 52422 ] ) ]
gap> Length(R) = 3;
true
gap> ForAll(R, y -> ForAll(S, x -> y * x <> y));
true
gap> RightIdentity(S, Transformation([76810559278]));
Error, the 2nd argument (a mult. elt.) does not belong to the 1st argument (a \
semigroup)
gap> LeftIdentity(S, Transformation([76810559278]));
Error, the 2nd argument (a mult. elt.) does not belong to the 1st argument (a \
semigroup)
gap> S := Semigroup(Transformation([1233]), Transformation([2311]));
<transformation semigroup of degree 4 with 2 generators>
gap> IsMonoidAsSemigroup(S);
true
gap> RightIdentity(S, Transformation([3122])) = MultiplicativeNeutralElement(S);
true
gap> LeftIdentity(S, Transformation([3122])) = MultiplicativeNeutralElement(S);
true
gap> S := Monoid(Transformation([1233]), Transformation([2311]));
<transformation monoid of degree 4 with 2 generators>
gap> RightIdentity(S, Transformation([3122])) = One(S);
true
gap> LeftIdentity(S, Transformation([3122])) = One(S);
true

#
gap> SEMIGROUPS.StopTest();
gap> STOP_TEST("Semigroups package: standard/attributes/acting.tst");

[Dauer der Verarbeitung: 0.18 Sekunden, vorverarbeitet 2026-06-17]