Skip to content

Commit

Permalink
construct complexes categories as tower of categories
Browse files Browse the repository at this point in the history
and adjust DerivedCategories & HomotopyCategories to
the current refactoring
  • Loading branch information
kamalsaleh committed Jun 16, 2023
1 parent c8d0c6d commit 2a877f6
Show file tree
Hide file tree
Showing 27 changed files with 437 additions and 646 deletions.
2 changes: 1 addition & 1 deletion Bicomplexes/PackageInfo.g
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@ SetPackageInfo( rec(

PackageName := "Bicomplexes",
Subtitle := "Bicomplexes for Abelian categories",
Version := "2023.05-02",
Version := "2023.06-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
26 changes: 10 additions & 16 deletions Bicomplexes/gap/Bicomplexes.gi
Original file line number Diff line number Diff line change
Expand Up @@ -68,21 +68,19 @@ BindGlobal( "CREATE_BICOMPLEXES_CATEGORY",
coch_cat := UnderlyingCategory( modeling_cat );

objects := AsZFunction(
i -> ObjectConstructor( coch_cat,
[ AsZFunction( j -> datum[1](i, j) ),
i -> CreateComplex( coch_cat,
AsZFunction( j -> datum[1](i, j) ),
AsZFunction( j -> (-1)^i * datum[3](i, j) ),
datum[6],
datum[7] ] ) );
datum[7] ) );

diffs := AsZFunction(
i -> MorphismConstructor( coch_cat,
i -> CreateComplexMorphism( coch_cat,
objects[i],
[ AsZFunction( j -> datum[2]( i, j ) ),
datum[6],
datum[7] ],
AsZFunction( j -> datum[2]( i, j ) ),
objects[i+index_shift] ) );

return ObjectConstructor( modeling_cat, [ objects, diffs, datum[4], datum[5] ] );
return CreateComplex( modeling_cat, objects, diffs, datum[4], datum[5] );

end;

Expand All @@ -107,18 +105,14 @@ BindGlobal( "CREATE_BICOMPLEXES_CATEGORY",
coch_cat := UnderlyingCategory( modeling_cat );

morphisms := AsZFunction(
i -> MorphismConstructor( coch_cat,
i -> CreateComplexMorphism( coch_cat,
source[i],
[ AsZFunction( j -> datum( i, j ) ),
Minimum( LowerBound( source[i] ), LowerBound( range[i] ) ),
Maximum( UpperBound( source[i] ), UpperBound( range[i] ) ) ],
AsZFunction( j -> datum( i, j ) ),
range[i] ) );

return MorphismConstructor( modeling_cat,
return CreateComplexMorphism( modeling_cat,
source,
[ morphisms,
Minimum( LowerBound( source ), LowerBound( range ) ),
Maximum( UpperBound( source ), UpperBound( range ) ) ],
morphisms,
range );

end;
Expand Down
2 changes: 1 addition & 1 deletion Bicomplexes/gap/TotalComplex.gi
Original file line number Diff line number Diff line change
Expand Up @@ -55,7 +55,7 @@ BindGlobal( "TOTAL_COMPLEX_OF_BICOMPLEX",
objs[index+sign]
) );

return ObjectConstructor( complexes_cat, [ objs, diffs, l+b, r+a ] );
return CreateComplex( complexes_cat, objs, diffs, l+b, r+a );

end );

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -136,13 +136,12 @@ gap> rels := [ PreCompose( dA1_m2, dA1_m1 ),
> -PreCompose( f4_m1, dB4_m1 ) + PreCompose( dA4_m1, f4_0 ),
> -PreCompose( f4_0, dB4_0 ) + PreCompose( dA4_0, f4_1 ),
> -PreCompose( f4_1, dB4_1 ) + PreCompose( dA4_1, f4_2) ];;
gap> oid := kF / rels;;
gap> oid := AlgebroidFromDataTables( kF / rels );;
gap> Aoid := AdditiveClosure( oid );;
gap> cochains_Aoid := ComplexesCategoryByCochains( Aoid );;
gap> cochains_cochains_Aoid := ComplexesCategoryByCochains( cochains_Aoid );;
gap> cochains_bicomplexes_Aoid := BicomplexesCategoryByCochains( Aoid );;
gap> IsIdenticalObj( cochains_cochains_Aoid, ModelingCategory( cochains_bicomplexes_Aoid ) );
true
gap> Assert( 0, IsIdenticalObj( cochains_cochains_Aoid, ModelingCategory( cochains_bicomplexes_Aoid ) ) );
gap> for object_info in objects do
> MakeReadWriteGlobal( object_info[1] );
> DeclareSynonym( object_info[1],
Expand All @@ -165,20 +164,16 @@ gap> for morphism_info in morphisms do
gap> A := CreateComplex( cochains_cochains_Aoid, [ dA_1, dA_2, dA_3 ], 1 );;
gap> B := CreateComplex( cochains_cochains_Aoid, [ dB_1, dB_2, dB_3 ], 1 );;
gap> f := CreateComplexMorphism( cochains_cochains_Aoid, A, [ f1, f2, f3, f4 ], 1, B );;
gap> ForAll( [ A, B, f ], IsWellDefined );
true
gap> Assert( 0, ForAll( [ A, B, f ], IsWellDefined ) );
gap> A := CreateBicomplex( cochains_bicomplexes_Aoid, A );;
gap> B := CreateBicomplex( cochains_bicomplexes_Aoid, B );;
gap> f := CreateBicomplexMorphism( cochains_bicomplexes_Aoid, f );;
gap> ForAll( [ A, B, f ], IsWellDefined );
true
gap> Assert( 0, ForAll( [ A, B, f ], IsWellDefined ) );
gap> total_f := TotalComplexFunctorial( TotalComplex(A), f, TotalComplex(B) );;
gap> IsWellDefined( total_f );
true
gap> Assert( 0, IsWellDefined( total_f ) );
gap> chains_bicomplexes_Aoid := BicomplexesCategoryByChains( Aoid );;
gap> A := CreateBicomplex( chains_bicomplexes_Aoid, A );;
gap> B := CreateBicomplex( chains_bicomplexes_Aoid, B );;
gap> f := CreateBicomplexMorphism( chains_bicomplexes_Aoid, f );;
gap> total_f := TotalComplexFunctorial( TotalComplex(A), f, TotalComplex(B) );;
gap> IsWellDefined( total_f );
true
gap> Assert( 0, IsWellDefined( total_f ) );
12 changes: 7 additions & 5 deletions ComplexesCategories/PackageInfo.g
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@ SetPackageInfo( rec(

PackageName := "ComplexesCategories",
Subtitle := "Category of (co)chain complexes of an additive category",
Version := "2023.05-02",
Version := "2023.06-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 Expand Up @@ -73,13 +73,15 @@ PackageDoc := rec(

Dependencies := rec(
GAP := ">= 4.12.1",
NeededOtherPackages := [
[ "AutoDoc", ">= 2019.09.04" ],
NeededOtherPackages := [ [ "AutoDoc", ">= 2019.09.04" ],
[ "CAP", ">= 2023.05-03" ],
[ "ToolsForHigherHomologicalAlgebra", ">= 2022.12-05" ],
[ "PreSheaves", ">= 2023.05-03" ],
],
SuggestedOtherPackages := [ ],


SuggestedOtherPackages := [ #[ "Locales", ">= 2023.05-05" ],
],

ExternalConditions := [ ],
),

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -156,7 +156,7 @@
"text": [
"A CAP category with name Complexes category by cochains( Freyd( Rows( Q[x,y,z] ) ) ):\n",
"\n",
"79 primitive operations were used to derive 325 operations for this category which algorithmically\n",
"84 primitive operations were used to derive 327 operations for this category which algorithmically\n",
"* IsEquippedWithHomomorphismStructure\n",
"* IsLinearCategoryOverCommutativeRing\n",
"* IsAbelianCategory\n"
Expand Down
4 changes: 2 additions & 2 deletions ComplexesCategories/examples/notebooks/PreSheaves.ipynb
Original file line number Diff line number Diff line change
Expand Up @@ -355,7 +355,7 @@
"name": "stdout",
"output_type": "stream",
"text": [
"77 primitive operations were used to derive 324 operations for this category which algorithmically\n",
"82 primitive operations were used to derive 326 operations for this category which algorithmically\n",
"* IsEquippedWithHomomorphismStructure\n",
"* IsLinearCategoryOverCommutativeRing\n",
"* IsAbelianCategory\n"
Expand Down Expand Up @@ -1044,7 +1044,7 @@
{
"data": {
"text/plain": [
"GAP: <A morphism in Complexes category by cochains( PreSheaves( Algebroid( Q, FreeCategory( RightQuiver( \"q_𝓞(𝓞₀,𝓞₁,𝓞₂)[x₀:𝓞₀->𝓞₁,x₁:𝓞₀->𝓞₁,x₂:𝓞₀->𝓞₁,y₀:𝓞₁->𝓞₂,y₁:𝓞₁->𝓞₂,y₂:𝓞₁->𝓞₂]\" ) ) ) / relations, Rows( Q ) ) ) supported on the interval [ 0 ]>"
"GAP: <A morphism in Complexes category by cochains( PreSheaves( Algebroid( Q, FreeCategory( RightQuiver( \"q_𝓞(𝓞₀,𝓞₁,𝓞₂)[x₀:𝓞₀->𝓞₁,x₁:𝓞₀->𝓞₁,x₂:𝓞₀->𝓞₁,y₀:𝓞₁->𝓞₂,y₁:𝓞₁->𝓞₂,y₂:𝓞₁->𝓞₂]\" ) ) ) / relations, Rows( Q ) ) ) supported on the interval [ 0 .. 2 ]>"
]
},
"execution_count": 32,
Expand Down
2 changes: 2 additions & 0 deletions ComplexesCategories/gap/Categories.gd
Original file line number Diff line number Diff line change
Expand Up @@ -40,6 +40,8 @@ DeclareCategory( "IsComplexesCategoryByCochains", IsComplexesCategory );
#
###################################################

DeclareGlobalFunction( "COMPLEXES_CATEGORY_BY_COCHAINS_AS_TOWER" );

#! @Description
#! Creates the complexes category by cochains $\mathcal{C}^b(A)$ of an additive category $A$.
#! @Arguments A
Expand Down
Loading

0 comments on commit 2a877f6

Please sign in to comment.