Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Hypergeometric function improvements #511

Closed
5 tasks
sakrejda opened this issue Mar 20, 2017 · 1 comment
Closed
5 tasks

Hypergeometric function improvements #511

sakrejda opened this issue Mar 20, 2017 · 1 comment
Labels
Milestone

Comments

@sakrejda
Copy link
Contributor

sakrejda commented Mar 20, 2017

Summary:

Our hypergeometric functions don't implement the accuracy and speed related improvements available in other libraries, this might lead to limited accuracy in some cases. This needs to be tackled after issues hypergeometric functions have proper tests (issue #27) and after hypergeometric functions are correct (issue #488). I will either add the model demonstrating these issues in a real example or move this stuff to a Wiki as it's only borderline specific enough.

Description:

  • I have a model that relies incomplete gamma functions and appears to fail due to innacurate computations (dropping stepsize despite lack of divergences), can't get accept probability consistently high, will post model once I verify.
  • Issue Bugfix/issue 487 hypergeometric functions #488 has some background on which functions can be expected to have problems.
  • We never check conditions on convergence of gradients even with fixes in Bugfix/issue 487 hypergeometric functions #488 as these are different from conditions on functions
  • Mathematica and other sources rely on analytic continuation and other tricks to get accurate results, esp near boundaries, and we don't (AFAIK)
  • There's a Julia implementation for 3F2 (and paper) by Barton.
  • We need some test-cases where this fails

Specifics:

  • add example demonstration failure caused by lack of accuracy.
  • add example demonstrating issue caused by slow convergence.
  • add convergence check functions for grad_3F2 and grad_2F1.
  • use reflection near |z|==1 and possibly a continuation at |z|==1
  • Check what effort would be invovled in the acceleration methods mentioned by Johansson

Reproducible Steps:

Adding example.

Current Output:

Stepsize keeps dropping b/c density or gradient is not accurate enough, will add doc.

Expected Output:

Apparent convergence

Current Version:

v2.14.0

@sakrejda sakrejda added this to the 2.14.0++ milestone Mar 20, 2017
@bob-carpenter bob-carpenter modified the milestones: 2.15.0++, 2.14.0++ Apr 3, 2017
@sakrejda
Copy link
Contributor Author

Some of these suggestions could be implemented but the scope is too broad, closing.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

2 participants