Skip to content

Commit bda519c

Browse files
Merge pull request #1764 from TKuh/source_range_functor
2 parents f4f8829 + 530f673 commit bda519c

13 files changed

Lines changed: 40 additions & 38 deletions

File tree

AdditiveClosuresForCAP/PackageInfo.g

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -10,7 +10,7 @@ SetPackageInfo( rec(
1010

1111
PackageName := "AdditiveClosuresForCAP",
1212
Subtitle := "Additive closures for pre-abelian categories",
13-
Version := "2025.07-02",
13+
Version := "2025.07-03",
1414
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)( ),
1515
License := "GPL-2.0-or-later",
1616

AdditiveClosuresForCAP/gap/AdditiveClosure.gi

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -352,9 +352,9 @@ InstallMethod( ExtendFunctorToAdditiveClosures,
352352
function( F )
353353
local source_cat, range_cat, additive_closure_source, additive_closure_range, name, G;
354354

355-
source_cat := AsCapCategory( Source( F ) );
355+
source_cat := SourceOfFunctor( F );
356356

357-
range_cat := AsCapCategory( Range( F ) );
357+
range_cat := RangeOfFunctor( F );
358358

359359
additive_closure_source := AdditiveClosure( source_cat );
360360

@@ -396,9 +396,9 @@ InstallMethod( ExtendFunctorWithAdditiveRangeToFunctorFromAdditiveClosureOfSourc
396396
function( F )
397397
local source_cat, range_cat, additive_closure_source, name, G;
398398

399-
source_cat := AsCapCategory( Source( F ) );
399+
source_cat := SourceOfFunctor( F );
400400

401-
range_cat := AsCapCategory( Range( F ) );
401+
range_cat := RangeOfFunctor( F );
402402

403403
if not ( HasIsAdditiveCategory( range_cat ) and IsAdditiveCategory( range_cat ) ) then
404404

@@ -455,7 +455,7 @@ InstallMethod( ExtendFunctorToAdditiveClosureOfSource,
455455
function( F )
456456
local range_cat;
457457

458-
range_cat := AsCapCategory( Range( F ) );
458+
range_cat := RangeOfFunctor( F );
459459

460460
if not ( HasIsAdditiveCategory( range_cat ) and IsAdditiveCategory( range_cat ) ) then
461461

@@ -477,7 +477,7 @@ InstallMethod( ExtendNaturalTransformationToAdditiveClosureOfSource,
477477

478478
G := Range( eta );
479479

480-
range := AsCapCategory( Range( F ) ); # = Range( G )
480+
range := RangeOfFunctor( F ); # = Range( G )
481481

482482
if not ( HasIsAdditiveCategory( range ) and IsAdditiveCategory( range ) ) then
483483

CAP/gap/CategoriesCategory.gi

Lines changed: 15 additions & 13 deletions
Original file line numberDiff line numberDiff line change
@@ -170,13 +170,15 @@ InstallMethod( SourceOfFunctor,
170170
[ IsCapFunctor ],
171171

172172
F -> AsCapCategory( Source( F ) )
173+
173174
);
174175

175176
##
176177
InstallMethod( RangeOfFunctor,
177178
[ IsCapFunctor ],
178179

179180
F -> AsCapCategory( Range( F ) )
181+
180182
);
181183

182184
BindGlobal( "CAP_INTERNAL_FUNCTOR_CREATE_FILTER_LIST",
@@ -229,7 +231,7 @@ InstallMethod( FunctorMorphismOperation,
229231

230232
filter_list := CAP_INTERNAL_FUNCTOR_CREATE_FILTER_LIST( functor, "morphism" );
231233

232-
range_cat := AsCapCategory( Range( functor ) );
234+
range_cat := RangeOfFunctor( functor );
233235

234236
filter_list := Concatenation( [ ObjectFilter( range_cat ) ], filter_list, [ ObjectFilter( range_cat ) ] );
235237

@@ -269,7 +271,7 @@ InstallMethod( AddMorphismFunction,
269271

270272
filter_list := CAP_INTERNAL_FUNCTOR_CREATE_FILTER_LIST( functor, "morphism" );
271273

272-
range_cat := AsCapCategory( Range( functor ) );
274+
range_cat := RangeOfFunctor( functor );
273275

274276
filter_list := Concatenation( [ ObjectFilter( range_cat ) ], filter_list, [ ObjectFilter( range_cat ) ] );
275277

@@ -316,8 +318,8 @@ InstallGlobalFunction( ApplyFunctor,
316318

317319
arguments := List( arguments ); # in Julia, `arguments` is a tuple which we cannot assign to below
318320

319-
source_category := AsCapCategory( Source( functor ) );
320-
range_category := AsCapCategory( Range( functor ) );
321+
source_category := SourceOfFunctor( functor );
322+
range_category := RangeOfFunctor( functor );
321323
input_signature := InputSignature( functor );
322324

323325
# n-ary functor and unary argument (possibly in product category)
@@ -433,8 +435,8 @@ AddPreCompose( category,
433435
local new_functor;
434436

435437
new_functor := CapFunctor( Concatenation( "Precomposition of ", Name( left_functor ), " and ", Name( right_functor ) ),
436-
AsCapCategory( Source( left_functor ) ),
437-
AsCapCategory( Range( right_functor ) ) );
438+
SourceOfFunctor( left_functor ),
439+
RangeOfFunctor( right_functor ) );
438440

439441
AddObjectFunction( new_functor,
440442

@@ -553,7 +555,7 @@ AddUniversalMorphismIntoDirectProductWithGivenDirectProduct( category,
553555

554556
name_string := Concatenation(
555557
"Product functor from ",
556-
Name( AsCapCategory( Source( sink[1] ) ) ),
558+
Name( SourceOfFunctor( sink[1] ) ),
557559
" to ",
558560
Name( AsCapCategory( direct_product ) )
559561
);
@@ -701,8 +703,8 @@ InstallMethod( InstallFunctor,
701703
object_filters := CAP_INTERNAL_FUNCTOR_CREATE_FILTER_LIST( functor, "object" );
702704
morphism_filters := CAP_INTERNAL_FUNCTOR_CREATE_FILTER_LIST( functor, "morphism" );
703705

704-
object_product_filters := [ ObjectFilter( AsCapCategory( Source( functor ) ) ) ];
705-
morphism_product_filters := [ MorphismFilter( AsCapCategory( Source( functor ) ) ) ];
706+
object_product_filters := [ ObjectFilter( SourceOfFunctor( functor ) ) ];
707+
morphism_product_filters := [ MorphismFilter( SourceOfFunctor( functor ) ) ];
706708

707709
install_list := [
708710
[ install_name, object_filters ],
@@ -944,7 +946,7 @@ InstallMethod( NaturalTransformationOperation,
944946

945947
filter_list := CAP_INTERNAL_FUNCTOR_CREATE_FILTER_LIST( Source( trafo ), "object" );
946948

947-
filter_list := Concatenation( [ ObjectFilter( AsCapCategory( Range( Source( trafo ) ) ) ) ], filter_list, [ ObjectFilter( AsCapCategory( Range( Source( trafo ) ) ) ) ] );
949+
filter_list := Concatenation( [ ObjectFilter( RangeOfFunctor( Source( trafo ) ) ) ], filter_list, [ ObjectFilter( RangeOfFunctor( Source( trafo ) ) ) ] );
948950

949951
return NewOperation( Concatenation( "CAP_NATURAL_TRANSFORMATION_", Name( trafo ), "_OPERATION" ), filter_list );
950952

@@ -959,7 +961,7 @@ InstallMethod( AddNaturalTransformationFunction,
959961

960962
filter_list := CAP_INTERNAL_FUNCTOR_CREATE_FILTER_LIST( Source( trafo ), "object" );
961963

962-
filter_list := Concatenation( [ ObjectFilter( AsCapCategory( Range( Source( trafo ) ) ) ) ], filter_list, [ ObjectFilter( AsCapCategory( Range( Source( trafo ) ) ) ) ] );
964+
filter_list := Concatenation( [ ObjectFilter( RangeOfFunctor( Source( trafo ) ) ) ], filter_list, [ ObjectFilter( RangeOfFunctor( Source( trafo ) ) ) ] );
963965

964966
if not IsBound( trafo!.function_list ) then
965967

@@ -984,7 +986,7 @@ InstallGlobalFunction( ApplyNaturalTransformation,
984986

985987
source_functor := Source( trafo );
986988

987-
range_category := AsCapCategory( Range( source_functor ) );
989+
range_category := RangeOfFunctor( source_functor );
988990

989991
arguments := arg{[ 2 .. Length( arg ) ]};
990992

@@ -1044,7 +1046,7 @@ InstallMethod( InstallNaturalTransformation,
10441046

10451047
object_filters := CAP_INTERNAL_FUNCTOR_CREATE_FILTER_LIST( Source( trafo ), "object" );
10461048

1047-
object_product_filters := [ ObjectFilter( AsCapCategory( Source( Source( trafo ) ) ) ) ];
1049+
object_product_filters := [ ObjectFilter( SourceOfFunctor( Source( trafo ) ) ) ];
10481050

10491051
for current_filters in [
10501052
[ install_name, object_filters ],

FreydCategoriesForCAP/PackageInfo.g

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -10,7 +10,7 @@ SetPackageInfo( rec(
1010

1111
PackageName := "FreydCategoriesForCAP",
1212
Subtitle := "Freyd categories - Formal (co)kernels for additive categories",
13-
Version := "2025.06-09",
13+
Version := "2025.07-01",
1414
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)( ),
1515
License := "GPL-2.0-or-later",
1616

FreydCategoriesForCAP/gap/AdelmanCategory.gi

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1014,7 +1014,7 @@ InstallMethod( AdelmanCategoryFunctorInducedByUniversalProperty,
10141014
function( functor )
10151015
local source, range, induced_functor;
10161016

1017-
range := AsCapCategory( Range( functor ) );
1017+
range := RangeOfFunctor( functor );
10181018

10191019
if not ( HasIsAbelianCategory( range ) and IsAbelianCategory( range ) ) then
10201020

@@ -1028,7 +1028,7 @@ InstallMethod( AdelmanCategoryFunctorInducedByUniversalProperty,
10281028

10291029
fi;
10301030

1031-
source := AdelmanCategory( AsCapCategory( Source( functor ) ) );
1031+
source := AdelmanCategory( SourceOfFunctor( functor ) );
10321032

10331033
induced_functor :=
10341034
CapFunctor(

FreydCategoriesForCAP/gap/LinearClosure.gi

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -879,9 +879,9 @@ InstallMethodWithCache( ExtendFunctorToLinearClosureOfSource,
879879
function( F, linear_closure_source, ring_map )
880880
local source_cat, range_cat, name, G;
881881

882-
source_cat := AsCapCategory( Source( F ) );
882+
source_cat := SourceOfFunctor( F );
883883

884-
range_cat := AsCapCategory( Range( F ) );
884+
range_cat := RangeOfFunctor( F );
885885

886886
if not IsIdenticalObj( source_cat, UnderlyingCategory( linear_closure_source ) ) then
887887

GeneralizedMorphismsForCAP/PackageInfo.g

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -10,7 +10,7 @@ SetPackageInfo( rec(
1010

1111
PackageName := "GeneralizedMorphismsForCAP",
1212
Subtitle := "Implementations of generalized morphisms for the CAP project",
13-
Version := "2025.06-01",
13+
Version := "2025.07-01",
1414
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)( ),
1515
License := "GPL-2.0-or-later",
1616

GeneralizedMorphismsForCAP/gap/GeneralizedMorphismCategoryByCospans.gd

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -229,8 +229,8 @@ DeclareAttribute( "GeneralizedMorphismByCospansObject",
229229

230230
#! @Description
231231
#! Lift the <E>exact</E> functor <A>F</A> to a functor <M>A \to B</M>,
232-
#! where <M>A := </M> <C>GeneralizedMorphismCategoryByCospans( AsCapCategory( Source( </C><A>F</A><C> ) ) )</C>
233-
#! and <M>B := </M> <C>GeneralizedMorphismCategoryByCospans( AsCapCategory( Range( </C><A>F</A><C> ) ) )</C>.
232+
#! where <M>A := </M> <C>GeneralizedMorphismCategoryByCospans( SourceOfFunctor( </C><A>F</A><C> ) )</C>
233+
#! and <M>B := </M> <C>GeneralizedMorphismCategoryByCospans( RangeOfFunctor( </C><A>F</A><C> ) )</C>.
234234
#! @Arguments F, name
235235
DeclareOperation( "AsGeneralizedMorphismByCospan",
236236
[ IsCapFunctor, IsString ] );

GeneralizedMorphismsForCAP/gap/GeneralizedMorphismCategoryByCospans.gi

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -371,8 +371,8 @@ InstallMethod( AsGeneralizedMorphismByCospan,
371371
function( F, name )
372372
local A, B, gmcF;
373373

374-
A := GeneralizedMorphismCategoryByCospans( AsCapCategory( Source( F ) ) : FinalizeCategory := true );
375-
B := GeneralizedMorphismCategoryByCospans( AsCapCategory( Range( F ) ) : FinalizeCategory := true );
374+
A := GeneralizedMorphismCategoryByCospans( SourceOfFunctor( F ) : FinalizeCategory := true );
375+
B := GeneralizedMorphismCategoryByCospans( RangeOfFunctor( F ) : FinalizeCategory := true );
376376

377377
gmcF := CapFunctor( name, A, B );
378378

GradedModulePresentationsForCAP/PackageInfo.g

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -10,7 +10,7 @@ SetPackageInfo( rec(
1010

1111
PackageName := "GradedModulePresentationsForCAP",
1212
Subtitle := "Presentations for graded modules",
13-
Version := "2025.02-01",
13+
Version := "2025.07-01",
1414
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)( ),
1515
License := "GPL-2.0-or-later",
1616

0 commit comments

Comments
 (0)