Eine aufbereitete Darstellung der Quelle

 
     
 
 
Anforderungen  |   Konzepte  |   Entwurf  |   Entwicklung  |   Qualitätssicherung  |   Lebenszyklus  |   Steuerung
 
 
 
 

Benutzer

Quelle  rack.gi   Sprache: unbekannt

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

### racks

InstallMethod(Rack, "for a matrix", [ IsMatrix ], 
function(matrix)
  local fam, obj;
  if not IS_RACK(matrix) then
    Error("this is not a rack");
  fi;

  fam := NewFamily("RackElmFamily", IsRackElm, IsMultiplicativeElement);
  fam!.DefaultType := NewType(fam, IsRackElmRep);

  obj := Objectify(NewType(CollectionsFamily(fam), IsRack and IsAttributeStoringRep), rec());
  fam!.Rack := obj;

  SetSize(obj, Size(matrix)); 
  SetMatrixOfRack(obj, matrix);
  SetPermutations(obj, List([1..Size(obj)], x->PermList(matrix[x])));

  return obj;
end);

InstallOtherMethod(Matrix, [ IsRack and HasMatrixOfRack ], MatrixOfRack);

InstallMethod(ViewObj,
  "for a rack",
  [ IsRack ],
  function(obj)
  Print("<A rack of size ", Size(obj), ">");
end);

InstallMethod(PrintObj,
  "for a rack", 
  [ IsRack ],
  function(obj)
  Print( "Rack( ", MatrixOfRack(obj), " )");
end);

InstallMethod(Enumerator,
    "for a rack", 
    [ IsRack ],
    AsList);

InstallMethod(AsList, 
    "for a rack",
    [ IsRack ],
    function( obj )
  return List([1..Size(obj)], x->RackElmConstructor(obj, x));
end);

InstallMethod( \=,
    "for two elements of a rack",
    IsIdenticalObj, [ IsRackElm, IsRackElm ],
    function( x, y )
      return x![1] = y![1];
end);

InstallMethod(ViewObj, "for a rack element", [ IsRackElm ],
function(x)
  Print("<", x![1], ">");
end);

InstallMethod(RackElmConstructor, "for a rack and an integer", [ IsRack, IsInt ], 
function( obj, x )
  return Objectify(ElementsFamily(FamilyObj(obj))!.DefaultType, [ x ]);
end);

InstallMethod( \*,
    "for two elements of a rack",
    IsIdenticalObj, [ IsRackElm, IsRackElm ],
    function( x, y )
    local fam;
    fam := FamilyObj(x);
    return RackElmConstructor(fam!.Rack, MatrixOfRack(fam!.Rack)[x![1],y![1]]);
end);

InstallMethod(Rack2YB, "for a rack", [ IsRack ], 
function(obj)
  return YB(MatrixOfRack(obj), List([1..Size(obj)], x->[1..Size(obj)]));
end);


[Dauer der Verarbeitung: 0.14 Sekunden, vorverarbeitet 2026-06-07]

                                                                                                                                                                                                                                                                                                                                                                                                     


Neuigkeiten

     Aktuelles
     Motto des Tages

Software

     Quellcodebibliothek
     Eigene Quellcodes
     Fremde Quellcodes
     Suchen

Aktivitäten

     Artikel über Sicherheit
     Anleitung zur Aktivierung von SSL

Muße

     Gedichte
     Musik
     Bilder

Jenseits des Üblichen ....
    

Besucherstatistik

Besucherstatistik