Version: 7.3.4.2 (x64) / LibreOffice Community
Build ID: 728fec16bd5f605073805c3c9e7c4212a0120dc5
CPU threads: 4; OS: Windows 10.0 Build 19043; UI render: Skia/Raster; VCL: win
Locale: sv-SE (en_GB); UI: en-GB
Calc: threaded
Hi there, all you guys who know more than me,
I’m attaching a mickey mouse CALC to demonstrate.
The COMBINA() function claims to return the count of non-unique permutations for a given definition and the help example demonstrates the result for 2 from 3.
Is it “illegal” to define the number of variables as identical to the source array i.e. 4 from 4?
The two tables demonstrate the unique permutations for 1, 2, 3 & 4 and the repetitious permutations for the same numbers. The repetitious table incorporates obvious starting pairs, priles & boxes in the first column as non-unique does imply all four may be the same.
I can get 88 permutations as the definition doesn’t state that the results are compulsorily non-unique and even though my perception of COMBINA() may have gone astray, I can certainly count() and sum() the resulting permutations.
Thanks chaps & chapesses.
COMBINA.ods (26.8 KB)
Note how COMBINA tells about “where the order of choosing is irrelevant”, i.e. 1121 and 1112 are identical (three 1s and one 2).
Hi @mikekaganski
I understand your explanation but it implies that the help is poorly written -
“COMBINA returns the number of unique ways to choose these items, where the order of choosing is irrelevant, and repetition of items is allowed”.
1131 and 1311 are indeed unique and quite consequential when the permutation is alpha characters AXEL = 1,2,3,4 and AXLE is 1,2,4,3. Both are certainly unique combinations of the same four characters without any pair distractions but one would be excluded because the unique locations are ignored. Perhaps we should give kids numbers instead of names
Perhaps the help could reflect the position that the results are “virtually” sorted in ascending order and then the duplications are excluded - or something
Shrug; indeed there’s always a way to improve (of course, in my opinion, the use of term “set” in the help, combined with quite explicit “irrelevant order of choosing”, is very specific, but it depends on background in combinatorics…) Patches are welcome!
I wasn’t convinced my “virtual sorting” was the correct interpretation but having accessed @mikekaganski’s link to Patches… I know I could really wreck that - without even trying. Pass.
your talking about permutations wich has no calc-function to calculate the numbers of.
COMBINEA
returns the number of combinations_with_replacments.
may be of help
Sorry my fault, my settings was on working with localized Names, did not expect ‘VARIATIONEN’ … ‘VARIATIONENA’
PERMUTATIONA
I suspect that’s the one I was looking for but I’m still confused, PERMUTATIONA(4;4) returns 256 - where/how did I lose 192 variations in my example? EDIT: Does making both variables the same i.e. 4;4 corrupt the results?
why not choose PERMUT?
Quote from the Helppage for PERMUTATIONA with Highlighted relavant Detail:
There are 216 different possibilities to put a sequence of 3 playing cards together out of six playing cards if every card is returned before the next one is drawn.
No. There are 256 permutations of 4 elements with repetitions in total (4^4)
I was looking at the variations (no pun intended) for evaluating the possible numbers involved in permutations of the 4 characters in the name AXEL. I had already figured it out with the simple mental arithmetic of product 2,3,4 but was having trouble equating the results of the other functions I was experimenting with. The table was more of a demonstration of the correct result and the possible permutations. It wasn’t a real worksheet. I thought the COMBINA() function might also provide a result of 24 but it came back with 35 and I was trying to figure out why. @mikekaganski 's original response set me on the mechanics of re-using some of the characters so I started to evaluate that impact. I’m not a statistician or one of those combo things, I just like to learn a couple of new tricks every day - I’ve succeeded. Thanks everybody for all your endeavours.
@karolus looking at the graphic accompanying your Wiki permutation definition where the colours are symbolic of 1, 2 & 3. Is there an explanation as to why the track for 1 & 3 can be traced from top to bottom in contiguous “frames” but 2 is broken at every pair? Also how is this affected by increasing the number of elements? Does it depend upon the number of columns? Is it always only the first and last or will other “positions” display the same characteristics?