Skip to content

Commit

Permalink
Fix rayangle for negative real arguments (#322)
Browse files Browse the repository at this point in the history
* fix rayangle for real

* Bump version to v0.6.52
  • Loading branch information
jishnub authored Dec 18, 2023
1 parent 18c4e1a commit 5756a2d
Show file tree
Hide file tree
Showing 3 changed files with 7 additions and 3 deletions.
2 changes: 1 addition & 1 deletion Project.toml
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
name = "ApproxFunOrthogonalPolynomials"
uuid = "b70543e2-c0d9-56b8-a290-0d4d6d4de211"
version = "0.6.51"
version = "0.6.52"

[deps]
ApproxFunBase = "fbd15aa5-315a-5a7d-a8a4-24992e37be05"
Expand Down
2 changes: 1 addition & 1 deletion src/Domains/Ray.jl
Original file line number Diff line number Diff line change
Expand Up @@ -48,7 +48,7 @@ Ray() = Ray{false}()
##deal with vector

_rayangle(x) = angle(x)
_rayangle(x::Real) = 0
_rayangle(x::Real) = signbit(x) * oftype(float(x), pi)

function convert(::Type{Ray}, d::AbstractInterval)
a,b = endpoints(d)
Expand Down
6 changes: 5 additions & 1 deletion test/LaguerreTest.jl
Original file line number Diff line number Diff line change
Expand Up @@ -10,12 +10,16 @@ include("testutils.jl")

@verbose @testset "Laguerre and WeightedLaguerre" begin
@testset "Ray" begin
r = VERSION >= v"1.8" ? @inferred(Ray(0..Inf)) : Ray(0..Inf)
r = Ray(0..Inf)
L = Laguerre(1.0,r)
f = x -> exp.(-x)
F = Fun(f, L)
@test F(.3) -F'(.3)
end
@testset "angle" begin
@test angle(Ray(complex(-Inf)..complex(0.0))) angle(Ray(-Inf..0.0))
@test angle(Ray(complex(0.0)..complex(Inf))) angle(Ray(0.0..Inf))
end
@testset "General scaled rays" begin
r = @inferred (() -> Ray(-1.0,0.0,2.0,true))()
L = Laguerre(1.0,r)
Expand Down

2 comments on commit 5756a2d

@jishnub
Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@JuliaRegistrator
Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Registration pull request created: JuliaRegistries/General/97337

Tip: Release Notes

Did you know you can add release notes too? Just add markdown formatted text underneath the comment after the text
"Release notes:" and it will be added to the registry PR, and if TagBot is installed it will also be added to the
release that TagBot creates. i.e.

@JuliaRegistrator register

Release notes:

## Breaking changes

- blah

To add them here just re-invoke and the PR will be updated.

Tagging

After the above pull request is merged, it is recommended that a tag is created on this repository for the registered package version.

This will be done automatically if the Julia TagBot GitHub Action is installed, or can be done manually through the github interface, or via:

git tag -a v0.6.52 -m "<description of version>" 5756a2d48bd529801d2a68b2ee60067ebdb512a7
git push origin v0.6.52

Please sign in to comment.