diff --git a/CartesianCategories/gap/SymmetricCartesianClosedCategoriesDerivedMethods.gi b/CartesianCategories/gap/SymmetricCartesianClosedCategoriesDerivedMethods.gi index 1ffb4763bb..a19ce52e3c 100644 --- a/CartesianCategories/gap/SymmetricCartesianClosedCategoriesDerivedMethods.gi +++ b/CartesianCategories/gap/SymmetricCartesianClosedCategoriesDerivedMethods.gi @@ -859,13 +859,14 @@ end : CategoryFilter := IsCartesianClosedCategory ); ## AddDerivationToCAP( CartesianPostComposeMorphismWithGivenObjects, "CartesianPostComposeMorphismWithGivenObjects using CartesianPreComposeMorphism and braiding", - [ [ CartesianBraiding, 1 ], + [ [ CartesianBraidingWithGivenDirectProducts, 1 ], [ ExponentialOnObjects, 2 ], [ PreCompose, 1 ], - [ CartesianPreComposeMorphism, 1 ] ], + [ DirectProduct, 1], + [ CartesianPreComposeMorphismWithGivenObjects, 1 ] ], function( cat, source, a, b, c, range ) - local braiding; + local exp_ab, exp_bc, exp_ab_x_exp_bc, braiding; # Exp(b,c) × Exp(a,b) # | @@ -877,22 +878,27 @@ AddDerivationToCAP( CartesianPostComposeMorphismWithGivenObjects, # v # Exp(a,c) - braiding := CartesianBraiding( cat, ExponentialOnObjects( cat, b, c ), ExponentialOnObjects( cat, a, b ) ); + exp_ab := ExponentialOnObjects( cat, a, b ); + exp_bc := ExponentialOnObjects( cat, b, c ); + exp_ab_x_exp_bc := BinaryDirectProduct( cat, exp_ab, exp_bc ); + + braiding := CartesianBraidingWithGivenDirectProducts( cat, source, exp_bc, exp_ab, exp_ab_x_exp_bc ); - return PreCompose( cat, braiding, CartesianPreComposeMorphism( cat, a, b, c ) ); + return PreCompose( cat, braiding, CartesianPreComposeMorphismWithGivenObjects( cat, exp_ab_x_exp_bc, a, b, c, range ) ); end : CategoryFilter := IsCartesianClosedCategory ); ## AddDerivationToCAP( CartesianPreComposeMorphismWithGivenObjects, "CartesianPreComposeMorphismWithGivenObjects using CartesianPostComposeMorphism and braiding", - [ [ CartesianBraiding, 1 ], + [ [ CartesianBraidingWithGivenDirectProducts, 1 ], [ ExponentialOnObjects, 2 ], [ PreCompose, 1 ], - [ CartesianPostComposeMorphism, 1 ] ], + [ DirectProduct, 1], + [ CartesianPostComposeMorphismWithGivenObjects, 1 ] ], function( cat, source, a, b, c, range ) - local braiding; + local exp_ab, exp_bc, exp_bc_x_exp_ab, braiding; # Exp(a,b) × Exp(b,c) # | @@ -904,9 +910,13 @@ AddDerivationToCAP( CartesianPreComposeMorphismWithGivenObjects, # v # Exp(a,c) - braiding := CartesianBraiding( cat, ExponentialOnObjects( cat, a, b ), ExponentialOnObjects( cat, b, c ) ); + exp_ab := ExponentialOnObjects( cat, a, b ); + exp_bc := ExponentialOnObjects( cat, b, c ); + exp_bc_x_exp_ab := BinaryDirectProduct( cat, exp_bc, exp_ab ); + + braiding := CartesianBraidingWithGivenDirectProducts( cat, source, exp_bc, exp_ab, exp_bc_x_exp_ab ); - return PreCompose( cat, braiding, CartesianPostComposeMorphism( cat, a, b, c ) ); + return PreCompose( cat, braiding, CartesianPostComposeMorphismWithGivenObjects( cat, exp_bc_x_exp_ab, a, b, c, range ) ); end : CategoryFilter := IsCartesianClosedCategory ); diff --git a/CartesianCategories/gap/SymmetricCocartesianCoclosedCategoriesDerivedMethods.gi b/CartesianCategories/gap/SymmetricCocartesianCoclosedCategoriesDerivedMethods.gi index ea4420b7f6..58b10f2ad4 100644 --- a/CartesianCategories/gap/SymmetricCocartesianCoclosedCategoriesDerivedMethods.gi +++ b/CartesianCategories/gap/SymmetricCocartesianCoclosedCategoriesDerivedMethods.gi @@ -867,13 +867,14 @@ end : CategoryFilter := IsCocartesianCoclosedCategory ); ## AddDerivationToCAP( CocartesianPostCoComposeMorphismWithGivenObjects, "CocartesianPostCoComposeMorphismWithGivenObjects using CocartesianPreCoComposeMorphism and braiding", - [ [ CocartesianBraiding, 1 ], + [ [ CocartesianBraidingWithGivenCoproducts, 1 ], [ CoexponentialOnObjects, 2 ], [ PreCompose, 1 ], - [ CocartesianPreCoComposeMorphism, 1 ] ], + [ Coproduct, 1 ], + [ CocartesianPreCoComposeMorphismWithGivenObjects, 1 ] ], function( cat, source, a, b, c, range ) - local braiding; + local coexp_ab, coexp_bc, coexp_bc_x_coexp_ab, braiding; # Coexp(a,c) # | @@ -885,22 +886,27 @@ AddDerivationToCAP( CocartesianPostCoComposeMorphismWithGivenObjects, # v # Coexp(a,b) ⊔ Coexp(b,c) - braiding := CocartesianBraiding( cat, CoexponentialOnObjects( cat, b, c ), CoexponentialOnObjects( cat, a, b ) ); + coexp_ab := CoexponentialOnObjects( cat, a, b ); + coexp_bc := CoexponentialOnObjects( cat, b, c ); + coexp_bc_x_coexp_ab := BinaryCoproduct( cat, coexp_bc, coexp_ab ); + + braiding := CocartesianBraidingWithGivenCoproducts( cat, coexp_bc_x_coexp_ab, coexp_bc, coexp_ab, range ); - return PreCompose( cat, CocartesianPreCoComposeMorphism( cat, a, b, c ), braiding ); + return PreCompose( cat, CocartesianPreCoComposeMorphismWithGivenObjects( cat, source, a, b, c, coexp_bc_x_coexp_ab ), braiding ); end : CategoryFilter := IsCocartesianCoclosedCategory ); ## AddDerivationToCAP( CocartesianPreCoComposeMorphismWithGivenObjects, "CocartesianPreCoComposeMorphismWithGivenObjects using CocartesianPostCoComposeMorphism and braiding", - [ [ CocartesianBraiding, 1 ], + [ [ CocartesianBraidingWithGivenCoproducts, 1 ], [ CoexponentialOnObjects, 2 ], [ PreCompose, 1 ], - [ CocartesianPostCoComposeMorphism, 1 ] ], + [ Coproduct, 1 ], + [ CocartesianPostCoComposeMorphismWithGivenObjects, 1 ] ], function( cat, source, a, b, c, range ) - local braiding; + local coexp_ab, coexp_bc, coexp_ab_x_coexp_bc, braiding; # Coexp(a,c) # | @@ -911,10 +917,14 @@ AddDerivationToCAP( CocartesianPreCoComposeMorphismWithGivenObjects, # | B_( Coexp(a,b), Coexp(b,c) ) # v # Coexp(b,c) ⊔ Coexp(a,b) - - braiding := CocartesianBraiding( cat, CoexponentialOnObjects( cat, a, b ), CoexponentialOnObjects( cat, b, c ) ); - return PreCompose( cat, CocartesianPostCoComposeMorphism( cat, a, b, c ), braiding ); + coexp_ab := CoexponentialOnObjects( cat, a, b ); + coexp_bc := CoexponentialOnObjects( cat, b, c ); + coexp_ab_x_coexp_bc := BinaryCoproduct( cat, coexp_ab, coexp_bc ); + + braiding := CocartesianBraidingWithGivenCoproducts( cat, coexp_ab_x_coexp_bc, coexp_ab, coexp_bc, range ); + + return PreCompose( cat, CocartesianPostCoComposeMorphismWithGivenObjects( cat, source, a, b, c, coexp_ab_x_coexp_bc ), braiding ); end : CategoryFilter := IsCocartesianCoclosedCategory ); diff --git a/LinearAlgebraForCAP/gap/precompiled_categories/MatrixCategoryPrecompiled.gi b/LinearAlgebraForCAP/gap/precompiled_categories/MatrixCategoryPrecompiled.gi index fdf7af5bb6..af1cf57791 100644 --- a/LinearAlgebraForCAP/gap/precompiled_categories/MatrixCategoryPrecompiled.gi +++ b/LinearAlgebraForCAP/gap/precompiled_categories/MatrixCategoryPrecompiled.gi @@ -3767,206 +3767,182 @@ end ######## function ( cat_1, a_1, b_1, c_1 ) - local morphism_attr_1_1, deduped_7_1, deduped_8_1, deduped_9_1, deduped_10_1, deduped_11_1, deduped_12_1, deduped_13_1, deduped_14_1, deduped_15_1, deduped_16_1, deduped_17_1, deduped_18_1, deduped_19_1, deduped_20_1; - deduped_20_1 := Dimension( b_1 ); - deduped_19_1 := Dimension( a_1 ); - deduped_18_1 := UnderlyingRing( cat_1 ); - deduped_17_1 := Dimension( c_1 ); - deduped_16_1 := deduped_17_1 * deduped_17_1; - deduped_15_1 := deduped_20_1 * deduped_17_1; - deduped_14_1 := deduped_19_1 * deduped_20_1; - deduped_13_1 := HomalgIdentityMatrix( deduped_20_1, deduped_18_1 ); - deduped_12_1 := HomalgIdentityMatrix( deduped_17_1, deduped_18_1 ); - deduped_11_1 := deduped_15_1 * deduped_14_1; - deduped_10_1 := deduped_17_1 * deduped_14_1; - deduped_9_1 := deduped_14_1 * deduped_20_1; - deduped_8_1 := HomalgIdentityMatrix( deduped_11_1, deduped_18_1 ); - deduped_7_1 := deduped_11_1 * deduped_17_1; - morphism_attr_1_1 := KroneckerMat( TransposedMatrix( deduped_12_1 ), KroneckerMat( HomalgIdentityMatrix( deduped_19_1, deduped_18_1 ), ConvertMatrixToRow( deduped_13_1 ) ) * KroneckerMat( HomalgMatrix( PermutationMat( PermList( List( [ 1 .. deduped_14_1 ], function ( i_2 ) + local morphism_attr_1_1, deduped_8_1, deduped_9_1, deduped_10_1, deduped_11_1, deduped_12_1, deduped_13_1, deduped_14_1, deduped_15_1, deduped_16_1, deduped_17_1, deduped_18_1, deduped_19_1; + deduped_19_1 := Dimension( b_1 ); + deduped_18_1 := Dimension( a_1 ); + deduped_17_1 := UnderlyingRing( cat_1 ); + deduped_16_1 := Dimension( c_1 ); + deduped_15_1 := deduped_16_1 * deduped_16_1; + deduped_14_1 := deduped_19_1 * deduped_16_1; + deduped_13_1 := deduped_18_1 * deduped_19_1; + deduped_12_1 := HomalgIdentityMatrix( deduped_19_1, deduped_17_1 ); + deduped_11_1 := HomalgIdentityMatrix( deduped_16_1, deduped_17_1 ); + deduped_10_1 := deduped_13_1 * deduped_14_1; + deduped_9_1 := HomalgIdentityMatrix( deduped_10_1, deduped_17_1 ); + deduped_8_1 := deduped_10_1 * deduped_16_1; + morphism_attr_1_1 := KroneckerMat( TransposedMatrix( deduped_11_1 ), KroneckerMat( HomalgIdentityMatrix( deduped_18_1, deduped_17_1 ), ConvertMatrixToRow( deduped_12_1 ) ) * KroneckerMat( HomalgMatrix( PermutationMat( PermList( List( [ 1 .. deduped_13_1 ], function ( i_2 ) + local deduped_1_2; + deduped_1_2 := (i_2 - 1); + return (REM_INT( deduped_1_2, deduped_19_1 ) * deduped_18_1 + QUO_INT( deduped_1_2, deduped_19_1 ) + 1); + end ) ), deduped_13_1 ), deduped_13_1, deduped_13_1, deduped_17_1 ), deduped_12_1 ) * KroneckerMat( HomalgIdentityMatrix( (deduped_19_1 * deduped_18_1), deduped_17_1 ), deduped_12_1 ) * KroneckerMat( HomalgIdentityMatrix( deduped_13_1, deduped_17_1 ), (KroneckerMat( deduped_12_1, ConvertMatrixToRow( deduped_11_1 ) ) * KroneckerMat( HomalgMatrix( PermutationMat( PermList( List( [ 1 .. deduped_14_1 ], function ( i_2 ) local deduped_1_2; deduped_1_2 := (i_2 - 1); - return (REM_INT( deduped_1_2, deduped_20_1 ) * deduped_19_1 + QUO_INT( deduped_1_2, deduped_20_1 ) + 1); - end ) ), deduped_14_1 ), deduped_14_1, deduped_14_1, deduped_18_1 ), deduped_13_1 ) * KroneckerMat( HomalgIdentityMatrix( (deduped_20_1 * deduped_19_1), deduped_18_1 ), deduped_13_1 ) * HomalgMatrix( PermutationMat( PermList( List( [ 1 .. deduped_9_1 ], function ( i_2 ) + return (REM_INT( deduped_1_2, deduped_16_1 ) * deduped_19_1 + QUO_INT( deduped_1_2, deduped_16_1 ) + 1); + end ) ), deduped_14_1 ), deduped_14_1, deduped_14_1, deduped_17_1 ), deduped_11_1 ) * KroneckerMat( HomalgIdentityMatrix( (deduped_16_1 * deduped_19_1), deduped_17_1 ), deduped_11_1 )) ) ) * (KroneckerMat( deduped_11_1, HomalgMatrix( PermutationMat( PermList( List( [ 1 .. deduped_8_1 ], function ( i_2 ) local deduped_1_2; deduped_1_2 := (i_2 - 1); - return (REM_INT( deduped_1_2, deduped_20_1 ) * deduped_14_1 + QUO_INT( deduped_1_2, deduped_20_1 ) + 1); - end ) ), deduped_9_1 ), deduped_9_1, deduped_9_1, deduped_18_1 ) * KroneckerMat( (KroneckerMat( deduped_13_1, ConvertMatrixToRow( deduped_12_1 ) ) * KroneckerMat( HomalgMatrix( PermutationMat( PermList( List( [ 1 .. deduped_15_1 ], function ( i_2 ) - local deduped_1_2; - deduped_1_2 := (i_2 - 1); - return (REM_INT( deduped_1_2, deduped_17_1 ) * deduped_20_1 + QUO_INT( deduped_1_2, deduped_17_1 ) + 1); - end ) ), deduped_15_1 ), deduped_15_1, deduped_15_1, deduped_18_1 ), deduped_12_1 ) * KroneckerMat( HomalgIdentityMatrix( (deduped_17_1 * deduped_20_1), deduped_18_1 ), deduped_12_1 )), HomalgIdentityMatrix( deduped_14_1, deduped_18_1 ) ) * KroneckerMat( HomalgIdentityMatrix( deduped_15_1, deduped_18_1 ), HomalgMatrix( PermutationMat( PermList( List( [ 1 .. deduped_10_1 ], function ( i_2 ) - local deduped_1_2; - deduped_1_2 := (i_2 - 1); - return (REM_INT( deduped_1_2, deduped_14_1 ) * deduped_17_1 + QUO_INT( deduped_1_2, deduped_14_1 ) + 1); - end ) ), deduped_10_1 ), deduped_10_1, deduped_10_1, deduped_18_1 ) ) ) * (KroneckerMat( deduped_12_1, HomalgMatrix( PermutationMat( PermList( List( [ 1 .. deduped_7_1 ], function ( i_2 ) - local deduped_1_2; - deduped_1_2 := (i_2 - 1); - return (REM_INT( deduped_1_2, deduped_17_1 ) * deduped_11_1 + QUO_INT( deduped_1_2, deduped_17_1 ) + 1); - end ) ), deduped_7_1 ), deduped_7_1, deduped_7_1, deduped_18_1 ) ) * KroneckerMat( HomalgMatrix( PermutationMat( PermList( List( [ 1 .. deduped_16_1 ], function ( i_2 ) - local deduped_1_2; - deduped_1_2 := (i_2 - 1); - return (REM_INT( deduped_1_2, deduped_17_1 ) * deduped_17_1 + QUO_INT( deduped_1_2, deduped_17_1 ) + 1); - end ) ), deduped_16_1 ), deduped_16_1, deduped_16_1, deduped_18_1 ), deduped_8_1 ) * KroneckerMat( ConvertMatrixToColumn( deduped_12_1 ), deduped_8_1 )); + return (REM_INT( deduped_1_2, deduped_16_1 ) * deduped_10_1 + QUO_INT( deduped_1_2, deduped_16_1 ) + 1); + end ) ), deduped_8_1 ), deduped_8_1, deduped_8_1, deduped_17_1 ) ) * KroneckerMat( HomalgMatrix( PermutationMat( PermList( List( [ 1 .. deduped_15_1 ], function ( i_2 ) + local deduped_1_2; + deduped_1_2 := (i_2 - 1); + return (REM_INT( deduped_1_2, deduped_16_1 ) * deduped_16_1 + QUO_INT( deduped_1_2, deduped_16_1 ) + 1); + end ) ), deduped_15_1 ), deduped_15_1, deduped_15_1, deduped_17_1 ), deduped_9_1 ) * KroneckerMat( ConvertMatrixToColumn( deduped_11_1 ), deduped_9_1 )) * HomalgMatrix( PermutationMat( PermList( List( [ 1 .. deduped_10_1 ], function ( i_2 ) + local deduped_1_2; + deduped_1_2 := (i_2 - 1); + return (REM_INT( deduped_1_2, deduped_14_1 ) * deduped_13_1 + QUO_INT( deduped_1_2, deduped_14_1 ) + 1); + end ) ), deduped_10_1 ), deduped_10_1, deduped_10_1, deduped_17_1 ); return CreateCapCategoryMorphismWithAttributes( cat_1, CreateCapCategoryObjectWithAttributes( cat_1, Dimension, NumberRows( morphism_attr_1_1 ) ), CreateCapCategoryObjectWithAttributes( cat_1, Dimension, NumberColumns( morphism_attr_1_1 ) ), UnderlyingMatrix, morphism_attr_1_1 ); end ######## - , 14358 : IsPrecompiledDerivation := true ); + , 14158 : IsPrecompiledDerivation := true ); ## AddMonoidalPreCoComposeMorphismWithGivenObjects( cat, ######## function ( cat_1, s_1, a_1, b_1, c_1, r_1 ) - local deduped_6_1, deduped_7_1, deduped_8_1, deduped_9_1, deduped_10_1, deduped_11_1, deduped_12_1, deduped_13_1, deduped_14_1, deduped_15_1, deduped_16_1, deduped_17_1, deduped_18_1, deduped_19_1; - deduped_19_1 := Dimension( r_1 ); + local deduped_7_1, deduped_8_1, deduped_9_1, deduped_10_1, deduped_11_1, deduped_12_1, deduped_13_1, deduped_14_1, deduped_15_1, deduped_16_1, deduped_17_1, deduped_18_1; deduped_18_1 := Dimension( b_1 ); deduped_17_1 := Dimension( a_1 ); deduped_16_1 := UnderlyingRing( cat_1 ); deduped_15_1 := Dimension( c_1 ); - deduped_14_1 := HomalgIdentityMatrix( deduped_19_1, deduped_16_1 ); - deduped_13_1 := deduped_15_1 * deduped_15_1; - deduped_12_1 := deduped_19_1 * deduped_15_1; - deduped_11_1 := deduped_18_1 * deduped_15_1; - deduped_10_1 := deduped_17_1 * deduped_18_1; - deduped_9_1 := HomalgIdentityMatrix( deduped_18_1, deduped_16_1 ); - deduped_8_1 := HomalgIdentityMatrix( deduped_15_1, deduped_16_1 ); - deduped_7_1 := deduped_15_1 * deduped_10_1; - deduped_6_1 := deduped_10_1 * deduped_18_1; - return CreateCapCategoryMorphismWithAttributes( cat_1, s_1, r_1, UnderlyingMatrix, KroneckerMat( TransposedMatrix( deduped_8_1 ), KroneckerMat( HomalgIdentityMatrix( deduped_17_1, deduped_16_1 ), ConvertMatrixToRow( deduped_9_1 ) ) * KroneckerMat( HomalgMatrix( PermutationMat( PermList( List( [ 1 .. deduped_10_1 ], function ( i_2 ) + deduped_14_1 := deduped_15_1 * deduped_15_1; + deduped_13_1 := deduped_18_1 * deduped_15_1; + deduped_12_1 := deduped_17_1 * deduped_18_1; + deduped_11_1 := HomalgIdentityMatrix( deduped_18_1, deduped_16_1 ); + deduped_10_1 := HomalgIdentityMatrix( deduped_15_1, deduped_16_1 ); + deduped_9_1 := deduped_12_1 * deduped_13_1; + deduped_8_1 := HomalgIdentityMatrix( deduped_9_1, deduped_16_1 ); + deduped_7_1 := deduped_9_1 * deduped_15_1; + return CreateCapCategoryMorphismWithAttributes( cat_1, s_1, r_1, UnderlyingMatrix, KroneckerMat( TransposedMatrix( deduped_10_1 ), KroneckerMat( HomalgIdentityMatrix( deduped_17_1, deduped_16_1 ), ConvertMatrixToRow( deduped_11_1 ) ) * KroneckerMat( HomalgMatrix( PermutationMat( PermList( List( [ 1 .. deduped_12_1 ], function ( i_2 ) + local deduped_1_2; + deduped_1_2 := (i_2 - 1); + return (REM_INT( deduped_1_2, deduped_18_1 ) * deduped_17_1 + QUO_INT( deduped_1_2, deduped_18_1 ) + 1); + end ) ), deduped_12_1 ), deduped_12_1, deduped_12_1, deduped_16_1 ), deduped_11_1 ) * KroneckerMat( HomalgIdentityMatrix( (deduped_18_1 * deduped_17_1), deduped_16_1 ), deduped_11_1 ) * KroneckerMat( HomalgIdentityMatrix( deduped_12_1, deduped_16_1 ), (KroneckerMat( deduped_11_1, ConvertMatrixToRow( deduped_10_1 ) ) * KroneckerMat( HomalgMatrix( PermutationMat( PermList( List( [ 1 .. deduped_13_1 ], function ( i_2 ) local deduped_1_2; deduped_1_2 := (i_2 - 1); - return (REM_INT( deduped_1_2, deduped_18_1 ) * deduped_17_1 + QUO_INT( deduped_1_2, deduped_18_1 ) + 1); - end ) ), deduped_10_1 ), deduped_10_1, deduped_10_1, deduped_16_1 ), deduped_9_1 ) * KroneckerMat( HomalgIdentityMatrix( (deduped_18_1 * deduped_17_1), deduped_16_1 ), deduped_9_1 ) * HomalgMatrix( PermutationMat( PermList( List( [ 1 .. deduped_6_1 ], function ( i_2 ) + return (REM_INT( deduped_1_2, deduped_15_1 ) * deduped_18_1 + QUO_INT( deduped_1_2, deduped_15_1 ) + 1); + end ) ), deduped_13_1 ), deduped_13_1, deduped_13_1, deduped_16_1 ), deduped_10_1 ) * KroneckerMat( HomalgIdentityMatrix( (deduped_15_1 * deduped_18_1), deduped_16_1 ), deduped_10_1 )) ) ) * (KroneckerMat( deduped_10_1, HomalgMatrix( PermutationMat( PermList( List( [ 1 .. deduped_7_1 ], function ( i_2 ) local deduped_1_2; deduped_1_2 := (i_2 - 1); - return (REM_INT( deduped_1_2, deduped_18_1 ) * deduped_10_1 + QUO_INT( deduped_1_2, deduped_18_1 ) + 1); - end ) ), deduped_6_1 ), deduped_6_1, deduped_6_1, deduped_16_1 ) * KroneckerMat( (KroneckerMat( deduped_9_1, ConvertMatrixToRow( deduped_8_1 ) ) * KroneckerMat( HomalgMatrix( PermutationMat( PermList( List( [ 1 .. deduped_11_1 ], function ( i_2 ) - local deduped_1_2; - deduped_1_2 := (i_2 - 1); - return (REM_INT( deduped_1_2, deduped_15_1 ) * deduped_18_1 + QUO_INT( deduped_1_2, deduped_15_1 ) + 1); - end ) ), deduped_11_1 ), deduped_11_1, deduped_11_1, deduped_16_1 ), deduped_8_1 ) * KroneckerMat( HomalgIdentityMatrix( (deduped_15_1 * deduped_18_1), deduped_16_1 ), deduped_8_1 )), HomalgIdentityMatrix( deduped_10_1, deduped_16_1 ) ) * KroneckerMat( HomalgIdentityMatrix( deduped_11_1, deduped_16_1 ), HomalgMatrix( PermutationMat( PermList( List( [ 1 .. deduped_7_1 ], function ( i_2 ) - local deduped_1_2; - deduped_1_2 := (i_2 - 1); - return (REM_INT( deduped_1_2, deduped_10_1 ) * deduped_15_1 + QUO_INT( deduped_1_2, deduped_10_1 ) + 1); - end ) ), deduped_7_1 ), deduped_7_1, deduped_7_1, deduped_16_1 ) ) ) * (KroneckerMat( deduped_8_1, HomalgMatrix( PermutationMat( PermList( List( [ 1 .. deduped_12_1 ], function ( i_2 ) - local deduped_1_2; - deduped_1_2 := (i_2 - 1); - return (REM_INT( deduped_1_2, deduped_15_1 ) * deduped_19_1 + QUO_INT( deduped_1_2, deduped_15_1 ) + 1); - end ) ), deduped_12_1 ), deduped_12_1, deduped_12_1, deduped_16_1 ) ) * KroneckerMat( HomalgMatrix( PermutationMat( PermList( List( [ 1 .. deduped_13_1 ], function ( i_2 ) - local deduped_1_2; - deduped_1_2 := (i_2 - 1); - return (REM_INT( deduped_1_2, deduped_15_1 ) * deduped_15_1 + QUO_INT( deduped_1_2, deduped_15_1 ) + 1); - end ) ), deduped_13_1 ), deduped_13_1, deduped_13_1, deduped_16_1 ), deduped_14_1 ) * KroneckerMat( ConvertMatrixToColumn( deduped_8_1 ), deduped_14_1 )) ); + return (REM_INT( deduped_1_2, deduped_15_1 ) * deduped_9_1 + QUO_INT( deduped_1_2, deduped_15_1 ) + 1); + end ) ), deduped_7_1 ), deduped_7_1, deduped_7_1, deduped_16_1 ) ) * KroneckerMat( HomalgMatrix( PermutationMat( PermList( List( [ 1 .. deduped_14_1 ], function ( i_2 ) + local deduped_1_2; + deduped_1_2 := (i_2 - 1); + return (REM_INT( deduped_1_2, deduped_15_1 ) * deduped_15_1 + QUO_INT( deduped_1_2, deduped_15_1 ) + 1); + end ) ), deduped_14_1 ), deduped_14_1, deduped_14_1, deduped_16_1 ), deduped_8_1 ) * KroneckerMat( ConvertMatrixToColumn( deduped_10_1 ), deduped_8_1 )) * HomalgMatrix( PermutationMat( PermList( List( [ 1 .. deduped_9_1 ], function ( i_2 ) + local deduped_1_2; + deduped_1_2 := (i_2 - 1); + return (REM_INT( deduped_1_2, deduped_13_1 ) * deduped_12_1 + QUO_INT( deduped_1_2, deduped_13_1 ) + 1); + end ) ), deduped_9_1 ), deduped_9_1, deduped_9_1, deduped_16_1 ) ); end ######## - , 13351 : IsPrecompiledDerivation := true ); + , 13151 : IsPrecompiledDerivation := true ); ## AddMonoidalPreComposeMorphism( cat, ######## function ( cat_1, a_1, b_1, c_1 ) - local morphism_attr_1_1, deduped_7_1, deduped_8_1, deduped_9_1, deduped_10_1, deduped_11_1, deduped_12_1, deduped_13_1, deduped_14_1, deduped_15_1, deduped_16_1, deduped_17_1, deduped_18_1, deduped_19_1, deduped_20_1, deduped_21_1, deduped_22_1; - deduped_22_1 := Dimension( c_1 ); - deduped_21_1 := Dimension( b_1 ); - deduped_20_1 := UnderlyingRing( cat_1 ); - deduped_19_1 := Dimension( a_1 ); - deduped_18_1 := HomalgIdentityMatrix( deduped_21_1, deduped_20_1 ); - deduped_17_1 := deduped_19_1 * deduped_19_1; - deduped_16_1 := deduped_21_1 * deduped_22_1; - deduped_15_1 := deduped_19_1 * deduped_21_1; - deduped_14_1 := HomalgIdentityMatrix( deduped_19_1, deduped_20_1 ); - deduped_13_1 := deduped_21_1 * deduped_16_1; - deduped_12_1 := HomalgIdentityMatrix( deduped_16_1, deduped_20_1 ); - deduped_11_1 := deduped_16_1 * deduped_19_1; - deduped_10_1 := HomalgIdentityMatrix( deduped_15_1, deduped_20_1 ); - deduped_9_1 := deduped_15_1 * deduped_16_1; - deduped_8_1 := deduped_19_1 * deduped_9_1; - deduped_7_1 := HomalgIdentityMatrix( deduped_9_1, deduped_20_1 ); - morphism_attr_1_1 := KroneckerMat( ConvertMatrixToRow( deduped_14_1 ), deduped_7_1 ) * KroneckerMat( HomalgMatrix( PermutationMat( PermList( List( [ 1 .. deduped_17_1 ], function ( i_2 ) - local deduped_1_2; - deduped_1_2 := (i_2 - 1); - return (REM_INT( deduped_1_2, deduped_19_1 ) * deduped_19_1 + QUO_INT( deduped_1_2, deduped_19_1 ) + 1); - end ) ), deduped_17_1 ), deduped_17_1, deduped_17_1, deduped_20_1 ), deduped_7_1 ) * KroneckerMat( deduped_14_1, HomalgMatrix( PermutationMat( PermList( List( [ 1 .. deduped_8_1 ], function ( i_2 ) - local deduped_1_2; - deduped_1_2 := (i_2 - 1); - return (REM_INT( deduped_1_2, deduped_9_1 ) * deduped_19_1 + QUO_INT( deduped_1_2, deduped_9_1 ) + 1); - end ) ), deduped_8_1 ), deduped_8_1, deduped_8_1, deduped_20_1 ) ) * KroneckerMat( TransposedMatrix( deduped_14_1 ), (KroneckerMat( deduped_10_1, HomalgMatrix( PermutationMat( PermList( List( [ 1 .. deduped_11_1 ], function ( i_2 ) - local deduped_1_2; - deduped_1_2 := (i_2 - 1); - return (REM_INT( deduped_1_2, deduped_19_1 ) * deduped_16_1 + QUO_INT( deduped_1_2, deduped_19_1 ) + 1); - end ) ), deduped_11_1 ), deduped_11_1, deduped_11_1, deduped_20_1 ) ) * KroneckerMat( (KroneckerMat( deduped_10_1, deduped_14_1 ) * KroneckerMat( HomalgMatrix( PermutationMat( PermList( List( [ 1 .. deduped_15_1 ], function ( i_2 ) - local deduped_1_2; - deduped_1_2 := (i_2 - 1); - return (REM_INT( deduped_1_2, deduped_21_1 ) * deduped_19_1 + QUO_INT( deduped_1_2, deduped_21_1 ) + 1); - end ) ), deduped_15_1 ), deduped_15_1, deduped_15_1, deduped_20_1 ), deduped_14_1 ) * KroneckerMat( deduped_18_1, ConvertMatrixToColumn( deduped_14_1 ) )), deduped_12_1 ) * HomalgMatrix( PermutationMat( PermList( List( [ 1 .. deduped_13_1 ], function ( i_2 ) + local morphism_attr_1_1, deduped_8_1, deduped_9_1, deduped_10_1, deduped_11_1, deduped_12_1, deduped_13_1, deduped_14_1, deduped_15_1, deduped_16_1, deduped_17_1, deduped_18_1, deduped_19_1, deduped_20_1, deduped_21_1; + deduped_21_1 := UnderlyingRing( cat_1 ); + deduped_20_1 := Dimension( c_1 ); + deduped_19_1 := Dimension( b_1 ); + deduped_18_1 := Dimension( a_1 ); + deduped_17_1 := HomalgIdentityMatrix( deduped_19_1, deduped_21_1 ); + deduped_16_1 := deduped_18_1 * deduped_18_1; + deduped_15_1 := HomalgIdentityMatrix( deduped_18_1, deduped_21_1 ); + deduped_14_1 := deduped_19_1 * deduped_20_1; + deduped_13_1 := deduped_18_1 * deduped_19_1; + deduped_12_1 := HomalgIdentityMatrix( deduped_14_1, deduped_21_1 ); + deduped_11_1 := deduped_14_1 * deduped_13_1; + deduped_10_1 := deduped_13_1 * deduped_14_1; + deduped_9_1 := deduped_18_1 * deduped_11_1; + deduped_8_1 := HomalgIdentityMatrix( deduped_11_1, deduped_21_1 ); + morphism_attr_1_1 := HomalgMatrix( PermutationMat( PermList( List( [ 1 .. deduped_10_1 ], function ( i_2 ) + local deduped_1_2; + deduped_1_2 := (i_2 - 1); + return (REM_INT( deduped_1_2, deduped_13_1 ) * deduped_14_1 + QUO_INT( deduped_1_2, deduped_13_1 ) + 1); + end ) ), deduped_10_1 ), deduped_10_1, deduped_10_1, deduped_21_1 ) * (KroneckerMat( ConvertMatrixToRow( deduped_15_1 ), deduped_8_1 ) * KroneckerMat( HomalgMatrix( PermutationMat( PermList( List( [ 1 .. deduped_16_1 ], function ( i_2 ) + local deduped_1_2; + deduped_1_2 := (i_2 - 1); + return (REM_INT( deduped_1_2, deduped_18_1 ) * deduped_18_1 + QUO_INT( deduped_1_2, deduped_18_1 ) + 1); + end ) ), deduped_16_1 ), deduped_16_1, deduped_16_1, deduped_21_1 ), deduped_8_1 ) * KroneckerMat( deduped_15_1, HomalgMatrix( PermutationMat( PermList( List( [ 1 .. deduped_9_1 ], function ( i_2 ) local deduped_1_2; deduped_1_2 := (i_2 - 1); - return (REM_INT( deduped_1_2, deduped_16_1 ) * deduped_21_1 + QUO_INT( deduped_1_2, deduped_16_1 ) + 1); - end ) ), deduped_13_1 ), deduped_13_1, deduped_13_1, deduped_20_1 ) * (KroneckerMat( deduped_12_1, deduped_18_1 ) * KroneckerMat( HomalgMatrix( PermutationMat( PermList( List( [ 1 .. deduped_16_1 ], function ( i_2 ) - local deduped_1_2; - deduped_1_2 := (i_2 - 1); - return (REM_INT( deduped_1_2, deduped_22_1 ) * deduped_21_1 + QUO_INT( deduped_1_2, deduped_22_1 ) + 1); - end ) ), deduped_16_1 ), deduped_16_1, deduped_16_1, deduped_20_1 ), deduped_18_1 ) * KroneckerMat( HomalgIdentityMatrix( deduped_22_1, deduped_20_1 ), ConvertMatrixToColumn( deduped_18_1 ) ))) ); + return (REM_INT( deduped_1_2, deduped_11_1 ) * deduped_18_1 + QUO_INT( deduped_1_2, deduped_11_1 ) + 1); + end ) ), deduped_9_1 ), deduped_9_1, deduped_9_1, deduped_21_1 ) ) * KroneckerMat( TransposedMatrix( deduped_15_1 ), (KroneckerMat( deduped_12_1, KroneckerMat( HomalgIdentityMatrix( deduped_13_1, deduped_21_1 ), deduped_15_1 ) * KroneckerMat( HomalgMatrix( PermutationMat( PermList( List( [ 1 .. deduped_13_1 ], function ( i_2 ) + local deduped_1_2; + deduped_1_2 := (i_2 - 1); + return (REM_INT( deduped_1_2, deduped_19_1 ) * deduped_18_1 + QUO_INT( deduped_1_2, deduped_19_1 ) + 1); + end ) ), deduped_13_1 ), deduped_13_1, deduped_13_1, deduped_21_1 ), deduped_15_1 ) * KroneckerMat( deduped_17_1, ConvertMatrixToColumn( deduped_15_1 ) ) ) * (KroneckerMat( deduped_12_1, deduped_17_1 ) * KroneckerMat( HomalgMatrix( PermutationMat( PermList( List( [ 1 .. deduped_14_1 ], function ( i_2 ) + local deduped_1_2; + deduped_1_2 := (i_2 - 1); + return (REM_INT( deduped_1_2, deduped_20_1 ) * deduped_19_1 + QUO_INT( deduped_1_2, deduped_20_1 ) + 1); + end ) ), deduped_14_1 ), deduped_14_1, deduped_14_1, deduped_21_1 ), deduped_17_1 ) * KroneckerMat( HomalgIdentityMatrix( deduped_20_1, deduped_21_1 ), ConvertMatrixToColumn( deduped_17_1 ) ))) )); return CreateCapCategoryMorphismWithAttributes( cat_1, CreateCapCategoryObjectWithAttributes( cat_1, Dimension, NumberRows( morphism_attr_1_1 ) ), CreateCapCategoryObjectWithAttributes( cat_1, Dimension, NumberColumns( morphism_attr_1_1 ) ), UnderlyingMatrix, morphism_attr_1_1 ); end ######## - , 14358 : IsPrecompiledDerivation := true ); + , 14158 : IsPrecompiledDerivation := true ); ## AddMonoidalPreComposeMorphismWithGivenObjects( cat, ######## function ( cat_1, s_1, a_1, b_1, c_1, r_1 ) - local deduped_6_1, deduped_7_1, deduped_8_1, deduped_9_1, deduped_10_1, deduped_11_1, deduped_12_1, deduped_13_1, deduped_14_1, deduped_15_1, deduped_16_1, deduped_17_1, deduped_18_1, deduped_19_1, deduped_20_1, deduped_21_1; - deduped_21_1 := Dimension( c_1 ); - deduped_20_1 := Dimension( b_1 ); - deduped_19_1 := Dimension( s_1 ); - deduped_18_1 := UnderlyingRing( cat_1 ); - deduped_17_1 := Dimension( a_1 ); - deduped_16_1 := HomalgIdentityMatrix( deduped_20_1, deduped_18_1 ); - deduped_15_1 := deduped_20_1 * deduped_21_1; - deduped_14_1 := deduped_17_1 * deduped_20_1; - deduped_13_1 := deduped_17_1 * deduped_19_1; - deduped_12_1 := deduped_17_1 * deduped_17_1; - deduped_11_1 := HomalgIdentityMatrix( deduped_19_1, deduped_18_1 ); - deduped_10_1 := HomalgIdentityMatrix( deduped_17_1, deduped_18_1 ); - deduped_9_1 := deduped_20_1 * deduped_15_1; - deduped_8_1 := HomalgIdentityMatrix( deduped_15_1, deduped_18_1 ); - deduped_7_1 := deduped_15_1 * deduped_17_1; - deduped_6_1 := HomalgIdentityMatrix( deduped_14_1, deduped_18_1 ); - return CreateCapCategoryMorphismWithAttributes( cat_1, s_1, r_1, UnderlyingMatrix, KroneckerMat( ConvertMatrixToRow( deduped_10_1 ), deduped_11_1 ) * KroneckerMat( HomalgMatrix( PermutationMat( PermList( List( [ 1 .. deduped_12_1 ], function ( i_2 ) - local deduped_1_2; - deduped_1_2 := (i_2 - 1); - return (REM_INT( deduped_1_2, deduped_17_1 ) * deduped_17_1 + QUO_INT( deduped_1_2, deduped_17_1 ) + 1); - end ) ), deduped_12_1 ), deduped_12_1, deduped_12_1, deduped_18_1 ), deduped_11_1 ) * KroneckerMat( deduped_10_1, HomalgMatrix( PermutationMat( PermList( List( [ 1 .. deduped_13_1 ], function ( i_2 ) - local deduped_1_2; - deduped_1_2 := (i_2 - 1); - return (REM_INT( deduped_1_2, deduped_19_1 ) * deduped_17_1 + QUO_INT( deduped_1_2, deduped_19_1 ) + 1); - end ) ), deduped_13_1 ), deduped_13_1, deduped_13_1, deduped_18_1 ) ) * KroneckerMat( TransposedMatrix( deduped_10_1 ), (KroneckerMat( deduped_6_1, HomalgMatrix( PermutationMat( PermList( List( [ 1 .. deduped_7_1 ], function ( i_2 ) - local deduped_1_2; - deduped_1_2 := (i_2 - 1); - return (REM_INT( deduped_1_2, deduped_17_1 ) * deduped_15_1 + QUO_INT( deduped_1_2, deduped_17_1 ) + 1); - end ) ), deduped_7_1 ), deduped_7_1, deduped_7_1, deduped_18_1 ) ) * KroneckerMat( (KroneckerMat( deduped_6_1, deduped_10_1 ) * KroneckerMat( HomalgMatrix( PermutationMat( PermList( List( [ 1 .. deduped_14_1 ], function ( i_2 ) - local deduped_1_2; - deduped_1_2 := (i_2 - 1); - return (REM_INT( deduped_1_2, deduped_20_1 ) * deduped_17_1 + QUO_INT( deduped_1_2, deduped_20_1 ) + 1); - end ) ), deduped_14_1 ), deduped_14_1, deduped_14_1, deduped_18_1 ), deduped_10_1 ) * KroneckerMat( deduped_16_1, ConvertMatrixToColumn( deduped_10_1 ) )), deduped_8_1 ) * HomalgMatrix( PermutationMat( PermList( List( [ 1 .. deduped_9_1 ], function ( i_2 ) + local deduped_7_1, deduped_8_1, deduped_9_1, deduped_10_1, deduped_11_1, deduped_12_1, deduped_13_1, deduped_14_1, deduped_15_1, deduped_16_1, deduped_17_1, deduped_18_1, deduped_19_1, deduped_20_1; + deduped_20_1 := Dimension( c_1 ); + deduped_19_1 := Dimension( b_1 ); + deduped_18_1 := Dimension( a_1 ); + deduped_17_1 := UnderlyingRing( cat_1 ); + deduped_16_1 := Dimension( s_1 ); + deduped_15_1 := HomalgIdentityMatrix( deduped_19_1, deduped_17_1 ); + deduped_14_1 := deduped_18_1 * deduped_18_1; + deduped_13_1 := deduped_18_1 * deduped_19_1; + deduped_12_1 := deduped_19_1 * deduped_20_1; + deduped_11_1 := HomalgIdentityMatrix( deduped_18_1, deduped_17_1 ); + deduped_10_1 := HomalgIdentityMatrix( deduped_12_1, deduped_17_1 ); + deduped_9_1 := deduped_12_1 * deduped_13_1; + deduped_8_1 := deduped_18_1 * deduped_9_1; + deduped_7_1 := HomalgIdentityMatrix( deduped_9_1, deduped_17_1 ); + return CreateCapCategoryMorphismWithAttributes( cat_1, s_1, r_1, UnderlyingMatrix, HomalgMatrix( PermutationMat( PermList( List( [ 1 .. deduped_16_1 ], function ( i_2 ) + local deduped_1_2; + deduped_1_2 := (i_2 - 1); + return (REM_INT( deduped_1_2, deduped_13_1 ) * deduped_12_1 + QUO_INT( deduped_1_2, deduped_13_1 ) + 1); + end ) ), deduped_16_1 ), deduped_16_1, deduped_16_1, deduped_17_1 ) * (KroneckerMat( ConvertMatrixToRow( deduped_11_1 ), deduped_7_1 ) * KroneckerMat( HomalgMatrix( PermutationMat( PermList( List( [ 1 .. deduped_14_1 ], function ( i_2 ) + local deduped_1_2; + deduped_1_2 := (i_2 - 1); + return (REM_INT( deduped_1_2, deduped_18_1 ) * deduped_18_1 + QUO_INT( deduped_1_2, deduped_18_1 ) + 1); + end ) ), deduped_14_1 ), deduped_14_1, deduped_14_1, deduped_17_1 ), deduped_7_1 ) * KroneckerMat( deduped_11_1, HomalgMatrix( PermutationMat( PermList( List( [ 1 .. deduped_8_1 ], function ( i_2 ) local deduped_1_2; deduped_1_2 := (i_2 - 1); - return (REM_INT( deduped_1_2, deduped_15_1 ) * deduped_20_1 + QUO_INT( deduped_1_2, deduped_15_1 ) + 1); - end ) ), deduped_9_1 ), deduped_9_1, deduped_9_1, deduped_18_1 ) * (KroneckerMat( deduped_8_1, deduped_16_1 ) * KroneckerMat( HomalgMatrix( PermutationMat( PermList( List( [ 1 .. deduped_15_1 ], function ( i_2 ) - local deduped_1_2; - deduped_1_2 := (i_2 - 1); - return (REM_INT( deduped_1_2, deduped_21_1 ) * deduped_20_1 + QUO_INT( deduped_1_2, deduped_21_1 ) + 1); - end ) ), deduped_15_1 ), deduped_15_1, deduped_15_1, deduped_18_1 ), deduped_16_1 ) * KroneckerMat( HomalgIdentityMatrix( deduped_21_1, deduped_18_1 ), ConvertMatrixToColumn( deduped_16_1 ) ))) ) ); + return (REM_INT( deduped_1_2, deduped_9_1 ) * deduped_18_1 + QUO_INT( deduped_1_2, deduped_9_1 ) + 1); + end ) ), deduped_8_1 ), deduped_8_1, deduped_8_1, deduped_17_1 ) ) * KroneckerMat( TransposedMatrix( deduped_11_1 ), (KroneckerMat( deduped_10_1, KroneckerMat( HomalgIdentityMatrix( deduped_13_1, deduped_17_1 ), deduped_11_1 ) * KroneckerMat( HomalgMatrix( PermutationMat( PermList( List( [ 1 .. deduped_13_1 ], function ( i_2 ) + local deduped_1_2; + deduped_1_2 := (i_2 - 1); + return (REM_INT( deduped_1_2, deduped_19_1 ) * deduped_18_1 + QUO_INT( deduped_1_2, deduped_19_1 ) + 1); + end ) ), deduped_13_1 ), deduped_13_1, deduped_13_1, deduped_17_1 ), deduped_11_1 ) * KroneckerMat( deduped_15_1, ConvertMatrixToColumn( deduped_11_1 ) ) ) * (KroneckerMat( deduped_10_1, deduped_15_1 ) * KroneckerMat( HomalgMatrix( PermutationMat( PermList( List( [ 1 .. deduped_12_1 ], function ( i_2 ) + local deduped_1_2; + deduped_1_2 := (i_2 - 1); + return (REM_INT( deduped_1_2, deduped_20_1 ) * deduped_19_1 + QUO_INT( deduped_1_2, deduped_20_1 ) + 1); + end ) ), deduped_12_1 ), deduped_12_1, deduped_12_1, deduped_17_1 ), deduped_15_1 ) * KroneckerMat( HomalgIdentityMatrix( deduped_20_1, deduped_17_1 ), ConvertMatrixToColumn( deduped_15_1 ) ))) )) ); end ######## - , 13351 : IsPrecompiledDerivation := true ); + , 13151 : IsPrecompiledDerivation := true ); ## AddMonomorphismIntoSomeInjectiveObject( cat, diff --git a/MonoidalCategories/gap/SymmetricClosedMonoidalCategoriesDerivedMethods.gi b/MonoidalCategories/gap/SymmetricClosedMonoidalCategoriesDerivedMethods.gi index fa1467f7ed..f0fa9b8b6b 100644 --- a/MonoidalCategories/gap/SymmetricClosedMonoidalCategoriesDerivedMethods.gi +++ b/MonoidalCategories/gap/SymmetricClosedMonoidalCategoriesDerivedMethods.gi @@ -856,13 +856,14 @@ end : CategoryFilter := IsSymmetricClosedMonoidalCategory ); ## AddDerivationToCAP( MonoidalPostComposeMorphismWithGivenObjects, "MonoidalPostComposeMorphismWithGivenObjects using MonoidalPreComposeMorphism and braiding", - [ [ Braiding, 1 ], + [ [ BraidingWithGivenTensorProducts, 1 ], [ InternalHomOnObjects, 2 ], [ PreCompose, 1 ], - [ MonoidalPreComposeMorphism, 1 ] ], + [ TensorProductOnObjects, 1], + [ MonoidalPreComposeMorphismWithGivenObjects, 1 ] ], function( cat, source, a, b, c, range ) - local braiding; + local hom_ab, hom_bc, hom_ab_x_hom_bc, braiding; # Hom(b,c) ⊗ Hom(a,b) # | @@ -874,22 +875,27 @@ AddDerivationToCAP( MonoidalPostComposeMorphismWithGivenObjects, # v # Hom(a,c) - braiding := Braiding( cat, InternalHomOnObjects( cat, b, c ), InternalHomOnObjects( cat, a, b ) ); + hom_ab := InternalHomOnObjects( cat, a, b ); + hom_bc := InternalHomOnObjects( cat, b, c ); + hom_ab_x_hom_bc := TensorProductOnObjects( cat, hom_ab, hom_bc ); + + braiding := BraidingWithGivenTensorProducts( cat, source, hom_bc, hom_ab, hom_ab_x_hom_bc ); - return PreCompose( cat, braiding, MonoidalPreComposeMorphism( cat, a, b, c ) ); + return PreCompose( cat, braiding, MonoidalPreComposeMorphismWithGivenObjects( cat, hom_ab_x_hom_bc, a, b, c, range ) ); end : CategoryFilter := IsSymmetricClosedMonoidalCategory ); ## AddDerivationToCAP( MonoidalPreComposeMorphismWithGivenObjects, "MonoidalPreComposeMorphismWithGivenObjects using MonoidalPostComposeMorphism and braiding", - [ [ Braiding, 1 ], + [ [ BraidingWithGivenTensorProducts, 1 ], [ InternalHomOnObjects, 2 ], [ PreCompose, 1 ], - [ MonoidalPostComposeMorphism, 1 ] ], + [ TensorProductOnObjects, 1], + [ MonoidalPostComposeMorphismWithGivenObjects, 1 ] ], function( cat, source, a, b, c, range ) - local braiding; + local hom_ab, hom_bc, hom_bc_x_hom_ab, braiding; # Hom(a,b) ⊗ Hom(b,c) # | @@ -901,9 +907,13 @@ AddDerivationToCAP( MonoidalPreComposeMorphismWithGivenObjects, # v # Hom(a,c) - braiding := Braiding( cat, InternalHomOnObjects( cat, a, b ), InternalHomOnObjects( cat, b, c ) ); + hom_ab := InternalHomOnObjects( cat, a, b ); + hom_bc := InternalHomOnObjects( cat, b, c ); + hom_bc_x_hom_ab := TensorProductOnObjects( cat, hom_bc, hom_ab ); + + braiding := BraidingWithGivenTensorProducts( cat, source, hom_bc, hom_ab, hom_bc_x_hom_ab ); - return PreCompose( cat, braiding, MonoidalPostComposeMorphism( cat, a, b, c ) ); + return PreCompose( cat, braiding, MonoidalPostComposeMorphismWithGivenObjects( cat, hom_bc_x_hom_ab, a, b, c, range ) ); end : CategoryFilter := IsSymmetricClosedMonoidalCategory ); diff --git a/MonoidalCategories/gap/SymmetricCoclosedMonoidalCategoriesDerivedMethods.gi b/MonoidalCategories/gap/SymmetricCoclosedMonoidalCategoriesDerivedMethods.gi index 4fef46c799..ce6a3369aa 100644 --- a/MonoidalCategories/gap/SymmetricCoclosedMonoidalCategoriesDerivedMethods.gi +++ b/MonoidalCategories/gap/SymmetricCoclosedMonoidalCategoriesDerivedMethods.gi @@ -864,13 +864,14 @@ end : CategoryFilter := IsSymmetricCoclosedMonoidalCategory ); ## AddDerivationToCAP( MonoidalPostCoComposeMorphismWithGivenObjects, "MonoidalPostCoComposeMorphismWithGivenObjects using MonoidalPreCoComposeMorphism and braiding", - [ [ Braiding, 1 ], + [ [ BraidingWithGivenTensorProducts, 1 ], [ InternalCoHomOnObjects, 2 ], [ PreCompose, 1 ], - [ MonoidalPreCoComposeMorphism, 1 ] ], + [ TensorProductOnObjects, 1 ], + [ MonoidalPreCoComposeMorphismWithGivenObjects, 1 ] ], function( cat, source, a, b, c, range ) - local braiding; + local cohom_ab, cohom_bc, cohom_bc_x_cohom_ab, braiding; # Cohom(a,c) # | @@ -882,22 +883,27 @@ AddDerivationToCAP( MonoidalPostCoComposeMorphismWithGivenObjects, # v # Cohom(a,b) ⊗ Cohom(b,c) - braiding := Braiding( cat, InternalCoHomOnObjects( cat, b, c ), InternalCoHomOnObjects( cat, a, b ) ); + cohom_ab := InternalCoHomOnObjects( cat, a, b ); + cohom_bc := InternalCoHomOnObjects( cat, b, c ); + cohom_bc_x_cohom_ab := TensorProductOnObjects( cat, cohom_bc, cohom_ab ); + + braiding := BraidingWithGivenTensorProducts( cat, cohom_bc_x_cohom_ab, cohom_bc, cohom_ab, range ); - return PreCompose( cat, MonoidalPreCoComposeMorphism( cat, a, b, c ), braiding ); + return PreCompose( cat, MonoidalPreCoComposeMorphismWithGivenObjects( cat, source, a, b, c, cohom_bc_x_cohom_ab ), braiding ); end : CategoryFilter := IsSymmetricCoclosedMonoidalCategory ); ## AddDerivationToCAP( MonoidalPreCoComposeMorphismWithGivenObjects, "MonoidalPreCoComposeMorphismWithGivenObjects using MonoidalPostCoComposeMorphism and braiding", - [ [ Braiding, 1 ], + [ [ BraidingWithGivenTensorProducts, 1 ], [ InternalCoHomOnObjects, 2 ], [ PreCompose, 1 ], - [ MonoidalPostCoComposeMorphism, 1 ] ], + [ TensorProductOnObjects, 1 ], + [ MonoidalPostCoComposeMorphismWithGivenObjects, 1 ] ], function( cat, source, a, b, c, range ) - local braiding; + local cohom_ab, cohom_bc, cohom_ab_x_cohom_bc, braiding; # Cohom(a,c) # | @@ -908,10 +914,14 @@ AddDerivationToCAP( MonoidalPreCoComposeMorphismWithGivenObjects, # | B_( Cohom(a,b), Cohom(b,c) ) # v # Cohom(b,c) ⊗ Cohom(a,b) - - braiding := Braiding( cat, InternalCoHomOnObjects( cat, a, b ), InternalCoHomOnObjects( cat, b, c ) ); - return PreCompose( cat, MonoidalPostCoComposeMorphism( cat, a, b, c ), braiding ); + cohom_ab := InternalCoHomOnObjects( cat, a, b ); + cohom_bc := InternalCoHomOnObjects( cat, b, c ); + cohom_ab_x_cohom_bc := TensorProductOnObjects( cat, cohom_ab, cohom_bc ); + + braiding := BraidingWithGivenTensorProducts( cat, cohom_ab_x_cohom_bc, cohom_ab, cohom_bc, range ); + + return PreCompose( cat, MonoidalPostCoComposeMorphismWithGivenObjects( cat, source, a, b, c, cohom_ab_x_cohom_bc ), braiding ); end : CategoryFilter := IsSymmetricCoclosedMonoidalCategory );