Skip to content

Conversation

@ValentinKaisermayer
Copy link

    using Plots, SpecialFunctions
    plot(-3:0.1:3, -3:0.1:3, owens_t, st=:surface)

OwensT

julia> all(owens_t.(-3:3, 0) .== 0.)
true

julia> all(isapprox.(owens_t.(0, -3:3), 1 ./ (2 .* pi) .* atan.(-3:3), rtol=1e-6))
true

julia> all(isapprox.([owens_t(-h, a) for h in -3:3, a in -3:3], [owens_t(h, a) for h in -3:3, a in -3:3], rtol=1e-6))
true

julia> all(isapprox.([owens_t(h, -a) for h in -3:3, a in -3:3], [-owens_t(h, a) for h in -3:3, a in -3:3], rtol=1e-6))
true

@ValentinKaisermayer
Copy link
Author

@giordano
Copy link
Member

Note that that file has the following license:

This code is distributed under the GNU LGPL license.

while this package has MIT License. As far as I know, LGPL is compatible with MIT license, but you must attribute the work to the original author and use the same license for this specific function, and I believe it'd be better to make it explicit in the license of this package that this function has a different license.

added comment

Owen's T function

Ported from Matlab implementation of John Burkardt, which is distributed under the GNU LGPL license.
Copy link
Member

Choose a reason for hiding this comment

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

This is more restrictive than the SpecialFunctions.jl license, which also disqualifies anything derived from that code.

@stevengj
Copy link
Member

stevengj commented Sep 25, 2020

As far as I know, LGPL is compatible with MIT license

It's "compatible" in that you can legally comply with both licenses simultaneously, but it would effectively put SpecialFunctions.jl under the LGPL (since the terms of the LGPL are more restrictive than MIT, and with any license the copyright extends to all derived works including translations to other languages).

@ValentinKaisermayer
Copy link
Author

Scipy implements a version from Boost.
Which in turn is based on the paper Patefield et al. - 2000 - Fast and Accurate Calculation of Owen's T Function.

@azev77
Copy link

azev77 commented Oct 25, 2020

@ohmsweetohm1 this would be really nice, as it would allow a CDF for SkewNormal in Distributions.jl

@ValentinKaisermayer
Copy link
Author

Closing this, due to licencing issues

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants