Skip to content

Commit

Permalink
Merge pull request #610 from zickgraf/master
Browse files Browse the repository at this point in the history
Add RingFilter and RingElementFilter to more rings
  • Loading branch information
mohamed-barakat authored Jul 9, 2024
2 parents a6731f3 + 1df4c5c commit 3b863b0
Show file tree
Hide file tree
Showing 8 changed files with 21 additions and 4 deletions.
2 changes: 1 addition & 1 deletion GaussForHomalg/PackageInfo.g
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@ SetPackageInfo( rec(

PackageName := "GaussForHomalg",
Subtitle := "Gauss functionality for the homalg project",
Version := "2023.11-01",
Version := "2024.07-01",
Date := (function ( ) if IsBound( GAPInfo.SystemEnvironment.GAP_PKG_RELEASE_DATE ) then return GAPInfo.SystemEnvironment.GAP_PKG_RELEASE_DATE; else return Concatenation( ~.Version{[ 1 .. 4 ]}, "-", ~.Version{[ 6, 7 ]}, "-01" ); fi; end)( ),
License := "GPL-2.0-or-later",

Expand Down
7 changes: 7 additions & 0 deletions GaussForHomalg/gap/GaussTools.gi
Original file line number Diff line number Diff line change
Expand Up @@ -406,11 +406,18 @@ InstallGlobalFunction( HOMALG_RING_OF_INTEGERS_PRIME_POWER_HELPER,
d := 1;
fi;
R := CreateHomalgRing( GF( c, d ) );

SetRingFilter( R, IsHomalgRing );
SetRingElementFilter( R, IsFFE );

R!.NameOfPrimitiveElement := Concatenation( "Z", String( c ), "_", String( d ) );
SetIsFieldForHomalg( R, true );
SetRingProperties( R, c, d );
else
R := CreateHomalgRing( ZmodnZ( c ) );

SetRingFilter( R, IsHomalgRing );
SetRingElementFilter( R, IsZmodnZObj );
fi;
return R;
end );
2 changes: 1 addition & 1 deletion GradedRingForHomalg/PackageInfo.g
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@ SetPackageInfo( rec(

PackageName := "GradedRingForHomalg",
Subtitle := "Endow Commutative Rings with an Abelian Grading",
Version := "2023.08-01",
Version := "2024.07-01",
Date := (function ( ) if IsBound( GAPInfo.SystemEnvironment.GAP_PKG_RELEASE_DATE ) then return GAPInfo.SystemEnvironment.GAP_PKG_RELEASE_DATE; else return Concatenation( ~.Version{[ 1 .. 4 ]}, "-", ~.Version{[ 6, 7 ]}, "-01" ); fi; end)( ),
License := "GPL-2.0-or-later",

Expand Down
4 changes: 4 additions & 0 deletions GradedRingForHomalg/gap/GradedRing.gi
Original file line number Diff line number Diff line change
Expand Up @@ -779,6 +779,10 @@ InstallMethod( GradedRing,

## create the graded ring
S := CreateHomalgRing( R, [ TheTypeHomalgGradedRing, ValueGlobal( "TheTypeHomalgMatrixOverGradedRing" ) ], GradedRingElement, RP );

SetRingFilter( S, IsHomalgGradedRingRep );
SetRingElementFilter( S, IsHomalgGradedRingElementRep );

SetConstructorForHomalgMatrices( S,
function( arg )
local nargs, mat, R, l;
Expand Down
2 changes: 1 addition & 1 deletion MatricesForHomalg/PackageInfo.g
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@ SetPackageInfo( rec(

PackageName := "MatricesForHomalg",
Subtitle := "Matrices for the homalg project",
Version := "2024.06-01",
Version := "2024.07-01",
Date := (function ( ) if IsBound( GAPInfo.SystemEnvironment.GAP_PKG_RELEASE_DATE ) then return GAPInfo.SystemEnvironment.GAP_PKG_RELEASE_DATE; else return Concatenation( ~.Version{[ 1 .. 4 ]}, "-", ~.Version{[ 6, 7 ]}, "-01" ); fi; end)( ),
License := "GPL-2.0-or-later",

Expand Down
3 changes: 3 additions & 0 deletions MatricesForHomalg/gap/ResidueClassRing.gi
Original file line number Diff line number Diff line change
Expand Up @@ -578,6 +578,9 @@ InstallMethod( \/, ## this operation is declared in the file HomalgRelations.gd
## create the residue class ring
S := CreateHomalgRing( R, [ TheTypeHomalgResidueClassRing, TheTypeHomalgResidueClassMatrix ], HomalgResidueClassRingElement, RP );

SetRingFilter( S, IsHomalgResidueClassRingRep );
SetRingElementFilter( S, IsHomalgResidueClassRingElementRep );

## the constructor of matrices over residue class rings
SetConstructorForHomalgMatrices( S,
function( arg )
Expand Down
2 changes: 1 addition & 1 deletion ToolsForHomalg/PackageInfo.g
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@ SetPackageInfo( rec(

PackageName := "ToolsForHomalg",
Subtitle := "Special methods and knowledge propagation tools",
Version := "2023.11-01",
Version := "2024.07-01",
Date := (function ( ) if IsBound( GAPInfo.SystemEnvironment.GAP_PKG_RELEASE_DATE ) then return GAPInfo.SystemEnvironment.GAP_PKG_RELEASE_DATE; else return Concatenation( ~.Version{[ 1 .. 4 ]}, "-", ~.Version{[ 6, 7 ]}, "-01" ); fi; end)( ),
License := "GPL-2.0-or-later",

Expand Down
3 changes: 3 additions & 0 deletions ToolsForHomalg/gap/ToolsForHomalg.gd
Original file line number Diff line number Diff line change
Expand Up @@ -105,6 +105,9 @@ DeclareAttribute( "RingElementFilter",
SetRingFilter( Integers, IsIntegers );
SetRingElementFilter( Integers, IsInt );

SetRingFilter( Rationals, IsRationals );
SetRingElementFilter( Rationals, IsRat );

####################################
#
# global functions and operations:
Expand Down

0 comments on commit 3b863b0

Please sign in to comment.