Skip to content

Commit bb14424

Browse files
SymPy fixed in tests
1 parent 34e710d commit bb14424

File tree

3 files changed

+7
-5
lines changed

3 files changed

+7
-5
lines changed

Project.toml

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,23 +1,24 @@
11
name = "SymbolicNumericIntegration"
22
uuid = "78aadeae-fbc0-11eb-17b6-c7ec0477ba9e"
33
authors = ["Shahriar Iravanian <[email protected]>"]
4-
version = "0.8.3"
4+
version = "0.8.4"
55

66
[deps]
77
DataDrivenDiffEq = "2445eb08-9709-466a-b3fc-47e12bd697a2"
88
DataStructures = "864edb3b-99cc-5e75-8d2d-829cb0a9cfe8"
99
LinearAlgebra = "37e2e46d-f89d-539d-b4ee-838fcccc9c8e"
1010
Statistics = "10745b16-79ce-11e8-11f9-7d13ad32a3b2"
11+
SymPy = "24249f21-da20-56a4-8eb1-6a02cf4ae2e6"
1112
SymbolicUtils = "d1185830-fcd6-423d-90d6-eec64667417b"
1213
Symbolics = "0c5d862f-8b57-4792-8d23-62f2024744c7"
1314

1415
[compat]
1516
DataDrivenDiffEq = "0.8"
1617
DataStructures = "0.18"
1718
PyCall = "1"
19+
SymPy = "1"
1820
SymbolicUtils = "0.19"
1921
Symbolics = "4"
20-
SymPy = "1"
2122
julia = "1.6"
2223

2324
[extras]

test/axiom.jl

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -97,7 +97,7 @@ function accept_integral(sol, ans, x; radius=1.0, abstol=1e-3, n=5)
9797
ϵ = zeros(n)
9898
for i = 1:n
9999
x₀ = test_point(true, radius)
100-
ϵ[i] = value(abs(substitute(sol - ans, Dict(x => x₀))))
100+
ϵ[i] = Symbolics.value(abs(substitute(sol - ans, Dict(x => x₀))))
101101
end
102102
return maximum(ϵ) - minimum(ϵ) <= abstol
103103
catch e
@@ -127,7 +127,7 @@ function test_axiom(L, try_sympy=true; kwargs...)
127127
if isequal(sol, 0)
128128
printstyled("\tFailure\n"; color=:red)
129129
n_fail += 1
130-
elseif accept_integral(value(sol), value(ans), x)
130+
elseif accept_integral(Symbolics.value(sol), Symbolics.value(ans), x)
131131
printstyled("\tSuccess:\t", sol, '\n'; color=:cyan)
132132
n_ok += 1
133133
else

test/runtests.jl

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,8 @@ using SymbolicUtils
55
using SymbolicUtils.Rewriters
66

77
using Test
8-
using PyCall, SymPy
8+
using PyCall
9+
import SymPy
910

1011

1112
include("axiom.jl")

0 commit comments

Comments
 (0)