COMBINA Function in ONLYOFFICE: Combinations With Repetition
Learn ONLYOFFICE COMBINA for unordered choices with repetition, reproducible worksheets, differences from COMBIN, and vendor-documented boundary cautions.
Verification status: Official documentation referenced; example outcomes independently reasoned or arithmetically checked where stated. Not executed in ONLYOFFICE Spreadsheet Editor. How formula examples are checked
Verification: Formula outputs are independently calculated mathematical expectations. Native ONLYOFFICE execution was not performed.
Quick answer: Counts unordered selections when you may select a type more than once. The official syntax is COMBINA(number, number_chosen) (ONLYOFFICE official function reference); this short unversioned reference does not establish the first-supported Desktop/web release.
Purpose and counting model
Use COMBINA when the individual type matters, repetition is allowed, and order does not matter. For example, a two-scoop order from vanilla, chocolate and strawberry counts vanilla–chocolate as the same order as chocolate–vanilla, while vanilla–vanilla is allowed. The ONLYOFFICE COMBINA documentation explicitly identifies combinations with repetition. That differs from COMBIN, which counts sets selected without replacement, and from PERMUTATIONA, which counts order-sensitive arrangements with repetition.
For positive integer numbers of types n and selections k, the independently derived mathematical result is
COMBINA(n,k) = (n+k−1)! / (k! × (n−1)!) = COMBIN(n+k−1,k)
This is a mathematical identity; it is not evidence of an executed ONLYOFFICE function. The guide’s tested-on-paper examples stay inside the vendor’s published k<n restriction.
Exact syntax, arguments and defaults
=COMBINA(number, number_chosen)
| Position | Argument | Required | Vendor-described restriction |
|---|---|---|---|
| 1 | number |
Yes | Numeric number of available item types, ≥0. |
| 2 | number_chosen |
Yes | Numeric number of items selected, ≥0 and less than number according to the current English help. |
No optional arguments, omitted-argument defaults or alternate syntax are specified by the official function page. In a worksheet use whole-number inputs to model discrete choices; the official short page does not say how fractions are truncated/coerced or which error strings occur for invalid types.
Reproducible worksheet: ice-cream combinations
- In A1 type
Flavours available; in B1 typeScoops chosen; in C1 typeCOMBINA formula; in D1 typeIndependently expected. - For rows 2–9 enter the A/B pairs from the table below as numbers, not text. In C2 type
=COMBINA(A2,B2)and fill C2 downward through C9 (or type the formula into each row). - Fill D2:D9 with the expected results to provide an independent answer key. Only a live ONLYOFFICE test can establish the observed C values.
| Row | A: Types n | B: Selections k | Formula in C | Independently expected D |
|---|---|---|---|---|
| 2 | 3 | 2 | =COMBINA(A2,B2) |
6 |
| 3 | 4 | 3 | =COMBINA(A3,B3) |
20 |
| 4 | 5 | 2 | =COMBINA(A4,B4) |
15 |
| 5 | 6 | 3 | =COMBINA(A5,B5) |
56 |
| 6 | 3 | 0 | =COMBINA(A6,B6) |
1 |
| 7 | 7 | 4 | =COMBINA(A7,B7) |
210 |
| 8 | 10 | 5 | =COMBINA(A8,B8) |
2002 |
| 9 | 8 | 2 | =COMBINA(A9,B9) |
36 |
Validation labeling: these values were computed using Python standard-library integer arithmetic and represent expected mathematical results. No screenshot, formula execution, locale trial, or native error observation was produced.
Advanced scenario: selecting a product bundle
A customer chooses three products from four flavours, with unlimited stock and no order significance. The distinct multisets number COMBINA(4,3) = 20 expected. Categorize the combinations by multiplicity: four all-the-same bundles; for a two-of-one plus one-of-another pattern, 4×3=12 bundles; and for three different flavours, C(4,3)=4 bundles. Total 4+12+4=20. This cross-check does not require trusting a second spreadsheet engine.
To validate algebraically using separately documented functions, =COMBIN(6,3) also has expected value 20, since n+k−1=6. Do not assume these two software functions behave identically on malformed inputs just because their integer counting results agree mathematically.
Probability caveat: distinct combinations are not automatically equally likely
When three scoops are chosen sequentially and uniformly from four flavours, there are 4³=64 equiprobable ordered outcomes (a PERMUTATIONA model). The 20 unordered multisets do not have equal probabilities: an all-vanilla triple corresponds to just one ordered outcome; a triple containing three different flavours corresponds to six ordered outcomes. Therefore do not compute a random-order probability by dividing 1 by COMBINA(4,3) without defining an equal-probability sampling model.
Troubleshooting and unverified boundaries
- Wrong function selected:
=COMBIN(4,3)expects 4 without replacement, not 20 with replacement. Use COMBINA only for repetition-allowed multisets. - Order matters: sequencing 3 scoops on a cone can distinguish positions; the mathematically appropriate order-aware count for 4 flavours is 4³=64, not 20.
k=nandk>n: the mathematical count is defined for n>0, but current vendor text says k must be less than n.=COMBINA(3,3)is a native-test hold, not a guaranteed return value or error.n=0andk=0: vendor wording allowsnumber ≥0but does not state how degenerate zero-type combinations are evaluated. Do not infer runtime output from convention.- Negative, fractional or text inputs: exact coercions/error tokens are not described in the cited vendor article; require testing before promising
#NUM!,#VALUE!or any specific result. - Large counts: values may exceed exact floating-point integer precision; compare with an arbitrary-precision mathematical result and inspect displayed format rather than assuming exact integers.
Related official documentation and links
COMBIN — unordered without repetition; PERMUTATIONA — ordered with repetition; FACT — factorial identity. Each link leads to the official ONLYOFFICE Help Center.
Evidence for claims (accessed 2026-10-13 UTC)
- Definition, function category and exact published argument spelling/order: ONLYOFFICE COMBINA page.
- Function picker and manually typed syntax with commas: official Insert Functions instructions.
- Configurable formula language and region: official Advanced Settings.
- Different version histories: Docs changelog and Desktop changelog. Neither is cited as proof of a first-supported release.
- Numerical expectations and special cases: independent integer mathematics, not vendor runtime verification. Known uncertainty: The documented
number_chosen < numberconstraint is stricter than the general mathematical combinations-with-repetition domain (including k=n or k>n). Native ONLYOFFICE behavior outside the documented restriction is UNVERIFIED.
Entering the formula in ONLYOFFICE
Open an editable worksheet, select the output cell, and enter the formula beginning with =. The official formula entry instructions also support Formula → Function (or the Insert Function dialog) with a name search and argument wizard; manually entered English examples on that page use commas between arguments. Press Enter to calculate. For spreadsheet software and build versions not yet tested, treat the numerical answers below as expected, not observed.
Locale, release and testing scope
This guide writes English function names and comma-separated arguments, matching the official English entry help (checked 2026-10-13). ONLYOFFICE also lets users change the Formula Language and regional number-format settings via File → Advanced Settings (vendor instructions); do not assume the localized function spelling, argument punctuation, decimal mark, or workbook behavior is identical without checking the installed language configuration. The documented regional choices include separate decimal and thousands separator controls, which are not a license to guess a local formula argument delimiter.
These short vendor function references are not versioned. See the independent ONLYOFFICE Docs changelog and Desktop Editors changelog; neither a first-support version nor identical behavior in all historical web, desktop, mobile or third-party spreadsheet engines has been established by this review. The examples are based on documented syntax and independently computed integer mathematics. **Native ONLYOFFICE web/desktop execution: not performed. Localized testing: not performed. Exact native error strings: not observed. **
Verification limitations
Native Desktop/web execution, localized formula parsing, error outcomes and undocumented boundary behavior were not tested. Verify these cases in the target version before relying on them.