[
https://issues.apache.org/jira/browse/NUMBERS-167?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=17426593#comment-17426593
]
Alex Herbert commented on NUMBERS-167:
--------------------------------------
While I like the use of DoubleUnaryOperator I have some reservations:
# It does not allow the convergence tolerance or iterations to be passed
dynamically. These will have to be set when creating the operator. This is not
a major issue but does limit the ability to dynamically tune the thresholds.
# It does not allow calling P or Q with the same precomputed argument. Also
not a major issue but will require management of the operators by the user to
keep them in sync.
I will create a new PR with the change to use operators and have a think about
the implications of each design.
> RegularizedGamma.P with precomputed LogGamma value
> --------------------------------------------------
>
> Key: NUMBERS-167
> URL: https://issues.apache.org/jira/browse/NUMBERS-167
> Project: Commons Numbers
> Issue Type: Wish
> Components: gamma
> Reporter: Gilles Sadowski
> Priority: Minor
> Fix For: 1.1
>
> Time Spent: 20m
> Remaining Estimate: 0h
>
> We have
> {code:java}
> double v = RegularizedGamma.P.value(a, x);
> {code}
> where method {{value}} internally calls {{LogGamma.value(a)}}.
> There is a use-case for
> {code:java}
> double logGammaA = LogGamma.value(a);
> double v = RegularizedGamma.P.value(a, x, logGammaA);
> {code}
> for when the user varies {{x}} but not {{a}}.
> Method name TBD: Another overload of {{value}} may be confusing (?).
--
This message was sent by Atlassian Jira
(v8.3.4#803005)