Skip to content

Commit

Permalink
Fix GLHighPrecision error
Browse files Browse the repository at this point in the history
Signed-off-by: ErikQQY <2283984853@qq.com>
  • Loading branch information
ErikQQY committed Mar 23, 2024
1 parent 405d7c8 commit e79f6ce
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 2 deletions.
2 changes: 1 addition & 1 deletion src/Derivative/GL.jl
Original file line number Diff line number Diff line change
Expand Up @@ -214,7 +214,7 @@ function fracdiff(f::Union{Function, Number, Vector},
α::T,
t,
alg::GLHighPrecision) where {T <: Real}
p = @unpack p = alg
@unpack p = alg
if isa(f, Function)
y=f.(t)
elseif isa(f, Vector)
Expand Down
2 changes: 1 addition & 1 deletion test/Derivative.jl
Original file line number Diff line number Diff line change
Expand Up @@ -43,7 +43,7 @@ end
@testset "Test Grunwald-Letnikov Fractional Derivative" begin
@test isapprox(fracdiff(x->x, 0.5, 0, 0.5, GLDirect())[1], 0.7978845583186518; atol = 1e-5)
@test isapprox(fracdiff(x->x^5, 0.5, 0, 3.2, GLDirect())[1], 4.300306216488329e2; atol = 1e-5)
@test isapprox(fracdiff(x->x, 0.5, collect(0:0.01:1), 2, GLHighPrecision())[end], 2/sqrt(pi); atol = 1e-4)
@test isapprox(fracdiff(x->x, 0.5, collect(0:0.01:1), GLHighPrecision())[end], 2/sqrt(pi); atol = 1e-4)
end

@testset "Test GL_Multiplicative_Additive()" begin
Expand Down

0 comments on commit e79f6ce

Please sign in to comment.