commons-issues mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Amey Jadiye (JIRA)" <j...@apache.org>
Subject [jira] [Commented] (NUMBERS-38) No unit tests for "LanczosApproximation" class
Date Sun, 04 Jun 2017 12:49:04 GMT

    [ https://issues.apache.org/jira/browse/NUMBERS-38?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=16036264#comment-16036264
] 

Amey Jadiye commented on NUMBERS-38:
------------------------------------

Hi [~erans],

I think all that you copied from commons math is correct just need better refactoring of code,
as of now partial logic is present in {{Gamma.java}} and {{LanczosApproximation.java}}  and
they both generate correct output, that said I just went through all repository of commons-number
and found that code is being called from {{Gamma.java}} _(which I see is  very abstract term/class)_
for *Gamma functions* and  Lanczos Approximation as well as Stirling Approximation _(not present
in repo, we can code this and will be and addition)_ are extension to Gamma so their full
logic should be in their own class.

I Gamma we are generating values with basic logic if {{n <= 20}} else we calculate it with
LanczosApproximation, all  we can do is to put full logic in {{LanczosApproximation.java}}
and just call it, at this point Test-cases on LanczosApproximation doesn't make sense.
   

> No unit tests for "LanczosApproximation" class
> ----------------------------------------------
>
>                 Key: NUMBERS-38
>                 URL: https://issues.apache.org/jira/browse/NUMBERS-38
>             Project: Commons Numbers
>          Issue Type: Test
>            Reporter: Gilles
>              Labels: unit-test
>             Fix For: 1.0
>
>
> The computation of the {{LanczosApproximation}} (package {{o.a.c.numbers.gamma}} in module
{{commons-numbers-gamma}}) function is not checked by unit tests.



--
This message was sent by Atlassian JIRA
(v6.3.15#6346)

Mime
View raw message