Description
Return a colex ranking term from the largest element.
Combinatorial counts depend on whether objects are labeled, order matters, repetitions are permitted and a prefix is already fixed. Local counts, exact integer factors and feasibility bounds answer specific questions and need not enumerate complete objects.
Return a colex ranking term from the largest element.
When to use this tool
Use Subset Colex Leading Rank when checking the stated word, set, multiset or composition convention.
How to use the tool and how it works
- Enter largestElement, subsetSize. Use the units and conventions below.
- Run the tool. Correct any format, range, or cross-field input error before interpreting the output.
- Read leadingRankDecimal. Use the output convention below.
Return a colex ranking term from the largest element. Require whole subsetSize 1..256 and largestElement >= size-1; leadingRankDecimal is exact binomial(largestElement,subsetSize), including zero when largest = size-1.1
| Input field | Meaning and units | Accepted input |
|---|---|---|
| largestElement | Largest Element | Required. Safe integer; minimum 0. |
| subsetSize | Subset Size | Required. Safe integer; minimum 1; maximum 256. |
| Output field | Interpretation | Returned shape |
|---|---|---|
| leadingRankDecimal | Exact binomial(largestElement,subsetSize) for zero-based colex leading term. | Required. Text; maximum UTF-16 length 8192. |
{
"input": {
"largestElement": 5,
"subsetSize": 3
},
"output": {
"leadingRankDecimal": "10"
}
} Limitations and assumptions
- Elements use zero-based colex convention; this is one leading term, not a full subset rank or unranking operation.
- Inputs must satisfy both the field types and the cross-field conditions above. Invalid input causes an error; a successful false flag or documented placeholder is a different result.
- Numeric calculations use binary floating point unless exact decimal-integer arithmetic is explicitly stated. No hidden measurement tolerance or decimal rounding is added; nonfinite or out-of-contract results are rejected. Numeric signed-zero results are exported as zero.
Alternative or Complementary methods
Use complete objects and an appropriate exact counting, ranking or enumeration method when the local contribution is insufficient.
References
Similar or alternative tools
- Subset Complement Cardinality Shift
Update complement cardinality after a supplied subset change.
- Subset Fixed Intersection Budget
Check intersection-size feasibility from set cardinalities.