[ 
https://issues.apache.org/jira/browse/MATH-703?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
 ]

Christian Winter updated MATH-703:
----------------------------------

    Attachment: MATH-703_patch.zip

Here comes the patch for this issue.

However, there are two design points in the patch which might be worth a 
discussion:

1. Should we remove the function toRealDistribution() from 
(Abstract)IntegerDistribution?
=> The test cases for integer distributions need to be adjusted.

2. Should we merge AbstractDefaultXxxDistribution into AbstractXxxDistribution?
=> The methods from AbstractDefaultXxxDistribution must not be final when moved 
to AbstractXxxDistribution.
=> The documentation of AbstractXxxDistribution must clearly state that some 
methods (those which were adopted from AbstractDefaultXxxDistribution) are 
implemented based on assumptions which might not be true for every inheriting 
class and thus must be overwritten in some cases.
                
> Splitting up the distribution hierarchy
> ---------------------------------------
>
>                 Key: MATH-703
>                 URL: https://issues.apache.org/jira/browse/MATH-703
>             Project: Commons Math
>          Issue Type: Improvement
>            Reporter: Christian Winter
>            Priority: Minor
>         Attachments: MATH-703_patch.zip
>
>
> As discussed on the mailing list 
> (http://apache-commons.680414.n4.nabble.com/math-Distributions-over-sample-spaces-other-than-R-tp3931349p3931349.html),
>  the distribution interfaces should be restructured.
> The most important point is to create one root interface for each domain. 
> There should *not* be a common super-interace because different domains 
> require different functionality. Additionally, a super-inferface would 
> require to parametrize the domain which makes things more complicated (e.g., 
> "double" would have to be replaced by "Double"). Currently, Commons Math 
> supports distributions with real domain and distributions with integer 
> domain. Thus there will be the interfaces RealDistribution and 
> IntegerDistribution.
> Another point is to drop the special cases of distributions with real domain 
> in order to simplify the structure. There won't be an interface for 
> absolutely continuous distributions, and there won't be an interface for 
> discrete distributions on the real domain. All the functionality required by 
> the special cases can be defined in RealDistribution.

--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators: 
https://issues.apache.org/jira/secure/ContactAdministrators!default.jspa
For more information on JIRA, see: http://www.atlassian.com/software/jira

        

Reply via email to