Skip to content

Commit f86e10b

Browse files
authored
Merge pull request #21 from fingolfin/mh/obsolete
Avoid obsolete names for functions and types
2 parents 5d1cc94 + 7b6f308 commit f86e10b

File tree

14 files changed

+112
-114
lines changed

14 files changed

+112
-114
lines changed

docs/src/groebner-bases.md

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -27,7 +27,7 @@ At the moment different variants of Faugère's F4 Algorithm are implemented.
2727

2828
```@docs
2929
groebner_basis(
30-
I::Ideal{T} where T <: MPolyElem;
30+
I::Ideal{T} where T <: MPolyRingElem;
3131
initial_hts::Int=17,
3232
nr_thrds::Int=1,
3333
max_nr_pairs::Int=0,
@@ -46,7 +46,7 @@ variables of the first block via the `eliminate` parameter in the
4646

4747
```@docs
4848
eliminate(
49-
I::Ideal{T} where T <: MPolyElem,
49+
I::Ideal{T} where T <: MPolyRingElem,
5050
eliminate::Int;
5151
initial_hts::Int=17,
5252
nr_thrds::Int=1,

docs/src/solvers.md

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -26,7 +26,7 @@ The underlying engine is provided by msolve.
2626

2727
```@docs
2828
rational_parametrization(
29-
I::Ideal{T} where T <: MPolyElem;
29+
I::Ideal{T} where T <: MPolyRingElem;
3030
initial_hts::Int=17,
3131
nr_thrds::Int=1,
3232
max_nr_pairs::Int=0,
@@ -36,7 +36,7 @@ The underlying engine is provided by msolve.
3636
)
3737
3838
real_solutions(
39-
I::Ideal{T} where T <: MPolyElem;
39+
I::Ideal{T} where T <: MPolyRingElem;
4040
initial_hts::Int=17,
4141
nr_thrds::Int=1,
4242
max_nr_pairs::Int=0,
@@ -45,7 +45,7 @@ The underlying engine is provided by msolve.
4545
precision::Int=32
4646
)
4747
rational_solutions(
48-
I::Ideal{T} where T <: MPolyElem;
48+
I::Ideal{T} where T <: MPolyRingElem;
4949
initial_hts::Int=17,
5050
nr_thrds::Int=1,
5151
max_nr_pairs::Int=0,

docs/src/types.md

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -26,15 +26,15 @@ We use [Nemo](https://www.nemocas.org/index.html)'s multivariate polynomial
2626
ring structures:
2727

2828
```@repl
29-
R, (x,y,z) = PolynomialRing(QQ, ["x", "y", "z"], ordering=:degrevlex)
29+
R, (x,y,z) = polynomial_ring(QQ, ["x", "y", "z"], ordering=:degrevlex)
3030
```
3131
The above example defines a multivariate polynomial ring in three variables `x`,
3232
`y`, and `z` over the rationals using the dgree reverse lexicographical ordering
3333
for printing polynomials in the following. One can also define polynomial rings
3434
over finite fields:
3535

3636
```@repl
37-
R, (x,y,z) = PolynomialRing(GF(101), ["x", "y", "z"], ordering=:degrevlex)
37+
R, (x,y,z) = polynomial_ring(GF(101), ["x", "y", "z"], ordering=:degrevlex)
3838
```
3939

4040
## Ideals
@@ -44,7 +44,7 @@ data structures connected to ideals in order to make computational algebra more
4444
effective:
4545

4646
```@repl
47-
R, (x,y,z) = PolynomialRing(QQ, ["x", "y", "z"], ordering=:degrevlex)
47+
R, (x,y,z) = polynomial_ring(QQ, ["x", "y", "z"], ordering=:degrevlex)
4848
I = Ideal([x+y+1, y*z^2-13*y^2])
4949
```
5050

src/algorithms/groebner-bases.jl

Lines changed: 16 additions & 16 deletions
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,7 @@ import msolve_jll: libneogb
33
export groebner_basis, eliminate
44

55
@doc Markdown.doc"""
6-
eliminate(I::Ideal{T} where T <: MPolyElem, eliminate::Int, <keyword arguments>)
6+
eliminate(I::Ideal{T} where T <: MPolyRingElem, eliminate::Int, <keyword arguments>)
77
88
Compute a Groebner basis of the ideal `I` w.r.t. to the product monomial ordering defined by two blocks
99
w.r.t. the degree reverse lexicographical monomial ordering using Faugère's F4 algorithm. Hereby the first block includes
@@ -14,7 +14,7 @@ At the moment the underlying algorithm is based on variants of Faugère's F4 Alg
1414
**Note**: At the moment only ground fields of characteristic `p`, `p` prime, `p < 2^{31}` are supported.
1515
1616
# Arguments
17-
- `I::Ideal{T} where T <: MPolyElem`: input generators.
17+
- `I::Ideal{T} where T <: MPolyRingElem`: input generators.
1818
- `initial_hts::Int=17`: initial hash table size `log_2`.
1919
- `nr_thrds::Int=1`: number of threads for parallel linear algebra.
2020
- `max_nr_pairs::Int=0`: maximal number of pairs per matrix, only bounded by minimal degree if `0`.
@@ -26,19 +26,19 @@ At the moment the underlying algorithm is based on variants of Faugère's F4 Alg
2626
```jldoctest
2727
julia> using AlgebraicSolving
2828
29-
julia> R, (x,y,z) = PolynomialRing(GF(101),["x","y","z"], ordering=:degrevlex)
30-
(Multivariate polynomial ring in 3 variables over GF(101), Nemo.fpMPolyRingElem[x, y, z])
29+
julia> R, (x,y,z) = polynomial_ring(GF(101),["x","y","z"], ordering=:degrevlex)
30+
(Multivariate polynomial ring in 3 variables over GF(101), fpMPolyRingElem[x, y, z])
3131
3232
julia> I = Ideal([x+2*y+2*z-1, x^2+2*y^2+2*z^2-x, 2*x*y+2*y*z-y])
33-
Nemo.fpMPolyRingElem[x + 2*y + 2*z + 100, x^2 + 2*y^2 + 2*z^2 + 100*x, 2*x*y + 2*y*z + 100*y]
33+
fpMPolyRingElem[x + 2*y + 2*z + 100, x^2 + 2*y^2 + 2*z^2 + 100*x, 2*x*y + 2*y*z + 100*y]
3434
3535
julia> eliminate(I, 2)
36-
1-element Vector{Nemo.fpMPolyRingElem}:
36+
1-element Vector{fpMPolyRingElem}:
3737
z^4 + 38*z^3 + 95*z^2 + 95*z
3838
```
3939
"""
4040
function eliminate(
41-
I::Ideal{T} where T <: MPolyElem,
41+
I::Ideal{T} where T <: MPolyRingElem,
4242
eliminate::Int;
4343
initial_hts::Int=17,
4444
nr_thrds::Int=1,
@@ -59,15 +59,15 @@ function eliminate(
5959
end
6060

6161
@doc Markdown.doc"""
62-
groebner_basis(I::Ideal{T} where T <: MPolyElem, <keyword arguments>)
62+
groebner_basis(I::Ideal{T} where T <: MPolyRingElem, <keyword arguments>)
6363
6464
Compute a Groebner basis of the ideal `I` w.r.t. to the degree reverse lexicographical monomial ordering using Faugère's F4 algorithm.
6565
At the moment the underlying algorithm is based on variants of Faugère's F4 Algorithm.
6666
6767
**Note**: At the moment only ground fields of characteristic `p`, `p` prime, `p < 2^{31}` are supported.
6868
6969
# Arguments
70-
- `I::Ideal{T} where T <: MPolyElem`: input generators.
70+
- `I::Ideal{T} where T <: MPolyRingElem`: input generators.
7171
- `initial_hts::Int=17`: initial hash table size `log_2`.
7272
- `nr_thrds::Int=1`: number of threads for parallel linear algebra.
7373
- `max_nr_pairs::Int=0`: maximal number of pairs per matrix, only bounded by minimal degree if `0`.
@@ -80,26 +80,26 @@ At the moment the underlying algorithm is based on variants of Faugère's F4 Alg
8080
```jldoctest
8181
julia> using AlgebraicSolving
8282
83-
julia> R, (x,y,z) = PolynomialRing(GF(101),["x","y","z"], ordering=:degrevlex)
84-
(Multivariate polynomial ring in 3 variables over GF(101), Nemo.fpMPolyRingElem[x, y, z])
83+
julia> R, (x,y,z) = polynomial_ring(GF(101),["x","y","z"], ordering=:degrevlex)
84+
(Multivariate polynomial ring in 3 variables over GF(101), fpMPolyRingElem[x, y, z])
8585
8686
julia> I = Ideal([x+2*y+2*z-1, x^2+2*y^2+2*z^2-x, 2*x*y+2*y*z-y])
87-
Nemo.fpMPolyRingElem[x + 2*y + 2*z + 100, x^2 + 2*y^2 + 2*z^2 + 100*x, 2*x*y + 2*y*z + 100*y]
87+
fpMPolyRingElem[x + 2*y + 2*z + 100, x^2 + 2*y^2 + 2*z^2 + 100*x, 2*x*y + 2*y*z + 100*y]
8888
8989
julia> groebner_basis(I)
90-
4-element Vector{Nemo.fpMPolyRingElem}:
90+
4-element Vector{fpMPolyRingElem}:
9191
x + 2*y + 2*z + 100
9292
y*z + 82*z^2 + 10*y + 40*z
9393
y^2 + 60*z^2 + 20*y + 81*z
9494
z^3 + 28*z^2 + 64*y + 13*z
9595
9696
julia> groebner_basis(I, eliminate=2)
97-
1-element Vector{Nemo.fpMPolyRingElem}:
97+
1-element Vector{fpMPolyRingElem}:
9898
z^4 + 38*z^3 + 95*z^2 + 95*z
9999
```
100100
"""
101101
function groebner_basis(
102-
I::Ideal{T} where T <: MPolyElem;
102+
I::Ideal{T} where T <: MPolyRingElem;
103103
initial_hts::Int=17,
104104
nr_thrds::Int=1,
105105
max_nr_pairs::Int=0,
@@ -119,7 +119,7 @@ function groebner_basis(
119119
end
120120

121121
function _core_groebner_basis(
122-
I::Ideal{T} where T <: MPolyElem;
122+
I::Ideal{T} where T <: MPolyRingElem;
123123
initial_hts::Int=17,
124124
nr_thrds::Int=1,
125125
max_nr_pairs::Int=0,

0 commit comments

Comments
 (0)