Skip to content

Commit 2c0af43

Browse files
Merge pull request #62 from kamalsaleh/main
Cast indices to Int for Nemo matrix ops
2 parents 3d7a8ae + 71a81ce commit 2c0af43

2 files changed

Lines changed: 4 additions & 4 deletions

File tree

Project.toml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
name = "MatricesForHomalg"
22
uuid = "29b9b1b6-efa6-450e-8188-a5a2c25df071"
33
authors = ["Mohamed Barakat <mohamed.barakat@uni-siegen.de>", "Johanna Knecht <johanna.knecht@student.uni-siegen.de>"]
4-
version = "0.1.4"
4+
version = "0.1.5"
55

66
[deps]
77
Nemo = "2edaba10-b0f1-5616-af89-8c11ac63239a"

src/MatricesForHomalg.jl

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -114,7 +114,7 @@ julia> mat = HomalgIdentityMatrix(3, ZZ)
114114
```
115115
"""
116116
function HomalgIdentityMatrix(r, R)::TypeOfMatrixForHomalg
117-
return Nemo.identity_matrix(R, r)
117+
return Nemo.identity_matrix(R, Int(r))
118118
end
119119

120120
"""
@@ -915,7 +915,7 @@ function CertainColumns(mat, list)::TypeOfMatrixForHomalg
915915
if length(list) == 0
916916
return HomalgZeroMatrix(NumberRows(mat), 0, HomalgRing(mat))
917917
end
918-
return mat[:, list]
918+
return mat[:, map(x->Int(x), list)]
919919
end
920920

921921
"""
@@ -945,7 +945,7 @@ function CertainRows(mat, list)::TypeOfMatrixForHomalg
945945
if length(list) == 0
946946
return HomalgZeroMatrix(0, NumberColumns(mat), HomalgRing(mat))
947947
end
948-
return mat[list, :]
948+
return mat[map(x->Int(x), list), :]
949949
end
950950

951951
"""

0 commit comments

Comments
 (0)