diff --git a/src/RationalFunctionFields/normalforms.jl b/src/RationalFunctionFields/normalforms.jl index 53051848..9477fe7f 100644 --- a/src/RationalFunctionFields/normalforms.jl +++ b/src/RationalFunctionFields/normalforms.jl @@ -319,7 +319,7 @@ is not specified but is assumed to be close to 1. push!(relations_ff_1, monoms_ff_1[i]) push!(tref, exponent_vector(monoms_ff_1[i], 1)) end - complete_intersection_relations_ff = Vector{Nemo.gfp_mpoly}(undef, 0) + complete_intersection_relations_ff = Vector{Nemo.fpMPolyRingElem}(undef, 0) iters = 0 # Compute relations at several random points until a consensus is reached while true diff --git a/src/local_identifiability.jl b/src/local_identifiability.jl index 875fe7dd..a42a2409 100644 --- a/src/local_identifiability.jl +++ b/src/local_identifiability.jl @@ -253,7 +253,7 @@ function _assess_local_identifiability( # in the SE case, it will exit right away while true ic = Dict(x => F(rand(1:prime)) for x in ode_red.x_vars) - inputs = Dict{Nemo.gfp_mpoly, Array{Nemo.fpFieldElem, 1}}( + inputs = Dict{Nemo.fpMPolyRingElem, Array{Nemo.fpFieldElem, 1}}( u => [F(rand(1:prime)) for i in 1:prec] for u in ode_red.u_vars ) diff --git a/src/parametrizations.jl b/src/parametrizations.jl index c725c914..94b38585 100644 --- a/src/parametrizations.jl +++ b/src/parametrizations.jl @@ -237,7 +237,7 @@ $sat_string Original vars: $orig_strings""" end parametric_ring, _ = - polynomial_ring(FractionField(ring_of_tags), orig_strings, ordering = :degrevlex) + polynomial_ring(fraction_field(ring_of_tags), orig_strings, ordering = :degrevlex) relations_between_tags = map(poly -> parent_ring_change(poly, ring_of_tags), relations_between_tags) param_var_mapping = merge( diff --git a/test/differentiate_output.jl b/test/differentiate_output.jl index 9d978b6e..4ca876c7 100644 --- a/test/differentiate_output.jl +++ b/test/differentiate_output.jl @@ -80,32 +80,6 @@ if GROUP == "All" || GROUP == "Core" #------------------------------------------------------------------------------ - function rand_poly(deg, vars) - if deg == 0 - return parent(vars[1])(1) - end - result = 0 - indices = collect(1:length(vars)) - monomials = [] - for d in 0:deg - for subs in StructuralIdentifiability.IterTools.subsets(indices, d) - push!(monomials, subs) - end - end - - for subs in monomials - monom = rand(-50:50) - for v_ind in subs - monom *= vars[v_ind] - end - result += monom - end - - return result - end - - #------------------------------------------------------------------------------ - @testset "Partial derivatives of an output w.r.t. to initial conditions and parameters" begin test_cases = [] P = QQMPolyRingElem @@ -165,7 +139,7 @@ if GROUP == "All" || GROUP == "Core" ) F = Nemo.Native.GF(2^31 - 1) - P = gfp_mpoly + P = fpMPolyRingElem DType = Union{P, Generic.Frac{P}} varnames = vcat( diff --git a/test/ode_ps_solution.jl b/test/ode_ps_solution.jl index dc2e17da..1a072a7f 100644 --- a/test/ode_ps_solution.jl +++ b/test/ode_ps_solution.jl @@ -1,25 +1,4 @@ if GROUP == "All" || GROUP == "Core" - function rand_poly(deg, vars) - result = 0 - indices = vcat(collect(1:length(vars)), collect(1:length(vars))) - monomials = [] - for d in 0:deg - for subs in StructuralIdentifiability.IterTools.subsets(indices, d) - push!(monomials, subs) - end - end - - for subs in monomials - monom = rand(-50:50) - for v_ind in subs - monom *= vars[v_ind] - end - result += monom - end - - return result - end - @testset "Power series solution for an ODE system" begin R, (x, x_dot) = Nemo.polynomial_ring(Nemo.QQ, ["x", "x_dot"]) exp_t = ps_ode_solution( @@ -89,7 +68,7 @@ if GROUP == "All" || GROUP == "Core" ["u_$i" for i in 1:NUMU], ) R, vars = Nemo.polynomial_ring(F, varnames) - PType = gfp_mpoly + PType = fpMPolyRingElem TDict = Dict{PType, Union{PType, Generic.Frac{PType}}} # Generating the intial conditions etc diff --git a/test/parent_ring_change.jl b/test/parent_ring_change.jl index 4fa0a58f..9e940301 100644 --- a/test/parent_ring_change.jl +++ b/test/parent_ring_change.jl @@ -43,7 +43,7 @@ if GROUP == "All" || GROUP == "Core" StructuralIdentifiability.parent_ring_change(f, R__, matching = :byindex) R, (x,) = polynomial_ring(field, ["x"]) - R2, (x2,) = polynomial_ring(Nemo.FractionField(R), ["x"]) + R2, (x2,) = polynomial_ring(Nemo.fraction_field(R), ["x"]) R3, (x3,) = polynomial_ring(field, ["x"]) f = x3^2 f_ = StructuralIdentifiability.parent_ring_change(f, R2) diff --git a/test/runtests.jl b/test/runtests.jl index 970a2e37..cbd0fdd1 100644 --- a/test/runtests.jl +++ b/test/runtests.jl @@ -88,6 +88,27 @@ function random_ps_matrix(ps_ring, matrix_space) return result end +function rand_poly(deg, vars) + result = 0 + indices = vcat(collect(1:length(vars)), collect(1:length(vars))) + monomials = [] + for d in 0:deg + for subs in StructuralIdentifiability.IterTools.subsets(indices, d) + push!(monomials, subs) + end + end + + for subs in monomials + monom = rand(-50:50) + for v_ind in subs + monom *= vars[v_ind] + end + result += monom + end + + return result +end + @info "Testing started" @test isempty(Test.detect_ambiguities(StructuralIdentifiability))