diff --git a/lib/obsolete.gd b/lib/obsolete.gd index 6492de98f7..c1c7644d12 100644 --- a/lib/obsolete.gd +++ b/lib/obsolete.gd @@ -137,7 +137,7 @@ end ); ## Moved to obsoletes in May 2003. ## ## not used in any redistributed package (01/2016) -DeclareGlobalFunction( "DiagonalizeIntMatNormDriven" ); +#DeclareGlobalFunction( "DiagonalizeIntMatNormDriven" ); ############################################################################# @@ -167,7 +167,7 @@ BindGlobal( "DeclareAutoPackage", Ignore ); BindGlobal( "DeclarePackageAutoDocumentation", Ignore ); # 03/2018: still used in itc -BindGlobal( "DeclarePackageDocumentation", Ignore ); +#BindGlobal( "DeclarePackageDocumentation", Ignore ); # 03/2018: not used in any redistributed package DeclareObsoleteSynonym( "ReadPkg", "ReadPackage" ); @@ -193,21 +193,21 @@ DeclareObsoleteSynonym( "RequirePackage", "LoadPackage" ); ## Up to GAP 4.3, ## these global variables were used instead of the record `GAPInfo'. ## -BindGlobal( "KERNEL_VERSION", GAPInfo.KernelVersion ); +#BindGlobal( "KERNEL_VERSION", GAPInfo.KernelVersion ); BindGlobal( "VERSION", GAPInfo.Version ); BindGlobal( "GAP_ARCHITECTURE", GAPInfo.Architecture ); -BindGlobal( "GAP_ROOT_PATHS", GAPInfo.RootPaths ); +#BindGlobal( "GAP_ROOT_PATHS", GAPInfo.RootPaths ); BindGlobal( "DEBUG_LOADING", GAPInfo.CommandLineOptions.D ); BindGlobal( "BANNER", not GAPInfo.CommandLineOptions.b ); BindGlobal( "QUIET", GAPInfo.CommandLineOptions.q ); -BindGlobal( "LOADED_PACKAGES", GAPInfo.PackagesLoaded ); +#BindGlobal( "LOADED_PACKAGES", GAPInfo.PackagesLoaded ); ############################################################################# ## #V PACKAGES_VERSIONS - not used in any redistributed package (11/2017) #V Revision - still used by HAPcryst, pargap, polymaking, rds, #V singular, tomlib (03/2018) -BindGlobal( "PACKAGES_VERSIONS", rec() ); +#BindGlobal( "PACKAGES_VERSIONS", rec() ); BindGlobal( "Revision", rec() ); ############################################################################# @@ -285,7 +285,7 @@ DeclareObsoleteSynonym( "FormattedString", "String" ); #F IsTuple( ... ) - not used in any redistributed package (11/2017) #F Tuple( ... ) - still used by cubefree, groupoids, modisom, sonata (03/2018) ## -DeclareObsoleteSynonym( "IsTuple", "IsDirectProductElement" ); +#DeclareObsoleteSynonym( "IsTuple", "IsDirectProductElement" ); DeclareObsoleteSynonym( "Tuple", "DirectProductElement" ); ## from GAPs "classical" random number generator: @@ -339,21 +339,21 @@ DeclareObsoleteSynonym( "Tuple", "DirectProductElement" ); ## (We also keep the global variables R_N and R_X within the ## 'GlobalRandomSource' because they were documented.) ## -BindGlobal( "StateRandom", function() - return State(GlobalRandomSource); -end); - -BindGlobal( "RestoreStateRandom", function(seed) - Reset(GlobalRandomSource, seed); -end); +# BindGlobal( "StateRandom", function() +# return State(GlobalRandomSource); +# end); +# +# BindGlobal( "RestoreStateRandom", function(seed) +# Reset(GlobalRandomSource, seed); +# end); # older documentation referred to `StatusRandom'. -DeclareObsoleteSynonym( "StatusRandom", "StateRandom" ); +#DeclareObsoleteSynonym( "StatusRandom", "StateRandom" ); # synonym formerly declared in factgrp.gd. # Moved to obsoletes in October 2011 # not used in any redistributed package (11/2017) -DeclareObsoleteSynonym( "FactorCosetOperation", "FactorCosetAction" ); +#DeclareObsoleteSynonym( "FactorCosetOperation", "FactorCosetAction" ); # synonym retained for backwards compatibility with GAP 4.4. # Moved to obsoletes in April 2012. Still used by hap (03/2018) @@ -382,7 +382,7 @@ DeclareObsoleteSynonym( "Complementclasses", "ComplementClassesRepresentatives" ## ## ## not used in any redistributed package (11/2017) -DeclareOperation( "ShrinkCoeffs", [ IsMutable and IsList ] ); +#DeclareOperation( "ShrinkCoeffs", [ IsMutable and IsList ] ); ############################################################################# @@ -392,12 +392,12 @@ DeclareOperation( "ShrinkCoeffs", [ IsMutable and IsList ] ); ## was supported until GAP 4.4, obsolescent in GAP 4.5. ## ## not used in any redistributed package (01/2016) -BindGlobal( "ExcludeFromAutoload", function( arg ) - Info( InfoWarning, 1, - "the function `ExcludeFromAutoload' is not supported anymore,\n", - "#I use the component `ExcludeFromAutoload' in `gap.ini'\n", - "#I instead" ); - end ); +# BindGlobal( "ExcludeFromAutoload", function( arg ) +# Info( InfoWarning, 1, +# "the function `ExcludeFromAutoload' is not supported anymore,\n", +# "#I use the component `ExcludeFromAutoload' in `gap.ini'\n", +# "#I instead" ); +# end ); ############################################################################# @@ -465,7 +465,7 @@ DeclareOperation( "LaTeXObj", [ IS_OBJECT ] ); ## instead of `ConnectGroupAndCharacterTable'. ## ## not used in any redistributed package (01/2016) -DeclareGlobalFunction( "ConnectGroupAndCharacterTable" ); +#DeclareGlobalFunction( "ConnectGroupAndCharacterTable" ); ############################################################################# @@ -535,7 +535,7 @@ DeclareObsoleteSynonym( "MutableNullMat", "NullMat" ); ## <#/GAPDoc> ## ## not used in any redistributed packages (11/2017) -DeclareSynonymAttr( "IsSemilatticeAsSemigroup", IsSemilattice ); +#DeclareSynonymAttr( "IsSemilatticeAsSemigroup", IsSemilattice ); ############################################################################# ## @@ -543,9 +543,9 @@ DeclareSynonymAttr( "IsSemilatticeAsSemigroup", IsSemilattice ); ## ## NO LONGER SUPPORTED IN GAP >= 4.5 ## -BindGlobal( "CreateCompletionFiles", function() - Print("CreateCompletionFiles: Completion files are no longer supported by GAP.\n"); -end); +# BindGlobal( "CreateCompletionFiles", function() +# Print("CreateCompletionFiles: Completion files are no longer supported by GAP.\n"); +# end); ############################################################################# @@ -557,7 +557,7 @@ end); ## ## Deprecated in GAP >= 4.8 ## Not used in any redistributed packages (11/2017) -DeclareOperation( "PositionFirstComponent", [IsList,IsObject] ); +#DeclareOperation( "PositionFirstComponent", [IsList,IsObject] ); ############################################################################# ## diff --git a/lib/obsolete.gi b/lib/obsolete.gi index dd969594fd..a2235cb2e7 100644 --- a/lib/obsolete.gi +++ b/lib/obsolete.gi @@ -17,292 +17,292 @@ ## #T Should this test for mutability? SL ## -InstallGlobalFunction( DiagonalizeIntMatNormDriven, function ( mat ) - local nrrows, # number of rows (length of ) - nrcols, # number of columns (length of [1]) - rownorms, # norms of rows - colnorms, # norms of columns - d, # diagonal position - pivk, pivl, # position of a pivot - norm, # product of row and column norms of the pivot - clear, # are the row and column cleared - row, # one row - col, # one column - ent, # one entry of matrix - quo, # quotient - h, # gap width in shell sort - k, l, # loop variables - max, omax; # maximal entry and overall maximal entry - - # give some information - Info( InfoMatrix, 1, "DiagonalizeMat called" ); - omax := 0; - - # get the number of rows and columns - nrrows := Length( mat ); - if nrrows <> 0 then - nrcols := Length( mat[1] ); - else - nrcols := 0; - fi; - rownorms := []; - colnorms := []; - - # loop over the diagonal positions - d := 1; - Info( InfoMatrix, 2, " divisors:" ); - - while d <= nrrows and d <= nrcols do - - # find the maximal entry - Info( InfoMatrix, 3, " d=", d ); - if 3 <= InfoLevel( InfoMatrix ) then - max := 0; - for k in [ d .. nrrows ] do - for l in [ d .. nrcols ] do - ent := mat[k][l]; - if 0 < ent and max < ent then - max := ent; - elif ent < 0 and max < -ent then - max := -ent; - fi; - od; - od; - Info( InfoMatrix, 3, " max=", max ); - if omax < max then omax := max; fi; - fi; - - # compute the Euclidean norms of the rows and columns - for k in [ d .. nrrows ] do - row := mat[k]; - rownorms[k] := row * row; - od; - for l in [ d .. nrcols ] do - col := mat{[d..nrrows]}[l]; - colnorms[l] := col * col; - od; - Info( InfoMatrix, 3, " n" ); - - # push rows containing only zeroes down and forget about them - for k in [ nrrows, nrrows-1 .. d ] do - if k < nrrows and rownorms[k] = 0 then - row := mat[k]; - mat[k] := mat[nrrows]; - mat[nrrows] := row; - norm := rownorms[k]; - rownorms[k] := rownorms[nrrows]; - rownorms[nrrows] := norm; - fi; - if rownorms[nrrows] = 0 then - nrrows := nrrows - 1; - fi; - od; - - # quit if there are no more nonzero entries - if nrrows < d then - #N 1996/04/30 mschoene should 'break' - Info( InfoMatrix, 3, " overall maximal entry ", omax ); - Info( InfoMatrix, 1, "DiagonalizeMat returns" ); - return; - fi; - - # push columns containing only zeroes right and forget about them - for l in [ nrcols, nrcols-1 .. d ] do - if l < nrcols and colnorms[l] = 0 then - col := mat{[d..nrrows]}[l]; - mat{[d..nrrows]}[l] := mat{[d..nrrows]}[nrcols]; - mat{[d..nrrows]}[nrcols] := col; - norm := colnorms[l]; - colnorms[l] := colnorms[nrcols]; - colnorms[nrcols] := norm; - fi; - if colnorms[nrcols] = 0 then - nrcols := nrcols - 1; - fi; - od; - - # sort the rows with respect to their norms - h := 1; while 9 * h + 4 < nrrows-(d-1) do h := 3 * h + 1; od; - while 0 < h do - for l in [ h+1 .. nrrows-(d-1) ] do - norm := rownorms[l+(d-1)]; - row := mat[l+(d-1)]; - k := l; - while h+1 <= k and norm < rownorms[k-h+(d-1)] do - rownorms[k+(d-1)] := rownorms[k-h+(d-1)]; - mat[k+(d-1)] := mat[k-h+(d-1)]; - k := k - h; - od; - rownorms[k+(d-1)] := norm; - mat[k+(d-1)] := row; - od; - h := QuoInt( h, 3 ); - od; - - # choose a pivot in the '{[..]}{[..]}' submatrix - # the pivot must be the topmost nonzero entry in its column, - # now that the rows are sorted with respect to their norm - pivk := 0; pivl := 0; - norm := Maximum(rownorms) * Maximum(colnorms) + 1; - for l in [ d .. nrcols ] do - k := d; - while mat[k][l] = 0 do - k := k + 1; - od; - if rownorms[k] * colnorms[l] < norm then - pivk := k; pivl := l; - norm := rownorms[k] * colnorms[l]; - fi; - od; - Info( InfoMatrix, 3, " p" ); - - # move the pivot to the diagonal and make it positive - if d <> pivk then - row := mat[d]; - mat[d] := mat[pivk]; - mat[pivk] := row; - fi; - if d <> pivl then - col := mat{[d..nrrows]}[d]; - mat{[d..nrrows]}[d] := mat{[d..nrrows]}[pivl]; - mat{[d..nrrows]}[pivl] := col; - fi; - if mat[d][d] < 0 then - MultRowVector(mat[d],-1); - fi; - - # now perform row operations so that the entries in the - # -th column have absolute value at most pivot/2 - clear := true; - row := mat[d]; - for k in [ d+1 .. nrrows ] do - quo := BestQuoInt( mat[k][d], mat[d][d] ); - if quo = 1 then - AddRowVector(mat[k], row, -1); - elif quo = -1 then - AddRowVector(mat[k], row); - elif quo <> 0 then - AddRowVector(mat[k], row, -quo); - fi; - clear := clear and mat[k][d] = 0; - od; - Info( InfoMatrix, 3, " c" ); - - # now perform column operations so that the entries in - # the -th row have absolute value at most pivot/2 - col := mat{[d..nrrows]}[d]; - for l in [ d+1 .. nrcols ] do - quo := BestQuoInt( mat[d][l], mat[d][d] ); - if quo = 1 then - mat{[d..nrrows]}[l] := mat{[d..nrrows]}[l] - col; - elif quo = -1 then - mat{[d..nrrows]}[l] := mat{[d..nrrows]}[l] + col; - elif quo <> 0 then - mat{[d..nrrows]}[l] := mat{[d..nrrows]}[l] - quo * col; - fi; - clear := clear and mat[d][l] = 0; - od; - Info( InfoMatrix, 3, " r" ); - - # repeat until the -th row and column are totally cleared - while not clear do - - # compute the Euclidean norms of the rows and columns - # that have a nonzero entry in the -th column resp. row - for k in [ d .. nrrows ] do - if mat[k][d] <> 0 then - row := mat[k]; - rownorms[k] := row * row; - fi; - od; - for l in [ d .. nrcols ] do - if mat[d][l] <> 0 then - col := mat{[d..nrrows]}[l]; - colnorms[l] := col * col; - fi; - od; - Info( InfoMatrix, 3, " n" ); - - # choose a pivot in the -th row or -th column - pivk := 0; pivl := 0; - norm := Maximum(rownorms) * Maximum(colnorms) + 1; - for l in [ d+1 .. nrcols ] do - if 0 <> mat[d][l] and rownorms[d] * colnorms[l] < norm then - pivk := d; pivl := l; - norm := rownorms[d] * colnorms[l]; - fi; - od; - for k in [ d+1 .. nrrows ] do - if 0 <> mat[k][d] and rownorms[k] * colnorms[d] < norm then - pivk := k; pivl := d; - norm := rownorms[k] * colnorms[d]; - fi; - od; - Info( InfoMatrix, 3, " p" ); - - # move the pivot to the diagonal and make it positive - if d <> pivk then - row := mat[d]; - mat[d] := mat[pivk]; - mat[pivk] := row; - fi; - if d <> pivl then - col := mat{[d..nrrows]}[d]; - mat{[d..nrrows]}[d] := mat{[d..nrrows]}[pivl]; - mat{[d..nrrows]}[pivl] := col; - fi; - if mat[d][d] < 0 then - MultRowVector(mat[d],-1); - fi; - - # now perform row operations so that the entries in the - # -th column have absolute value at most pivot/2 - clear := true; - row := mat[d]; - for k in [ d+1 .. nrrows ] do - quo := BestQuoInt( mat[k][d], mat[d][d] ); - if quo = 1 then - AddRowVector(mat[k],row,-1); - elif quo = -1 then - AddRowVector(mat[k],row); - elif quo <> 0 then - AddRowVector(mat[k], row, -quo); - fi; - clear := clear and mat[k][d] = 0; - od; - Info( InfoMatrix, 3, " c" ); - - # now perform column operations so that the entries in - # the -th row have absolute value at most pivot/2 - col := mat{[d..nrrows]}[d]; - for l in [ d+1.. nrcols ] do - quo := BestQuoInt( mat[d][l], mat[d][d] ); - if quo = 1 then - mat{[d..nrrows]}[l] := mat{[d..nrrows]}[l] - col; - elif quo = -1 then - mat{[d..nrrows]}[l] := mat{[d..nrrows]}[l] + col; - elif quo <> 0 then - mat{[d..nrrows]}[l] := mat{[d..nrrows]}[l] - quo * col; - fi; - clear := clear and mat[d][l] = 0; - od; - Info( InfoMatrix, 3, " r" ); - - od; - - # print the diagonal entry (for information only) - Info( InfoMatrix, 3, " div=" ); - Info( InfoMatrix, 2, " ", mat[d][d] ); - - # go on to the next diagonal position - d := d + 1; - - od; - - # close with some more information - Info( InfoMatrix, 3, " overall maximal entry ", omax ); - Info( InfoMatrix, 1, "DiagonalizeMat returns" ); -end ); +# InstallGlobalFunction( DiagonalizeIntMatNormDriven, function ( mat ) +# local nrrows, # number of rows (length of ) +# nrcols, # number of columns (length of [1]) +# rownorms, # norms of rows +# colnorms, # norms of columns +# d, # diagonal position +# pivk, pivl, # position of a pivot +# norm, # product of row and column norms of the pivot +# clear, # are the row and column cleared +# row, # one row +# col, # one column +# ent, # one entry of matrix +# quo, # quotient +# h, # gap width in shell sort +# k, l, # loop variables +# max, omax; # maximal entry and overall maximal entry +# +# # give some information +# Info( InfoMatrix, 1, "DiagonalizeMat called" ); +# omax := 0; +# +# # get the number of rows and columns +# nrrows := Length( mat ); +# if nrrows <> 0 then +# nrcols := Length( mat[1] ); +# else +# nrcols := 0; +# fi; +# rownorms := []; +# colnorms := []; +# +# # loop over the diagonal positions +# d := 1; +# Info( InfoMatrix, 2, " divisors:" ); +# +# while d <= nrrows and d <= nrcols do +# +# # find the maximal entry +# Info( InfoMatrix, 3, " d=", d ); +# if 3 <= InfoLevel( InfoMatrix ) then +# max := 0; +# for k in [ d .. nrrows ] do +# for l in [ d .. nrcols ] do +# ent := mat[k][l]; +# if 0 < ent and max < ent then +# max := ent; +# elif ent < 0 and max < -ent then +# max := -ent; +# fi; +# od; +# od; +# Info( InfoMatrix, 3, " max=", max ); +# if omax < max then omax := max; fi; +# fi; +# +# # compute the Euclidean norms of the rows and columns +# for k in [ d .. nrrows ] do +# row := mat[k]; +# rownorms[k] := row * row; +# od; +# for l in [ d .. nrcols ] do +# col := mat{[d..nrrows]}[l]; +# colnorms[l] := col * col; +# od; +# Info( InfoMatrix, 3, " n" ); +# +# # push rows containing only zeroes down and forget about them +# for k in [ nrrows, nrrows-1 .. d ] do +# if k < nrrows and rownorms[k] = 0 then +# row := mat[k]; +# mat[k] := mat[nrrows]; +# mat[nrrows] := row; +# norm := rownorms[k]; +# rownorms[k] := rownorms[nrrows]; +# rownorms[nrrows] := norm; +# fi; +# if rownorms[nrrows] = 0 then +# nrrows := nrrows - 1; +# fi; +# od; +# +# # quit if there are no more nonzero entries +# if nrrows < d then +# #N 1996/04/30 mschoene should 'break' +# Info( InfoMatrix, 3, " overall maximal entry ", omax ); +# Info( InfoMatrix, 1, "DiagonalizeMat returns" ); +# return; +# fi; +# +# # push columns containing only zeroes right and forget about them +# for l in [ nrcols, nrcols-1 .. d ] do +# if l < nrcols and colnorms[l] = 0 then +# col := mat{[d..nrrows]}[l]; +# mat{[d..nrrows]}[l] := mat{[d..nrrows]}[nrcols]; +# mat{[d..nrrows]}[nrcols] := col; +# norm := colnorms[l]; +# colnorms[l] := colnorms[nrcols]; +# colnorms[nrcols] := norm; +# fi; +# if colnorms[nrcols] = 0 then +# nrcols := nrcols - 1; +# fi; +# od; +# +# # sort the rows with respect to their norms +# h := 1; while 9 * h + 4 < nrrows-(d-1) do h := 3 * h + 1; od; +# while 0 < h do +# for l in [ h+1 .. nrrows-(d-1) ] do +# norm := rownorms[l+(d-1)]; +# row := mat[l+(d-1)]; +# k := l; +# while h+1 <= k and norm < rownorms[k-h+(d-1)] do +# rownorms[k+(d-1)] := rownorms[k-h+(d-1)]; +# mat[k+(d-1)] := mat[k-h+(d-1)]; +# k := k - h; +# od; +# rownorms[k+(d-1)] := norm; +# mat[k+(d-1)] := row; +# od; +# h := QuoInt( h, 3 ); +# od; +# +# # choose a pivot in the '{[..]}{[..]}' submatrix +# # the pivot must be the topmost nonzero entry in its column, +# # now that the rows are sorted with respect to their norm +# pivk := 0; pivl := 0; +# norm := Maximum(rownorms) * Maximum(colnorms) + 1; +# for l in [ d .. nrcols ] do +# k := d; +# while mat[k][l] = 0 do +# k := k + 1; +# od; +# if rownorms[k] * colnorms[l] < norm then +# pivk := k; pivl := l; +# norm := rownorms[k] * colnorms[l]; +# fi; +# od; +# Info( InfoMatrix, 3, " p" ); +# +# # move the pivot to the diagonal and make it positive +# if d <> pivk then +# row := mat[d]; +# mat[d] := mat[pivk]; +# mat[pivk] := row; +# fi; +# if d <> pivl then +# col := mat{[d..nrrows]}[d]; +# mat{[d..nrrows]}[d] := mat{[d..nrrows]}[pivl]; +# mat{[d..nrrows]}[pivl] := col; +# fi; +# if mat[d][d] < 0 then +# MultRowVector(mat[d],-1); +# fi; +# +# # now perform row operations so that the entries in the +# # -th column have absolute value at most pivot/2 +# clear := true; +# row := mat[d]; +# for k in [ d+1 .. nrrows ] do +# quo := BestQuoInt( mat[k][d], mat[d][d] ); +# if quo = 1 then +# AddRowVector(mat[k], row, -1); +# elif quo = -1 then +# AddRowVector(mat[k], row); +# elif quo <> 0 then +# AddRowVector(mat[k], row, -quo); +# fi; +# clear := clear and mat[k][d] = 0; +# od; +# Info( InfoMatrix, 3, " c" ); +# +# # now perform column operations so that the entries in +# # the -th row have absolute value at most pivot/2 +# col := mat{[d..nrrows]}[d]; +# for l in [ d+1 .. nrcols ] do +# quo := BestQuoInt( mat[d][l], mat[d][d] ); +# if quo = 1 then +# mat{[d..nrrows]}[l] := mat{[d..nrrows]}[l] - col; +# elif quo = -1 then +# mat{[d..nrrows]}[l] := mat{[d..nrrows]}[l] + col; +# elif quo <> 0 then +# mat{[d..nrrows]}[l] := mat{[d..nrrows]}[l] - quo * col; +# fi; +# clear := clear and mat[d][l] = 0; +# od; +# Info( InfoMatrix, 3, " r" ); +# +# # repeat until the -th row and column are totally cleared +# while not clear do +# +# # compute the Euclidean norms of the rows and columns +# # that have a nonzero entry in the -th column resp. row +# for k in [ d .. nrrows ] do +# if mat[k][d] <> 0 then +# row := mat[k]; +# rownorms[k] := row * row; +# fi; +# od; +# for l in [ d .. nrcols ] do +# if mat[d][l] <> 0 then +# col := mat{[d..nrrows]}[l]; +# colnorms[l] := col * col; +# fi; +# od; +# Info( InfoMatrix, 3, " n" ); +# +# # choose a pivot in the -th row or -th column +# pivk := 0; pivl := 0; +# norm := Maximum(rownorms) * Maximum(colnorms) + 1; +# for l in [ d+1 .. nrcols ] do +# if 0 <> mat[d][l] and rownorms[d] * colnorms[l] < norm then +# pivk := d; pivl := l; +# norm := rownorms[d] * colnorms[l]; +# fi; +# od; +# for k in [ d+1 .. nrrows ] do +# if 0 <> mat[k][d] and rownorms[k] * colnorms[d] < norm then +# pivk := k; pivl := d; +# norm := rownorms[k] * colnorms[d]; +# fi; +# od; +# Info( InfoMatrix, 3, " p" ); +# +# # move the pivot to the diagonal and make it positive +# if d <> pivk then +# row := mat[d]; +# mat[d] := mat[pivk]; +# mat[pivk] := row; +# fi; +# if d <> pivl then +# col := mat{[d..nrrows]}[d]; +# mat{[d..nrrows]}[d] := mat{[d..nrrows]}[pivl]; +# mat{[d..nrrows]}[pivl] := col; +# fi; +# if mat[d][d] < 0 then +# MultRowVector(mat[d],-1); +# fi; +# +# # now perform row operations so that the entries in the +# # -th column have absolute value at most pivot/2 +# clear := true; +# row := mat[d]; +# for k in [ d+1 .. nrrows ] do +# quo := BestQuoInt( mat[k][d], mat[d][d] ); +# if quo = 1 then +# AddRowVector(mat[k],row,-1); +# elif quo = -1 then +# AddRowVector(mat[k],row); +# elif quo <> 0 then +# AddRowVector(mat[k], row, -quo); +# fi; +# clear := clear and mat[k][d] = 0; +# od; +# Info( InfoMatrix, 3, " c" ); +# +# # now perform column operations so that the entries in +# # the -th row have absolute value at most pivot/2 +# col := mat{[d..nrrows]}[d]; +# for l in [ d+1.. nrcols ] do +# quo := BestQuoInt( mat[d][l], mat[d][d] ); +# if quo = 1 then +# mat{[d..nrrows]}[l] := mat{[d..nrrows]}[l] - col; +# elif quo = -1 then +# mat{[d..nrrows]}[l] := mat{[d..nrrows]}[l] + col; +# elif quo <> 0 then +# mat{[d..nrrows]}[l] := mat{[d..nrrows]}[l] - quo * col; +# fi; +# clear := clear and mat[d][l] = 0; +# od; +# Info( InfoMatrix, 3, " r" ); +# +# od; +# +# # print the diagonal entry (for information only) +# Info( InfoMatrix, 3, " div=" ); +# Info( InfoMatrix, 2, " ", mat[d][d] ); +# +# # go on to the next diagonal position +# d := d + 1; +# +# od; +# +# # close with some more information +# Info( InfoMatrix, 3, " overall maximal entry ", omax ); +# Info( InfoMatrix, 1, "DiagonalizeMat returns" ); +# end ); ############################################################################# @@ -351,49 +351,49 @@ end ); ## #M ShrinkCoeffs( ) ## -InstallMethod( ShrinkCoeffs,"call `ShrinkRowVector'", - [ IsList and IsMutable ], -function( l1 ) - Info( InfoObsolete, 1, - "the operation `ShrinkCoeffs' is not supported anymore,\n", - "#I use `ShrinkRowVector' instead" ); - ShrinkRowVector(l1); - return Length(l1); -end ); - -InstallOtherMethod( ShrinkCoeffs,"error if immutable", - [ IsList ], - L1_IMMUTABLE_ERROR); +# InstallMethod( ShrinkCoeffs,"call `ShrinkRowVector'", +# [ IsList and IsMutable ], +# function( l1 ) +# Info( InfoObsolete, 1, +# "the operation `ShrinkCoeffs' is not supported anymore,\n", +# "#I use `ShrinkRowVector' instead" ); +# ShrinkRowVector(l1); +# return Length(l1); +# end ); +# +# InstallOtherMethod( ShrinkCoeffs,"error if immutable", +# [ IsList ], +# L1_IMMUTABLE_ERROR); ############################################################################# ## #M ShrinkCoeffs( ) ## -InstallMethod( ShrinkCoeffs, "8 bit vector", - [IsMutable and IsRowVector and Is8BitVectorRep ], - function(vec) - local r; - Info( InfoObsolete, 1, - "the operation `ShrinkCoeffs' is not supported anymore,\n", - "#I use `ShrinkRowVector' instead" ); - r := RIGHTMOST_NONZERO_VEC8BIT(vec); - RESIZE_VEC8BIT(vec, r); - return r; -end); +# InstallMethod( ShrinkCoeffs, "8 bit vector", +# [IsMutable and IsRowVector and Is8BitVectorRep ], +# function(vec) +# local r; +# Info( InfoObsolete, 1, +# "the operation `ShrinkCoeffs' is not supported anymore,\n", +# "#I use `ShrinkRowVector' instead" ); +# r := RIGHTMOST_NONZERO_VEC8BIT(vec); +# RESIZE_VEC8BIT(vec, r); +# return r; +# end); ############################################################################# ## #M ShrinkCoeffs( ) . . . . . . . . . . . . . . shrink a GF2 vector ## -InstallMethod( ShrinkCoeffs, - "for GF2 vector", - [ IsMutable and IsRowVector and IsGF2VectorRep ], -function( l1 ) - Info( InfoObsolete, 1, - "the operation `ShrinkCoeffs' is not supported anymore,\n", - "#I use `ShrinkRowVector' instead" ); - return SHRINKCOEFFS_GF2VEC(l1); -end ); +# InstallMethod( ShrinkCoeffs, +# "for GF2 vector", +# [ IsMutable and IsRowVector and IsGF2VectorRep ], +# function( l1 ) +# Info( InfoObsolete, 1, +# "the operation `ShrinkCoeffs' is not supported anymore,\n", +# "#I use `ShrinkRowVector' instead" ); +# return SHRINKCOEFFS_GF2VEC(l1); +# end ); ############################################################################# @@ -698,13 +698,13 @@ end); ## ## for backwards compatibility only ... ## -BindGlobal( "CharacterTableDisplayPrintLegendDefault", - function( data ) - Info( InfoObsolete, 1, - "the function `CharacterTableDisplayPrintLegendDefault' is no longer\n", - "#I supported and may be removed from future versions of GAP" ); - Print( CharacterTableDisplayLegendDefault( data ) ); - end ); +# BindGlobal( "CharacterTableDisplayPrintLegendDefault", +# function( data ) +# Info( InfoObsolete, 1, +# "the function `CharacterTableDisplayPrintLegendDefault' is no longer\n", +# "#I supported and may be removed from future versions of GAP" ); +# Print( CharacterTableDisplayLegendDefault( data ) ); +# end ); ############################################################################# @@ -712,64 +712,64 @@ BindGlobal( "CharacterTableDisplayPrintLegendDefault", #F ConnectGroupAndCharacterTable( , [, ] ) #F ConnectGroupAndCharacterTable( , , ) ## -InstallGlobalFunction( ConnectGroupAndCharacterTable, function( arg ) - local G, tbl, arec, ccl, compat; - - Info( InfoObsolete, 1, - "the function `ConnectGroupAndCharacterTable' is not supported anymore,\n", - "#I use `CharacterTableWithStoredGroup' instead" ); - - # Get and check the arguments. - if Length( arg ) = 2 and IsGroup( arg[1] ) - and IsOrdinaryTable( arg[2] ) then - arec:= rec(); - elif Length( arg ) = 3 and IsGroup( arg[1] ) - and IsOrdinaryTable( arg[2] ) - and ( IsRecord( arg[3] ) or IsList(arg[3]) ) then - arec:= arg[3]; - else - Error( "usage: ConnectGroupAndCharacterTable(,[,])" ); - fi; - - G := arg[1]; - tbl := arg[2]; - - if HasUnderlyingGroup( tbl ) then - Error( " has already underlying group" ); - elif HasOrdinaryCharacterTable( G ) then - Error( " has already a character table" ); - fi; - - ccl:= ConjugacyClasses( G ); -#T How to exploit the known character table -#T if the conjugacy classes of are not yet computed? - - if IsList( arec ) then - compat:= arec; - else - compat:= CompatibleConjugacyClasses( G, ccl, tbl, arec ); - fi; - - if IsList( compat ) then - - # Permute the classes if necessary. - if compat <> [ 1 .. Length( compat ) ] then - ccl:= ccl{ compat }; - fi; - - # The identification is unique, store attribute values. - SetUnderlyingGroup( tbl, G ); - SetOrdinaryCharacterTable( G, tbl ); - SetConjugacyClasses( tbl, ccl ); - SetIdentificationOfConjugacyClasses( tbl, compat ); - - return true; - - else - return false; - fi; - - end ); +# InstallGlobalFunction( ConnectGroupAndCharacterTable, function( arg ) +# local G, tbl, arec, ccl, compat; +# +# Info( InfoObsolete, 1, +# "the function `ConnectGroupAndCharacterTable' is not supported anymore,\n", +# "#I use `CharacterTableWithStoredGroup' instead" ); +# +# # Get and check the arguments. +# if Length( arg ) = 2 and IsGroup( arg[1] ) +# and IsOrdinaryTable( arg[2] ) then +# arec:= rec(); +# elif Length( arg ) = 3 and IsGroup( arg[1] ) +# and IsOrdinaryTable( arg[2] ) +# and ( IsRecord( arg[3] ) or IsList(arg[3]) ) then +# arec:= arg[3]; +# else +# Error( "usage: ConnectGroupAndCharacterTable(,[,])" ); +# fi; +# +# G := arg[1]; +# tbl := arg[2]; +# +# if HasUnderlyingGroup( tbl ) then +# Error( " has already underlying group" ); +# elif HasOrdinaryCharacterTable( G ) then +# Error( " has already a character table" ); +# fi; +# +# ccl:= ConjugacyClasses( G ); +# #T How to exploit the known character table +# #T if the conjugacy classes of are not yet computed? +# +# if IsList( arec ) then +# compat:= arec; +# else +# compat:= CompatibleConjugacyClasses( G, ccl, tbl, arec ); +# fi; +# +# if IsList( compat ) then +# +# # Permute the classes if necessary. +# if compat <> [ 1 .. Length( compat ) ] then +# ccl:= ccl{ compat }; +# fi; +# +# # The identification is unique, store attribute values. +# SetUnderlyingGroup( tbl, G ); +# SetOrdinaryCharacterTable( G, tbl ); +# SetConjugacyClasses( tbl, ccl ); +# SetIdentificationOfConjugacyClasses( tbl, compat ); +# +# return true; +# +# else +# return false; +# fi; +# +# end ); ############################################################################# @@ -783,16 +783,16 @@ InstallGlobalFunction( ConnectGroupAndCharacterTable, function( arg ) ## GAPInfo.ViewLength:= UserPreference( "ViewLength" ) is the maximal ## number of lines that are reasonably printed in `ViewObj' methods. ## -BIND_GLOBAL( "ViewLength", function(arg) - Info (InfoObsolete, 1, "The function `ViewLength' is no longer supported. ", - "Please use user preference `ViewLength' instead."); - if LEN_LIST( arg ) = 0 then - return GAPInfo.ViewLength; - else - GAPInfo.ViewLength:= arg[1]; - fi; -end ); - +# BIND_GLOBAL( "ViewLength", function(arg) +# Info (InfoObsolete, 1, "The function `ViewLength' is no longer supported. ", +# "Please use user preference `ViewLength' instead."); +# if LEN_LIST( arg ) = 0 then +# return GAPInfo.ViewLength; +# else +# GAPInfo.ViewLength:= arg[1]; +# fi; +# end ); +# ############################################################################# @@ -825,57 +825,57 @@ end ); ## by PositionSorted(list, [obj]), it was deemed ## simples to declare it obsolete. -InstallMethod( PositionFirstComponent,"for dense plain list", true, - [ IsDenseList and IsSortedList and IsPlistRep, IsObject ], 0, -function ( list, obj ) - Info( InfoObsolete, 1, - "the operation `PositionFirstComponent' is not supported anymore" ); - return POSITION_FIRST_COMPONENT_SORTED(list, obj); -end); - - -InstallMethod( PositionFirstComponent,"for dense list", true, - [ IsDenseList, IsObject ], 0, -function ( list, obj ) -local i; - Info( InfoObsolete, 1, - "the operation `PositionFirstComponent' is not supported anymore" ); - i:=1; - while i<=Length(list) do - if list[i][1]=obj then - return i; - fi; - i:=i+1; - od; - return i; -end); - -InstallMethod( PositionFirstComponent,"for sorted list", true, - [ IsSSortedList, IsObject ], 0, -function ( list, obj ) -local lo,up,s; - Info( InfoObsolete, 1, - "the operation `PositionFirstComponent' is not supported anymore" ); - # simple binary search. The entry is in the range [lo..up] - lo:=1; - up:=Length(list); - while lo