Probability Functions: order of arguments insanity

09122014, 04:55 AM
Post: #1




Probability Functions: order of arguments insanity
A student in a German HP Prime forum came up with the reasonable question, why following inconsistency was implemented (cited via copy&paste from User_Guide_EN.pdf):
for the density function: BINOMIAL(n,k,p) for the cumulative distribution function: BINOMIAL_CDF(n,p,k) What the heck was the reason for swapping the order of 2nd and 3rd arguments? Please please HP, enlighten us!! Kind regards, Ralf. 

09132014, 08:31 AM
Post: #2




RE: Probability Functions: order of arguments insanity
The CAS accepts both syntax for binomial: binomial(n,p,k) and binomial(n,k,p), it checks whether the second argument is a real in 0..1 or an integer. The reason to accept both syntax is for compatibility with binomial(n,k)==comb(n,k) and binomial_cdf and icdf argument order consistency.


09212014, 05:14 PM
(This post was last modified: 09212014 05:18 PM by Primeoprime.)
Post: #3




RE: Probability Functions: order of arguments insanity
(09132014 08:31 AM)parisse Wrote: The CAS accepts both syntax for binomial: binomial(n,p,k) and binomial(n,k,p), Hallo Parisse, mine doesn´t accept both.. it gives me error in that case:binomial(n,p,k) and also in that case: binominal_CDF(n,k,p) Shows "Fehler:ungültige Eingabe" (it knows German) My Casio fxcp 400 CAS, my Tinspire Cx CAS and my Casio fxCG20 too accept in each case only one syntax (defenitely!) , but the same for binomial and binominal_CDF. So I need no brain capacity to pay attention what biominal entry is asked and it´s so much easier for me to do math at school. I guess Hp prime is not build for pupils and students. And I can`t recommened HP prime to other pupils in my school. Better they use Casio fxcp 400 or Tinspire Cx CAS or Casio fxCG20 , which are easier to understand by intuition. Best regards! und herzlichst! Naomi " All those who agree with me and believe in telekinetics raise my right arm now !" 

09212014, 09:23 PM
Post: #4




RE: Probability Functions: order of arguments insanity
Keep on rocking, Naomi!


09232014, 06:45 AM
Post: #5




RE: Probability Functions: order of arguments insanity
(09212014 05:14 PM)Primeoprime Wrote:Make sure you enter the commandnames in lowercase. Also note that binomial_cdf and binomial_icdf take p as second argument, since binomial_[i]cdf(n,k) does not mean anything.(09132014 08:31 AM)parisse Wrote: The CAS accepts both syntax for binomial: binomial(n,p,k) and binomial(n,k,p), 

09242014, 05:52 AM
Post: #6




RE: Probability Functions: order of arguments insanity
(09132014 08:31 AM)parisse Wrote: The CAS accepts both syntax for binomial: binomial(n,p,k) and binomial(n,k,p), it checks whether the second argument is a real in 0..1 or an integer. ... I suggest a look at this topic in a German discussion forum, where basically is shown my means of examples, that the statement above is true only in some special cases, but not in general. 

09242014, 07:21 AM
Post: #7




RE: Probability Functions: order of arguments insanity
It's of course true if p and k have values, not if they are symbolic. There is no good solution anyway, since users will expect p as an optionnal 3rd argument to binomial(n,k) and will expect argument order consistency with binomial_cdf/icdf, whatever it means since the third arg has nothing to do with the k of binomial(n,k,p), you should see this k as a disappearing argument.


« Next Oldest  Next Newest »

User(s) browsing this thread: 1 Guest(s)