Description
Update complement cardinality after a supplied subset change.
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.
Update complement cardinality after a supplied subset change.
When to use this tool
Use Subset Complement Cardinality Shift when checking the stated word, set, multiset or composition convention.
How to use the tool and how it works
- Enter universe, subset, increment. Use the units and conventions below.
- Run the tool. Correct any format, range, or cross-field input error before interpreting the output.
- Read complement, changedComplement. Use the output convention below.
Update complement cardinality after a supplied subset change. Require valid whole universe/subset and updated subset within [0,universe]; complement = universe-subset, changedComplement subtracts increment.1
| Input field | Meaning and units | Accepted input |
|---|---|---|
| universe | Universe | Required. Safe integer; minimum 0. |
| subset | Subset | Required. Safe integer; minimum 0. |
| increment | Increment | Required. Safe integer. |
| Output field | Interpretation | Returned shape |
|---|---|---|
| complement | Complement | Required. Safe integer. |
| changedComplement | Changed Complement | Required. Safe integer. |
{
"input": {
"universe": 10,
"subset": 3,
"increment": 2
},
"output": {
"complement": 7,
"changedComplement": 5
}
} Limitations and assumptions
- This does not establish which elements changed or verify an actual set 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 Mask Cardinality Parity
Return cardinality and parity of an unsigned subset mask.
- Subset Fixed Intersection Budget
Check intersection-size feasibility from set cardinalities.