From 3acf03430f955e3206fe23801dec9ecaec241625 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Lars=20G=C3=B6ttgens?= Date: Thu, 14 Sep 2023 11:35:21 +0200 Subject: [PATCH] Adapt doctests to new printing for maps Nemocas/AbstractAlgebra.jl#1424 --- .../src/lattices_with_isometry.jl | 54 ++----------------- .../src/spaces_with_isometry.jl | 54 ++----------------- .../ProjectiveSchemes/Objects/Attributes.jl | 8 +-- .../NormalToricVarieties/attributes.jl | 48 +++-------------- .../ToricMorphisms/attributes.jl | 40 ++------------ .../ToricMorphisms/constructors.jl | 8 +-- src/Rings/MPolyMap/MPolyRing.jl | 10 +--- src/Rings/mpoly-affine-algebras.jl | 20 +++---- 8 files changed, 27 insertions(+), 215 deletions(-) diff --git a/experimental/QuadFormAndIsom/src/lattices_with_isometry.jl b/experimental/QuadFormAndIsom/src/lattices_with_isometry.jl index 6bed32a4e011..bfce40849487 100644 --- a/experimental/QuadFormAndIsom/src/lattices_with_isometry.jl +++ b/experimental/QuadFormAndIsom/src/lattices_with_isometry.jl @@ -1043,19 +1043,7 @@ Integer lattice of rank 5 and degree 5 [0 0 0 1 0] julia> Lh, inj = direct_sum(Lf, Lg) -(Integer lattice with isometry of finite order 10, AbstractSpaceMor[Map with following data -Domain: -======= -Quadratic space of dimension 5 -Codomain: -========= -Quadratic space of dimension 10, Map with following data -Domain: -======= -Quadratic space of dimension 5 -Codomain: -========= -Quadratic space of dimension 10]) +(Integer lattice with isometry of finite order 10, AbstractSpaceMor[Map: quadratic space -> quadratic space, Map: quadratic space -> quadratic space]) julia> Lh Integer lattice of rank 10 and degree 10 @@ -1136,19 +1124,7 @@ Integer lattice of rank 5 and degree 5 [0 0 0 1 0] julia> Lh, proj = direct_product(Lf, Lg) -(Integer lattice with isometry of finite order 10, AbstractSpaceMor[Map with following data -Domain: -======= -Quadratic space of dimension 10 -Codomain: -========= -Quadratic space of dimension 5, Map with following data -Domain: -======= -Quadratic space of dimension 10 -Codomain: -========= -Quadratic space of dimension 5]) +(Integer lattice with isometry of finite order 10, AbstractSpaceMor[Map: quadratic space -> quadratic space, Map: quadratic space -> quadratic space]) julia> Lh Integer lattice of rank 10 and degree 10 @@ -1232,31 +1208,7 @@ Integer lattice of rank 5 and degree 5 [0 0 0 1 0] julia> Lh, inj, proj = biproduct(Lf, Lg) -(Integer lattice with isometry of finite order 10, AbstractSpaceMor[Map with following data -Domain: -======= -Quadratic space of dimension 5 -Codomain: -========= -Quadratic space of dimension 10, Map with following data -Domain: -======= -Quadratic space of dimension 5 -Codomain: -========= -Quadratic space of dimension 10], AbstractSpaceMor[Map with following data -Domain: -======= -Quadratic space of dimension 10 -Codomain: -========= -Quadratic space of dimension 5, Map with following data -Domain: -======= -Quadratic space of dimension 10 -Codomain: -========= -Quadratic space of dimension 5]) +(Integer lattice with isometry of finite order 10, AbstractSpaceMor[Map: quadratic space -> quadratic space, Map: quadratic space -> quadratic space], AbstractSpaceMor[Map: quadratic space -> quadratic space, Map: quadratic space -> quadratic space]) julia> Lh Integer lattice of rank 10 and degree 10 diff --git a/experimental/QuadFormAndIsom/src/spaces_with_isometry.jl b/experimental/QuadFormAndIsom/src/spaces_with_isometry.jl index 6ff1f0bd5051..21428b7138fd 100644 --- a/experimental/QuadFormAndIsom/src/spaces_with_isometry.jl +++ b/experimental/QuadFormAndIsom/src/spaces_with_isometry.jl @@ -510,19 +510,7 @@ Quadratic space of dimension 2 [0 -1] julia> Vf3, inj = direct_sum(Vf1, Vf2) -(Quadratic space with isometry of finite order 2, AbstractSpaceMor[Map with following data -Domain: -======= -Quadratic space of dimension 2 -Codomain: -========= -Quadratic space of dimension 4, Map with following data -Domain: -======= -Quadratic space of dimension 2 -Codomain: -========= -Quadratic space of dimension 4]) +(Quadratic space with isometry of finite order 2, AbstractSpaceMor[Map: quadratic space -> quadratic space, Map: quadratic space -> quadratic space]) julia> Vf3 Quadratic space of dimension 4 @@ -605,19 +593,7 @@ Quadratic space of dimension 2 [0 -1] julia> Vf3, proj = direct_product(Vf1, Vf2) -(Quadratic space with isometry of finite order 2, AbstractSpaceMor[Map with following data -Domain: -======= -Quadratic space of dimension 4 -Codomain: -========= -Quadratic space of dimension 2, Map with following data -Domain: -======= -Quadratic space of dimension 4 -Codomain: -========= -Quadratic space of dimension 2]) +(Quadratic space with isometry of finite order 2, AbstractSpaceMor[Map: quadratic space -> quadratic space, Map: quadratic space -> quadratic space]) julia> Vf3 Quadratic space of dimension 4 @@ -701,31 +677,7 @@ Quadratic space of dimension 2 [0 -1] julia> Vf3, inj, proj = biproduct(Vf1, Vf2) -(Quadratic space with isometry of finite order 2, AbstractSpaceMor[Map with following data -Domain: -======= -Quadratic space of dimension 2 -Codomain: -========= -Quadratic space of dimension 4, Map with following data -Domain: -======= -Quadratic space of dimension 2 -Codomain: -========= -Quadratic space of dimension 4], AbstractSpaceMor[Map with following data -Domain: -======= -Quadratic space of dimension 4 -Codomain: -========= -Quadratic space of dimension 2, Map with following data -Domain: -======= -Quadratic space of dimension 4 -Codomain: -========= -Quadratic space of dimension 2]) +(Quadratic space with isometry of finite order 2, AbstractSpaceMor[Map: quadratic space -> quadratic space, Map: quadratic space -> quadratic space], AbstractSpaceMor[Map: quadratic space -> quadratic space, Map: quadratic space -> quadratic space]) julia> Vf3 Quadratic space of dimension 4 diff --git a/src/AlgebraicGeometry/Schemes/ProjectiveSchemes/Objects/Attributes.jl b/src/AlgebraicGeometry/Schemes/ProjectiveSchemes/Objects/Attributes.jl index 9f361348de7c..1d4c78df0c83 100644 --- a/src/AlgebraicGeometry/Schemes/ProjectiveSchemes/Objects/Attributes.jl +++ b/src/AlgebraicGeometry/Schemes/ProjectiveSchemes/Objects/Attributes.jl @@ -270,13 +270,7 @@ Projective space of dimension 2 with homogeneous coordinates [x, y, z] julia> affine_cone(P) -(Spec of quotient of multivariate polynomial ring, Map with following data -Domain: -======= -S -Codomain: -========= -Quotient of multivariate polynomial ring by ideal with 1 generator) +(Spec of quotient of multivariate polynomial ring, Map: graded multivariate polynomial ring -> quotient of multivariate polynomial ring) ``` """ affine_cone(P::AbsProjectiveScheme) diff --git a/src/AlgebraicGeometry/ToricVarieties/NormalToricVarieties/attributes.jl b/src/AlgebraicGeometry/ToricVarieties/NormalToricVarieties/attributes.jl index 45cadb51dc6a..17eee51b10cf 100644 --- a/src/AlgebraicGeometry/ToricVarieties/NormalToricVarieties/attributes.jl +++ b/src/AlgebraicGeometry/ToricVarieties/NormalToricVarieties/attributes.jl @@ -648,13 +648,7 @@ Return the map from the character lattice to the group of principal divisors of julia> p2 = projective_space(NormalToricVariety, 2); julia> map_from_character_lattice_to_torusinvariant_weil_divisor_group(p2) -Map with following data -Domain: -======= -Abelian group with structure: Z^2 -Codomain: -========= -Abelian group with structure: Z^3 +Map: GrpAb: Z^2 -> GrpAb: Z^3 ``` """ @attr GrpAbFinGenMap function map_from_character_lattice_to_torusinvariant_weil_divisor_group(v::NormalToricVarietyType) @@ -717,13 +711,7 @@ Return the map from the group of Weil divisors to the class of group of a normal julia> p2 = projective_space(NormalToricVariety, 2); julia> map_from_torusinvariant_weil_divisor_group_to_class_group(p2) -Map with following data -Domain: -======= -Abelian group with structure: Z^3 -Codomain: -========= -Abelian group with structure: Z +Map: GrpAb: Z^3 -> GrpAb: Z ``` """ @attr GrpAbFinGenMap function map_from_torusinvariant_weil_divisor_group_to_class_group(v::NormalToricVarietyType) @@ -745,13 +733,7 @@ julia> p2 = projective_space(NormalToricVariety, 2) Normal, non-affine, smooth, projective, gorenstein, fano, 2-dimensional toric variety without torusfactor julia> map_from_torusinvariant_cartier_divisor_group_to_torusinvariant_weil_divisor_group(p2) -Map with following data -Domain: -======= -Abelian group with structure: Z^3 -Codomain: -========= -Abelian group with structure: Z^3 +Map: GrpAb: Z^3 -> GrpAb: Z^3 ``` """ @attr Map{GrpAbFinGen, GrpAbFinGen} function map_from_torusinvariant_cartier_divisor_group_to_torusinvariant_weil_divisor_group(v::NormalToricVarietyType) @@ -845,13 +827,7 @@ julia> p2 = projective_space(NormalToricVariety, 2) Normal, non-affine, smooth, projective, gorenstein, fano, 2-dimensional toric variety without torusfactor julia> map_from_torusinvariant_cartier_divisor_group_to_class_group(p2) -Map with following data -Domain: -======= -Abelian group with structure: Z^3 -Codomain: -========= -Abelian group with structure: Z +Map: GrpAb: Z^3 -> GrpAb: Z ``` """ @attr GrpAbFinGenMap function map_from_torusinvariant_cartier_divisor_group_to_class_group(v::NormalToricVarietyType) @@ -876,13 +852,7 @@ julia> p2 = projective_space(NormalToricVariety, 2) Normal, non-affine, smooth, projective, gorenstein, fano, 2-dimensional toric variety without torusfactor julia> map_from_torusinvariant_cartier_divisor_group_to_picard_group(p2) -Map with following data -Domain: -======= -Abelian group with structure: Z^3 -Codomain: -========= -Abelian group with structure: Z +Map: GrpAb: Z^3 -> GrpAb: Z ``` """ @attr GrpAbFinGenMap function map_from_torusinvariant_cartier_divisor_group_to_picard_group(v::NormalToricVarietyType) @@ -925,13 +895,7 @@ julia> p2 = projective_space(NormalToricVariety, 2) Normal, non-affine, smooth, projective, gorenstein, fano, 2-dimensional toric variety without torusfactor julia> map_from_picard_group_to_class_group(p2) -Map with following data -Domain: -======= -Abelian group with structure: Z -Codomain: -========= -Abelian group with structure: Z +Map: GrpAb: Z -> GrpAb: Z ``` """ @attr GrpAbFinGenMap function map_from_picard_group_to_class_group(v::NormalToricVarietyType) diff --git a/src/AlgebraicGeometry/ToricVarieties/ToricMorphisms/attributes.jl b/src/AlgebraicGeometry/ToricVarieties/ToricMorphisms/attributes.jl index 17a32f369dbc..6c0f80bb0abb 100644 --- a/src/AlgebraicGeometry/ToricVarieties/ToricMorphisms/attributes.jl +++ b/src/AlgebraicGeometry/ToricVarieties/ToricMorphisms/attributes.jl @@ -43,13 +43,7 @@ julia> F4 = hirzebruch_surface(NormalToricVariety, 4) Normal, non-affine, smooth, projective, gorenstein, non-fano, 2-dimensional toric variety without torusfactor julia> grid_morphism(toric_identity_morphism(F4)) -Map with following data -Domain: -======= -Abelian group with structure: Z^2 -Codomain: -========= -Abelian group with structure: Z^2 +Map: GrpAb: Z^2 -> GrpAb: Z^2 ``` """ grid_morphism(tm::ToricMorphism) = tm.grid_morphism @@ -67,13 +61,7 @@ julia> F4 = hirzebruch_surface(NormalToricVariety, 4) Normal, non-affine, smooth, projective, gorenstein, non-fano, 2-dimensional toric variety without torusfactor julia> morphism_on_torusinvariant_weil_divisor_group(toric_identity_morphism(F4)) -Map with following data -Domain: -======= -Abelian group with structure: Z^4 -Codomain: -========= -Abelian group with structure: Z^4 +Map: GrpAb: Z^4 -> GrpAb: Z^4 ``` """ @attr GrpAbFinGenMap function morphism_on_torusinvariant_weil_divisor_group(tm::ToricMorphism) @@ -104,13 +92,7 @@ julia> F4 = hirzebruch_surface(NormalToricVariety, 4) Normal, non-affine, smooth, projective, gorenstein, non-fano, 2-dimensional toric variety without torusfactor julia> morphism_on_torusinvariant_cartier_divisor_group(toric_identity_morphism(F4)) -Map with following data -Domain: -======= -Abelian group with structure: Z^4 -Codomain: -========= -Abelian group with structure: Z^4 +Map: GrpAb: Z^4 -> GrpAb: Z^4 ``` """ @attr GrpAbFinGenMap function morphism_on_torusinvariant_cartier_divisor_group(tm::ToricMorphism) @@ -135,13 +117,7 @@ julia> F4 = hirzebruch_surface(NormalToricVariety, 4) Normal, non-affine, smooth, projective, gorenstein, non-fano, 2-dimensional toric variety without torusfactor julia> morphism_on_class_group(toric_identity_morphism(F4)) -Map with following data -Domain: -======= -Abelian group with structure: Z^2 -Codomain: -========= -Abelian group with structure: Z^2 +Map: GrpAb: Z^2 -> GrpAb: Z^2 ``` """ @attr GrpAbFinGenMap function morphism_on_class_group(tm::ToricMorphism) @@ -166,13 +142,7 @@ julia> F4 = hirzebruch_surface(NormalToricVariety, 4) Normal, non-affine, smooth, projective, gorenstein, non-fano, 2-dimensional toric variety without torusfactor julia> morphism_on_picard_group(toric_identity_morphism(F4)) -Map with following data -Domain: -======= -Abelian group with structure: Z^2 -Codomain: -========= -Abelian group with structure: Z^2 +Map: GrpAb: Z^2 -> GrpAb: Z^2 ``` """ @attr GrpAbFinGenMap function morphism_on_picard_group(tm::ToricMorphism) diff --git a/src/AlgebraicGeometry/ToricVarieties/ToricMorphisms/constructors.jl b/src/AlgebraicGeometry/ToricVarieties/ToricMorphisms/constructors.jl index b1a00222fead..30710ee80449 100644 --- a/src/AlgebraicGeometry/ToricVarieties/ToricMorphisms/constructors.jl +++ b/src/AlgebraicGeometry/ToricVarieties/ToricMorphisms/constructors.jl @@ -85,13 +85,7 @@ julia> mapping_matrix = matrix(ZZ, [[0, 1]]) [0 1] julia> grid_morphism = hom(character_lattice(domain), character_lattice(codomain), mapping_matrix) -Map with following data -Domain: -======= -Abelian group with structure: Z -Codomain: -========= -Abelian group with structure: Z^2 +Map: GrpAb: Z -> GrpAb: Z^2 julia> toric_morphism(domain, grid_morphism, codomain) A toric morphism diff --git a/src/Rings/MPolyMap/MPolyRing.jl b/src/Rings/MPolyMap/MPolyRing.jl index 2764f81fe723..101c88d30f19 100644 --- a/src/Rings/MPolyMap/MPolyRing.jl +++ b/src/Rings/MPolyMap/MPolyRing.jl @@ -59,7 +59,7 @@ defined by x -> y y -> x with map on coefficients -#1 + #1 julia> F(a * y) (a + 1)*x @@ -77,13 +77,7 @@ defined by x -> x^2 y -> y^2 with map on coefficients - Map with following data - Domain: - ======= - Qi - Codomain: - ========= - Qi + Map: imaginary quadratic field defined by x^2 + 1 -> imaginary quadratic field defined by x^2 + 1 julia> G(x+i*y) x^2 - sqrt(-1)*y^2 diff --git a/src/Rings/mpoly-affine-algebras.jl b/src/Rings/mpoly-affine-algebras.jl index 9a9669635b6c..775d94a78e4d 100644 --- a/src/Rings/mpoly-affine-algebras.jl +++ b/src/Rings/mpoly-affine-algebras.jl @@ -523,13 +523,9 @@ julia> H GrpAb: Z julia> iso -Map with following data -Domain: -======= -H -Codomain: -========= -G +Map: GrpAb: Z -> (General) abelian group with relation matrix +[1 -1] +with structure of GrpAb: Z ``` """ function multi_hilbert_series( @@ -720,13 +716,9 @@ julia> H[2][1] GrpAb: Z julia> H[2][2] -Map with following data -Domain: -======= -Abelian group with structure: Z -Codomain: -========= -G +Map: GrpAb: Z -> (General) abelian group with relation matrix +[1 -1] +with structure of GrpAb: Z ``` """ function multi_hilbert_series_reduced(A::MPolyQuoRing; algorithm::Symbol=:BayerStillmanA)