Skip to content

Commit f83e591

Browse files
committed
more rank -> torsion_free_rank
1 parent 744a80e commit f83e591

File tree

19 files changed

+55
-55
lines changed

19 files changed

+55
-55
lines changed

experimental/FTheoryTools/src/auxiliary.jl

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -35,10 +35,10 @@ function _ambient_space(base::NormalToricVariety, fiber_amb_space::NormalToricVa
3535

3636
# Compute divisor group and the class group of a_space
3737
a_space_divisor_group = free_abelian_group(nrows(a_rays))
38-
a_space_class_group = free_abelian_group(ncols(b_grades) + rank(class_group(fiber_amb_space)))
38+
a_space_class_group = free_abelian_group(ncols(b_grades) + torsion_free_rank(class_group(fiber_amb_space)))
3939

4040
# Compute grading of Cox ring of a_space
41-
a_space_grading = zero_matrix(ZZ, rank(a_space_divisor_group), rank(a_space_class_group))
41+
a_space_grading = zero_matrix(ZZ, torsion_free_rank(a_space_divisor_group), torsion_free_rank(a_space_class_group))
4242
a_space_grading[1:nrows(b_grades), 1:ncols(b_grades)] = b_grades
4343
a_space_grading[1+nrows(b_rays):nrows(b_rays) + nrows(f_grades), 1+ncols(b_grades):ncols(b_grades) + ncols(f_grades)] = f_grades
4444
a_space_grading[1+nrows(b_rays), 1:ncols(D1_coeffs)] = D1_coeffs

src/AlgebraicGeometry/ToricVarieties/NormalToricVarieties/attributes.jl

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -198,7 +198,7 @@ julia> coordinate_names(antv)
198198
```
199199
"""
200200
@attr Vector{String} function coordinate_names(v::NormalToricVarietyType)
201-
return ["x$(i)" for i in 1:rank(torusinvariant_weil_divisor_group(v))]
201+
return ["x$(i)" for i in 1:torsion_free_rank(torusinvariant_weil_divisor_group(v))]
202202
end
203203

204204

@@ -679,8 +679,8 @@ julia> torusinvariant_prime_divisors(p2)
679679
@attr Vector{ToricDivisor} function torusinvariant_prime_divisors(v::NormalToricVarietyType)
680680
ti_divisors = torusinvariant_weil_divisor_group(v)
681681
prime_divisors = ToricDivisor[]
682-
for i in 1:rank(ti_divisors)
683-
coeffs = zeros(Int, rank(ti_divisors))
682+
for i in 1:torsion_free_rank(ti_divisors)
683+
coeffs = zeros(Int, torsion_free_rank(ti_divisors))
684684
coeffs[i] = 1
685685
push!(prime_divisors, toric_divisor(v, coeffs))
686686
end
@@ -756,7 +756,7 @@ Map
756756
number_of_cones = size(max_cones)[1]
757757

758758
# compute quantities needed to construct the matrices
759-
rc = rank(character_lattice(v))
759+
rc = torsion_free_rank(character_lattice(v))
760760
number_ray_is_part_of_max_cones = [length(max_cones[:, k].s) for k in 1:number_of_rays]
761761
s = sum(number_ray_is_part_of_max_cones)
762762
cones_ray_is_part_of = [filter(x -> max_cones[x, r], 1:number_of_cones) for r in 1:number_of_rays]
@@ -784,7 +784,7 @@ Map
784784
end
785785

786786
# compute the matrix for mapping to torusinvariant Weil divisors
787-
map_to_weil_divisors = zero_matrix(ZZ, number_of_cones * rc, rank(torusinvariant_weil_divisor_group(v)))
787+
map_to_weil_divisors = zero_matrix(ZZ, number_of_cones * rc, torsion_free_rank(torusinvariant_weil_divisor_group(v)))
788788
for i in 1:number_of_rays
789789
map_to_weil_divisors[(cones_ray_is_part_of[i][1]-1)*rc+1:cones_ray_is_part_of[i][1]*rc, i] = [ZZRingElem(-c) for c in fan_rays[:, i]]
790790
end

src/AlgebraicGeometry/ToricVarieties/NormalToricVarieties/properties.jl

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -68,7 +68,7 @@ true
6868
if is_projective(v) == false
6969
return false
7070
end
71-
if rank(class_group(v)) > 1
71+
if torsion_free_rank(class_group(v)) > 1
7272
return false
7373
end
7474
w = [[Int(x) for x in transpose(g.coeff)] for g in gens(class_group(v))]

src/AlgebraicGeometry/ToricVarieties/ToricDivisors/constructors.jl

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -68,7 +68,7 @@ Torus-invariant, non-prime divisor on a normal toric variety
6868
```
6969
"""
7070
function divisor_of_character(v::NormalToricVarietyType, character::Vector{T}) where {T <: IntegerUnion}
71-
r = rank(character_lattice(v))
71+
r = torsion_free_rank(character_lattice(v))
7272
@req length(character) == r "Character must consist of $r integers"
7373
f = map_from_character_lattice_to_torusinvariant_weil_divisor_group(v)
7474
char = sum(character .* gens(domain(f)))

src/AlgebraicGeometry/ToricVarieties/ToricMorphisms/attributes.jl

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -73,7 +73,7 @@ Map
7373
cod = codomain(tm)
7474
cod_rays = matrix(ZZ, rays(cod))
7575
images = matrix(ZZ, rays(d)) * matrix(grid_morphism(tm))
76-
mapping_matrix = matrix(ZZ, zeros(ZZ, rank(torusinvariant_weil_divisor_group(cod)), 0))
76+
mapping_matrix = matrix(ZZ, zeros(ZZ, torsion_free_rank(torusinvariant_weil_divisor_group(cod)), 0))
7777
for i in 1:nrows(images)
7878
v = [images[i,k] for k in 1:ncols(images)]
7979
j = findfirst(x -> x == true, [(v in maximal_cones(cod)[j]) for j in 1:n_maximal_cones(cod)])

src/AlgebraicGeometry/ToricVarieties/ToricMorphisms/constructors.jl

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -109,10 +109,10 @@ function toric_morphism(domain::NormalToricVarietyType, grid_morphism::FinGenAbG
109109
@req (nrows(matrix(grid_morphism)) > 0 && ncols(matrix(grid_morphism)) > 0) "The mapping matrix must not be empty"
110110

111111
# check for a well-defined map
112-
@req nrows(matrix(grid_morphism)) == rank(character_lattice(domain)) "The number of rows of the mapping matrix must match the rank of the character lattice of the domain toric variety"
112+
@req nrows(matrix(grid_morphism)) == torsion_free_rank(character_lattice(domain)) "The number of rows of the mapping matrix must match the rank of the character lattice of the domain toric variety"
113113

114114
# compute the morphism
115-
@req ncols(matrix(grid_morphism)) == rank(character_lattice(codomain)) "The number of columns of the mapping matrix must match the rank of the character lattice of the codomain toric variety"
115+
@req ncols(matrix(grid_morphism)) == torsion_free_rank(character_lattice(codomain)) "The number of columns of the mapping matrix must match the rank of the character lattice of the codomain toric variety"
116116
if check
117117
codomain_cones = maximal_cones(codomain)
118118
image_cones = [positive_hull(matrix(ZZ, rays(c)) * matrix(grid_morphism)) for c in maximal_cones(domain)]
@@ -144,7 +144,7 @@ Toric morphism
144144
```
145145
"""
146146
function toric_identity_morphism(variety::NormalToricVarietyType)
147-
r = rank(character_lattice(variety))
147+
r = torsion_free_rank(character_lattice(variety))
148148
identity_matrix = matrix(ZZ, [[if i==j 1 else 0 end for j in 1:r] for i in 1:r])
149149
grid_morphism = hom(character_lattice(variety), character_lattice(variety), identity_matrix)
150150
return ToricMorphism(variety, grid_morphism, variety)

src/AlgebraicGeometry/ToricVarieties/cohomCalg/VanishingSets/constructors.jl

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,7 @@
77
ps::Vector{Polyhedron{QQFieldElem}}
88
cis::Vector{Int}
99
function ToricVanishingSet(toric_variety::NormalToricVarietyType, ps::Vector{Polyhedron{QQFieldElem}}, cis::Vector{Int})
10-
if !all(p -> ambient_dim(p) == rank(picard_group(toric_variety)), ps)
10+
if !all(p -> ambient_dim(p) == torsion_free_rank(picard_group(toric_variety)), ps)
1111
throw(ArgumentError("The ambient dimensions of the polyhedra must match the rank as the picard group of the toric variety"))
1212
end
1313
if !all(i -> 0 <= i <= dim(toric_variety), cis)

src/AlgebraicGeometry/ToricVarieties/cohomCalg/auxiliary.jl

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -29,7 +29,7 @@ function command_string(v::NormalToricVarietyType, c::Vector{ZZRingElem})
2929
# Join and return
3030
return join(string_list, ";")
3131
end
32-
command_string(v::NormalToricVarietyType) = command_string(v, [ZZRingElem(0) for i in 1:rank(picard_group(v))])
32+
command_string(v::NormalToricVarietyType) = command_string(v, [ZZRingElem(0) for i in 1:torsion_free_rank(picard_group(v))])
3333

3434

3535

test/AlgebraicGeometry/ToricVarieties/affine_normal_varieties.jl

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -18,10 +18,10 @@
1818
@test dim(cone(antv)) == 2
1919
@test length(affine_open_covering(antv)) == 1
2020
@test length(gens(toric_ideal(antv))) == 1
21-
@test rank(torusinvariant_weil_divisor_group(antv)) == 2
22-
@test rank(character_lattice(antv)) == 2
23-
@test rank(domain(map_from_character_lattice_to_torusinvariant_weil_divisor_group(antv))) == 2
24-
@test rank(codomain(map_from_character_lattice_to_torusinvariant_weil_divisor_group(antv))) == 2
21+
@test torsion_free_rank(torusinvariant_weil_divisor_group(antv)) == 2
22+
@test torsion_free_rank(character_lattice(antv)) == 2
23+
@test torsion_free_rank(domain(map_from_character_lattice_to_torusinvariant_weil_divisor_group(antv))) == 2
24+
@test torsion_free_rank(codomain(map_from_character_lattice_to_torusinvariant_weil_divisor_group(antv))) == 2
2525
@test elementary_divisors(codomain(map_from_torusinvariant_weil_divisor_group_to_class_group(antv))) == [ 2 ]
2626
@test elementary_divisors(class_group(antv)) == [ 2 ]
2727
@test ngens(cox_ring(antv)) == 2

test/AlgebraicGeometry/ToricVarieties/del_pezzo_surfaces.jl

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -23,8 +23,8 @@
2323

2424
@testset "Basic attributes of dP1" begin
2525
@test length(torusinvariant_prime_divisors(dP1)) == 4
26-
@test rank(torusinvariant_cartier_divisor_group(dP1)) == 4
27-
@test rank(picard_group(dP1)) == 2
26+
@test torsion_free_rank(torusinvariant_cartier_divisor_group(dP1)) == 4
27+
@test torsion_free_rank(picard_group(dP1)) == 2
2828
@test transpose(matrix(ZZ,rays(dP1))) == matrix(map_from_character_lattice_to_torusinvariant_weil_divisor_group(dP1))
2929
@test domain(map_from_character_lattice_to_torusinvariant_weil_divisor_group(dP1)) == character_lattice(dP1)
3030
@test codomain(map_from_character_lattice_to_torusinvariant_weil_divisor_group(dP1)) == torusinvariant_weil_divisor_group(dP1)
@@ -44,8 +44,8 @@
4444

4545
@testset "Basic attributes of dP2" begin
4646
@test length(torusinvariant_prime_divisors(dP2)) == 5
47-
@test rank(torusinvariant_cartier_divisor_group(dP2)) == 5
48-
@test rank(picard_group(dP2)) == 3
47+
@test torsion_free_rank(torusinvariant_cartier_divisor_group(dP2)) == 5
48+
@test torsion_free_rank(picard_group(dP2)) == 3
4949
@test transpose(matrix(ZZ,rays(dP2))) == matrix(map_from_character_lattice_to_torusinvariant_weil_divisor_group(dP2))
5050
@test domain(map_from_character_lattice_to_torusinvariant_weil_divisor_group(dP2)) == character_lattice(dP2)
5151
@test codomain(map_from_character_lattice_to_torusinvariant_weil_divisor_group(dP2)) == torusinvariant_weil_divisor_group(dP2)
@@ -65,8 +65,8 @@
6565

6666
@testset "Basic attributes of dP3" begin
6767
@test length(torusinvariant_prime_divisors(dP3)) == 6
68-
@test rank(torusinvariant_cartier_divisor_group(dP3)) == 6
69-
@test rank(picard_group(dP3)) == 4
68+
@test torsion_free_rank(torusinvariant_cartier_divisor_group(dP3)) == 6
69+
@test torsion_free_rank(picard_group(dP3)) == 4
7070
@test transpose(matrix(ZZ,rays(dP3))) == matrix(map_from_character_lattice_to_torusinvariant_weil_divisor_group(dP3))
7171
@test domain(map_from_character_lattice_to_torusinvariant_weil_divisor_group(dP3)) == character_lattice(dP3)
7272
@test codomain(map_from_character_lattice_to_torusinvariant_weil_divisor_group(dP3)) == torusinvariant_weil_divisor_group(dP3)

test/AlgebraicGeometry/ToricVarieties/hirzebruch_surfaces.jl

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -34,17 +34,17 @@
3434
@test betti_number(F5, 4) == 1
3535
@test length(affine_open_covering(F5)) == 4
3636
@test dim(polyhedral_fan(F5)) == 2
37-
@test rank(torusinvariant_weil_divisor_group(F5)) == 4
38-
@test rank(character_lattice(F5)) == 2
37+
@test torsion_free_rank(torusinvariant_weil_divisor_group(F5)) == 4
38+
@test torsion_free_rank(character_lattice(F5)) == 2
3939
@test ngens(cox_ring(F5)) == 4
4040
@test length(stanley_reisner_ideal(F5).gens) == 2
4141
@test length(irrelevant_ideal(F5).gens) == 4
4242
@test dim(nef_cone(F5)) == 2
4343
@test dim(mori_cone(F5)) == 2
44-
@test rank(domain(map_from_character_lattice_to_torusinvariant_weil_divisor_group(F5))) == 2
45-
@test rank(codomain(map_from_character_lattice_to_torusinvariant_weil_divisor_group(F5))) == 4
46-
@test rank(class_group(F5)) == 2
47-
@test rank(codomain(map_from_torusinvariant_weil_divisor_group_to_class_group(F5))) == 2
44+
@test torsion_free_rank(domain(map_from_character_lattice_to_torusinvariant_weil_divisor_group(F5))) == 2
45+
@test torsion_free_rank(codomain(map_from_character_lattice_to_torusinvariant_weil_divisor_group(F5))) == 4
46+
@test torsion_free_rank(class_group(F5)) == 2
47+
@test torsion_free_rank(codomain(map_from_torusinvariant_weil_divisor_group_to_class_group(F5))) == 2
4848
@test transpose(matrix(ZZ,rays(F5))) == matrix(map_from_character_lattice_to_torusinvariant_weil_divisor_group(F5))
4949
@test domain(map_from_character_lattice_to_torusinvariant_weil_divisor_group(F5)) == character_lattice(F5)
5050
@test codomain(map_from_character_lattice_to_torusinvariant_weil_divisor_group(F5)) == torusinvariant_weil_divisor_group(F5)

test/AlgebraicGeometry/ToricVarieties/normal_toric_varieties.jl

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -9,8 +9,8 @@
99
@testset "Basic properties" begin
1010
@test is_complete(ntv) == true
1111
@test is_projective_space(ntv) == false
12-
@test rank(torusinvariant_cartier_divisor_group(ntv)) == 4
13-
@test rank(domain(map_from_torusinvariant_cartier_divisor_group_to_torusinvariant_weil_divisor_group(ntv))) == 4
12+
@test torsion_free_rank(torusinvariant_cartier_divisor_group(ntv)) == 4
13+
@test torsion_free_rank(domain(map_from_torusinvariant_cartier_divisor_group_to_torusinvariant_weil_divisor_group(ntv))) == 4
1414
@test is_complete(ntv2) == true
1515
@test length(ntv3) == 1
1616
@test is_projective_space(ntv3[1]) == true

test/AlgebraicGeometry/ToricVarieties/projectivization.jl

Lines changed: 9 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,7 @@
77
X = projectivization(D0, Da)
88
@test is_smooth(X) == true
99
@test (a < 2) == is_fano(X)
10-
@test rank(picard_group(X)) == 2
10+
@test torsion_free_rank(picard_group(X)) == 2
1111
@test integrate(cohomology_class(anticanonical_divisor(X))^dim(X)) == integrate(cohomology_class(anticanonical_divisor(hirzebruch_surface(NormalToricVariety, a)))^2)
1212
end
1313
end
@@ -24,13 +24,13 @@
2424
D2 = toric_divisor(P2, [0,2,0])
2525
X3_P2 = projectivization(D0, D2)
2626
@testset "Test of some Fano projective bundles of dimension 3 over P2" begin
27-
@test rank(picard_group(X1_P2)) == 2
27+
@test torsion_free_rank(picard_group(X1_P2)) == 2
2828
@test is_fano(X1_P2) == true
2929
@test integrate(cohomology_class(anticanonical_divisor(X1_P2))^dim(X1_P2)) == 54
30-
@test rank(picard_group(X2_P2)) == 2
30+
@test torsion_free_rank(picard_group(X2_P2)) == 2
3131
@test is_fano(X2_P2) == true
3232
@test integrate(cohomology_class(anticanonical_divisor(X2_P2))^dim(X2_P2)) == 56
33-
@test rank(picard_group(X3_P2)) == 2
33+
@test torsion_free_rank(picard_group(X3_P2)) == 2
3434
@test is_fano(X3_P2) == true
3535
@test integrate(cohomology_class(anticanonical_divisor(X3_P2))^dim(X3_P2)) == 62
3636
end
@@ -43,11 +43,11 @@
4343
l1_F1 = toric_line_bundle(F1, [0,1])
4444
X2_F1 = projectivization(toric_line_bundle(F1, [0,0]), l1_F1)
4545
@testset "Test of some Fano projective bundles of dimension 3 over F1" begin
46-
@test rank(picard_group(X1_F1)) == 3
46+
@test torsion_free_rank(picard_group(X1_F1)) == 3
4747
@test is_fano(X1_F1) == true
4848
@test integrate(cohomology_class(anticanonical_divisor(X1_F1))^dim(X1_F1)) == 48
4949
@test integrate(cohomology_class(l1_F1)^2) == 1
50-
@test rank(picard_group(X2_F1)) == 3
50+
@test torsion_free_rank(picard_group(X2_F1)) == 3
5151
@test is_fano(X2_F1) == true
5252
@test integrate(cohomology_class(anticanonical_divisor(X2_F1))^dim(X2_F1)) == 50
5353
end
@@ -61,13 +61,13 @@
6161
X2_P1xP1 = projectivization(O10, O10)
6262
X3_P1xP1 = projectivization(O00, O11)
6363
@testset "Test of some Fano projective bundles of dimension 3 over P1 * P1" begin
64-
@test rank(picard_group(X1_P1xP1)) == 3
64+
@test torsion_free_rank(picard_group(X1_P1xP1)) == 3
6565
@test is_fano(X1_P1xP1) == true
6666
@test integrate(cohomology_class(anticanonical_divisor(X1_P1xP1))^dim(X1_P1xP1)) == 44
67-
@test rank(picard_group(X2_P1xP1)) == 3
67+
@test torsion_free_rank(picard_group(X2_P1xP1)) == 3
6868
@test is_fano(X2_P1xP1) == true
6969
@test integrate(cohomology_class(anticanonical_divisor(X2_P1xP1))^dim(X2_P1xP1)) == 48
70-
@test rank(picard_group(X3_P1xP1)) == 3
70+
@test torsion_free_rank(picard_group(X3_P1xP1)) == 3
7171
@test is_fano(X3_P1xP1) == true
7272
@test integrate(cohomology_class(anticanonical_divisor(X3_P1xP1))^dim(X3_P1xP1)) == 52
7373
end

test/AlgebraicGeometry/ToricVarieties/toric_blowdowns.jl

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -4,8 +4,8 @@
44
bl = blow_up(P2, [1, 1])
55

66
@testset "Basic tests for simple toric blowdown" begin
7-
@test rank(domain(grid_morphism(bl))) == 2
8-
@test rank(codomain(grid_morphism(bl))) == 2
7+
@test torsion_free_rank(domain(grid_morphism(bl))) == 2
8+
@test torsion_free_rank(codomain(grid_morphism(bl))) == 2
99
@test matrix(morphism_on_torusinvariant_weil_divisor_group(bl)) == matrix(ZZ, [1 0 0; 0 1 0; 0 0 1; 1 1 0])
1010
@test matrix(morphism_on_torusinvariant_cartier_divisor_group(bl)) == matrix(morphism_on_torusinvariant_weil_divisor_group(bl))
1111
end

test/AlgebraicGeometry/ToricVarieties/toric_blowups.jl

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -22,7 +22,7 @@
2222
@test betti_number(BP2, 3) == 0
2323
@test betti_number(BP2, 4) == 1
2424
@test euler_characteristic(BP2) == 4
25-
@test rank(picard_group(BP2)) == 2
25+
@test torsion_free_rank(picard_group(BP2)) == 2
2626
end
2727

2828
@testset "Trigger issue of PR3006" begin

test/AlgebraicGeometry/ToricVarieties/toric_divisor_classes.jl

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -20,7 +20,7 @@
2020
end
2121

2222
@testset "Basic attributes" begin
23-
@test rank(parent(divisor_class(DC2))) == 2
23+
@test torsion_free_rank(parent(divisor_class(DC2))) == 2
2424
@test dim(toric_variety(DC2)) == 2
2525
end
2626

test/AlgebraicGeometry/ToricVarieties/total_space.jl

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -9,7 +9,7 @@
99
@test is_smooth(X) == true
1010
@test !is_fano(X)
1111
@test !is_complete(X)
12-
@test rank(picard_group(X)) == 1
12+
@test torsion_free_rank(picard_group(X)) == 1
1313
@test dim(X) == 3
1414
@test (degree(canonical_bundle(X)) == 0) == (a - b == -2)
1515
end
@@ -23,7 +23,7 @@
2323
@test is_smooth(X) == true
2424
@test !is_fano(X)
2525
@test !is_complete(X)
26-
@test rank(picard_group(X)) == rank(picard_group(S))
26+
@test torsion_free_rank(picard_group(X)) == torsion_free_rank(picard_group(S))
2727
@test dim(X) == 3
2828
@test degree(canonical_bundle(X)) == 0
2929
end
@@ -35,7 +35,7 @@
3535
X = total_space(canonical_divisor(S))
3636
@test is_smooth(X) == true
3737
@test !is_fano(X)
38-
@test rank(picard_group(X)) == rank(picard_group(S))
38+
@test torsion_free_rank(picard_group(X)) == torsion_free_rank(picard_group(S))
3939
@test dim(X) == 3
4040
@test degree(canonical_bundle(X)) == 0
4141
end

test/Combinatorics/SimplicialComplexes.jl

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -55,9 +55,9 @@
5555
@test !is_trivial(H0)
5656
@test !is_trivial(H1)
5757
@test !is_trivial(H2)
58-
@test rank(H0) == 1
59-
@test rank(H1) == 2
60-
@test rank(H2) == 1
58+
@test torsion_free_rank(H0) == 1
59+
@test torsion_free_rank(H1) == 2
60+
@test torsion_free_rank(H2) == 1
6161
end
6262

6363
@testset "is_isomorphic" begin

test/Rings/hilbert.jl

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -104,13 +104,13 @@ end
104104
JJ = ideal(RR, X^2 - Y^6);
105105
A, _ = quo(base_ring(JJ), JJ);
106106
(numer1, denom1), (H, iso) = multi_hilbert_series(A);
107-
@test is_free(H) && isone(rank(H))
107+
@test is_free(H) && isone(torsion_free_rank(H))
108108
S, t = laurent_polynomial_ring(ZZ, "t");
109109
(numer2, denom2), (H, iso) = multi_hilbert_series(A; parent=S);
110-
@test is_free(H) && isone(rank(H))
110+
@test is_free(H) && isone(torsion_free_rank(H))
111111
Smult, (T,) = polynomial_ring(ZZ, ["t"]);
112112
(numer3, denom3), (H, iso) = multi_hilbert_series(A; parent=Smult);
113-
@test is_free(H) && isone(rank(H))
113+
@test is_free(H) && isone(torsion_free_rank(H))
114114
@test numer1 == evaluate(numer2, T)
115115
@test numer3 == evaluate(numer2, first(gens(parent(numer3))))
116116
end

0 commit comments

Comments
 (0)