Unfinished learning resource · Units 1–8 available · Whole-course validation unfinished

Unit 2. Explained answers and formative rubrics

Unit 2 explained answers · unfinished learning resource · TMP-SCI-074. Attempt the Unit 2 tasks first. This is a separate explanation resource, not a staffed assessment or a certification service. The 32-point quiz and 40-point project are unpiloted formative groups, not semester marks or degree credit. All eight planned units have manuscripts; whole-course validation remains unfinished. Credit equivalent correct constructions and proofs; require the requested reasoning as well as a number.

Readiness

R1. C(6,2)=15; C(4,2)=6; 6!/(2!2!2!)=90. These are arithmetic evaluations. A counting interpretation additionally needs a specified source/target model and a justified map or sequence of choices. In the later labelled-pairs model, the denominator counts permutations within each pair, not permutations of box names.

R2. The union count is 8+7−3=12. Exactly one gives 8+7−2·3=9. Neither gives 20−12=8. X,Y must be subsets of that common finite universe; the intersection is included in both single-set counts.

R3. There are 24/4=6 targets. If fibres can have sizes two and four, one common divisor no longer follows. For example two fibres of size two and five of size four would account for 24 sources and seven targets. Source total alone does not determine the number of uneven fibres.

R4. Use counts 3,3,3,3, assigning three distinct objects to each named box. This is one avoiding distribution. Another distribution, 12,0,0,0, violates the proposed universal maximum-three condition. An existence example and a claim about every distribution have different quantifiers.

Guided tasks

G1. Successive choices give C(8,3)C(5,3)C(2,2)=56·10·1=560. Every labelled allocation has 3!3!2!=72 full orderings of its within-class members, so 8!/72=560 as well. Swapping X and Y changes which labelled class contains each card; their disjoint nonempty member sets cannot be equal. It is a different labelled allocation, though a later forgetful map could identify them.

G2. The full count is 5!/(2!2!)=30. Words containing adjacent A symbols have the single AA block; collapse it to one symbol, arrange AA,B,B,C in 4!/2!=12 ways, and expand the block to recover the unique original word. Hence 30−12=18 avoid adjacent A symbols. There are exactly two As, so this encoding does not make ambiguous choices between overlapping AA occurrences.

G3. Labelled pair classes: 6!/(2!2!2!)=90. Forget class names: each collection of three distinct nonempty disjoint pairs has 3!=6 labellings, giving 15 targets. In the two-object model, both objects must stay together; choose the occupied box in three ways. Erasing names yields one nonempty pair, and the empty boxes are indistinguishable. The fibre has size three, not six; dividing 3 by 6 would not count targets.

G4. The triple intersection is {30,60}. An object in exactly two sets lies in one pair intersection and not the triple, so S₂−3S₃ contributes one. An object in all three lies in three pair intersections and once in the triple, contributing 3−3=0. Objects in zero or one set contribute zero. Therefore exactly two=20−3·2=14. Pair intersections themselves include the triple objects.

G5. The universe is six permutations. Let A_i mean position i contains label i. A specified single fixed position leaves 2!=2 permutations; a specified pair leaves 1!=1; all three fixed gives one. Thus allowed count is 6−3·2+3·1−1=2. The two surviving one-line permutations are (2,3,1) and (3,1,2). The last term is one all-fixed object, not zero.

G6. All strings: 3⁴=81. Exclude missing-symbol conditions: each missing specified symbol leaves 2⁴=16 strings, each pair missing leaves 1⁴=1, and all three missing gives zero. Thus 81−3·16+3=36. Alternatively the only positive multiplicity pattern is 2,1,1: choose the repeated symbol in three ways, choose its two positions in C(4,2)=6 ways, and order the remaining two distinct symbols in 2!=2 ways. Total 3·6·2=36. Choosing the repeated symbol without choosing positions omits valid words.

G7. The threshold is 4(5−1)+1=17. If every box held at most four, the total would be at most 16, so 17 forces at least five somewhere. At 16 the distribution 4,4,4,4 avoids five. It is therefore the least forcing count when every destination is allowed.

G8. Capacities sum to 2+4+1=7; eight forces an overflow because a capacity-respecting total cannot exceed seven. At seven, 2,4,1 attains the capacities and proves sharpness. If three objects are each allowed only in the first box, total three is below seven but cannot respect capacity two in that box. Empty space in inaccessible boxes does not make the assignment feasible.

Independent practice

I1. The unrestricted count is 560, as in G1. Fix A in the first group and B in the third. Of the six remaining distinct cards, allocate 2,3,1 to the labelled groups, giving 6!/(2!3!1!)=60. Equivalently C(6,2)C(4,3)=15·4=60. No extra ordering of A or B is introduced within their groups.

I2. All words: 6!/(3!2!)=60. Arrange the non-A letters B,B,C first in 3!/2!=3 ways. There are four gaps: before, between the two consecutive pairs of positions, and after those three letters. Choose three distinct gaps for one A each, C(4,3)=4 choices. Total 12. At most one A per gap prevents adjacency, and every valid word decodes uniquely by deleting As and noting their gaps. The As are identical, so permuting hidden A labels would create duplicates and is not an additional factor.

I3. Single counts are 45,30,18; pair counts are 15,9,6 for divisibility by 6,10,15; triple count is 3 for 30,60,90. Thus S₁=93, S₂=30, S₃=3. At least one: 93−30+3=66. Exactly one: 93−60+9=42. Exactly two: 30−9=21. Neither: 90−66=24. Check 42+21+3+24=90, with every integer in exactly one class.

I4. Missing-symbol inclusion–exclusion gives 4⁵−4·3⁵+6·2⁵−4·1⁵+0=1024−972+192−4=240. The all-four-missing intersection is empty for positive length. Alternatively all four symbols must occur, so the multiplicities are 2,1,1,1. Choose the repeated symbol in four ways and arrange its two identical copies with the other three: 4·5!/2!=240. Onto requires positive class sizes, which need not be equal; equal sizes would be impossible for five positions and four symbols.

I5. A specified j-set of fixed positions leaves (4−j)! permutations. The number of choices of those positions is C(4,j). Inclusion–exclusion gives 4!−4·3!+6·2!−4·1!+1·0!=24−24+12−4+1=9. Three fixed positions do force the fourth, but that makes the intersection contain the identity permutation, not no permutations. Different triple intersections can contain the same object; inclusion–exclusion is designed to account for this overlap.

I6. Some box has at least ceil(26/6)=5 objects. Counts 5,5,4,4,4,4 sum to 26 and achieve maximum five, so six is not forced. To force six requires 6(6−1)+1=31; at 30, six boxes each holding five avoid six. These witnesses are admissible under unrestricted assignments.

I7. Capacity sum is 1+3+4+2=10, so eleven forces at least one violation. Filling to 1,3,4,2 at ten proves the threshold is sharp. A particular named box need not overflow: leave it empty and place the excess elsewhere. The statement is “for every assignment, some box overflows,” not “there is a named box that overflows in every assignment.” No capacity-respecting assignment exists at eleven, but assignments with violations still exist.

I8. No such sets exist. The triple intersection is a subset of B∩C, so it cannot have three elements when B∩C has only two. Equivalently the region “B and C but not A” would have size 2−3=−1. Blind substitution produces 8+7+6−4−3−2+3=15, but this arithmetic is not evidence that the impossible input describes a set system.

Homework

H1. Require n≥0 and r≥1 integers, with nonnegative integer k_i summing to n, distinct objects and labelled classes. Successive choices of disjoint member sets give C(n,k₁)C(n−k₁,k₂)⋯, whose factorials cancel to n!/∏k_i!. For a second proof, take all n! orderings, cut into labelled blocks with the prescribed lengths, then erase internal block order. Every allocation is reachable by ordering each block; exactly ∏k_i! orderings produce it. A zero block has one empty ordering and contributes 0!=1. When n=0 all blocks are empty and the count is one. Forgetting class labels changes the target equality relation and may create different fibre sizes; identical empty blocks or name-specific restrictions mean an r! divisor is not automatic.

H2. Fix an object lying in q≥1 named sets, and consider subsets of those q names. Choose one such name a; the map J↦J△{a} toggles a, reverses itself and switches parity. Thus its pairs have opposite contributions when odd subsets count +1 and even subsets −1. The total over all subsets is zero. The empty subset has contribution −1 and is omitted from inclusion–exclusion, so the nonempty total is +1. If q=0 there are no nonempty name selections and the contribution is zero. Summing over all objects proves the finite many-set union rule. For three sets, exactly-one weighting is S₁−2S₂+3S₃: contributions for q=0,1,2,3 are 0,1,2−2=0,3−6+3=0. With four memberships the same truncated expression would give 4−12+12=4 rather than zero, so it is not the four-set rule.

H3. If k boxes each contain at most r−1 objects, their sum is at most k(r−1). Hence one more forces at least r in some box. Conversely k(r−1) objects can be split with exactly r−1 in each box. This proves minimality, including r=1 where the one-below total is zero. For nonnegative capacities c_i, the same sum argument gives total at most Σc_i; unrestricted assignments attain it by filling each box to its capacity, so Σc_i+1 is sharp. If destinations are restricted, take capacities 2,4,1 and three objects allowed only in the first box. Total capacity exceeds three but no capacity-respecting assignment exists. The sum condition remains necessary; its sufficiency was conditional on unrestricted destinations.

H4. Six distinct objects allocated to three labelled boxes with exactly two per box have 6!/(2!2!2!)=90 assignments. Every assignment has occupancies 2,2,2, so none has three in a box. Pigeonhole applies to six objects across three boxes within one assignment, guaranteeing at least two somewhere. Here the prescribed capacities give the stronger fact that every box has exactly two. The number 90 counts alternative complete assignments, not objects inside one assignment.

Quiz key and rubric: 32 points

Q1 (8). All words: 6!/(2!2!2!)=90. With first A fixed, arrange A,B,B,C,C in 5!/(2!2!)=30 ways. Exclude those also ending A, whose middle is B,B,C,C in 4!/(2!2!)=6 ways, leaving 24. Alternatively choose last B or C. For last B, the middle A,B,C,C has 4!/2!=12 arrangements; last C similarly gives 12. The two final-letter cases are disjoint, giving 24. Factorials in the denominator erase permutations of identical letter copies, not positions. Rubric: 2 for full count/interpretation, 2 for first-A count and overlap subtraction, 2 for the last-letter case count, 2 for denominator and coverage justification.

Q2 (8). There are 4⁵=1024 candidate strings. Single missing-symbol conditions have 3⁵=243 members, pair intersections 2⁵=32, triple intersections 1⁵=1, and all four missing is impossible for length five. Thus 1024−4·243+6·32−4·1+0=240. The pattern proof is 4·5!/2!=240 for repeated-symbol choice and arrangement of multiplicities 2,1,1,1. The all-empty intersection has zero functions from a nonempty set of positions to an empty alphabet; the empty-position case is a separate model. Rubric: 3 for complete intersection-level derivation, 3 for the independently justified pattern count, 2 for positive-length boundary and correct object/equality meaning.

Q3 (8). The sharp lower bound is four. If every queue had at most three, only 15 objects could fit; the 17-object witness 4,4,3,3,3 shows five is not forced. Unequal capacities sum to 11, so twelve forces a violation; occupancy 2,4,5 at eleven attains the capacity total. Both proofs assert existence of some qualifying box and do not fix its identity. Rubric: 2 for lower-bound proof, 2 for valid 17-object sharpness witness, 2 for overflow threshold and one-below witness, 2 for unrestricted-destination and quantifier explanation.

Q4 (8). Triple region ABC=3. Pair-only regions are AB-only=7−3=4, AC-only=5−3=2, BC-only=4−3=1. Single-only regions are A-only=12−7−5+3=3, B-only=10−7−4+3=2 and C-only=9−5−4+3=3. These seven regions sum to 18, so neither=2. Exactly one=3+2+3=8. Feasibility follows by taking twenty distinct elements and splitting them into disjoint blocks labelled A-only, B-only, C-only, AB-only, AC-only, BC-only, ABC and neither, of respective sizes 3,2,3,4,2,1,3,2. Define A,B,C by those indicated memberships; this reconstructs the stated totals. Changing only the triple to 5 makes BC-only=4−5=−1, contradicting containment. Rubric: 3 for all eight nonnegative region counts, 2 for union/exactly-one, 2 for a region-based realization with reconstruction reasoning, 1 for the changed-data impossibility.

Project key and rubric: 40 points

P1 (10). Choose distinct destinations for A and B in 3·2=6 ways. The other four records may use any queue, but the still-unused third queue must receive at least one. There are 3⁴−2⁴=65 choices, giving 390 assignments. Alternatively all onto assignments number 3⁶−3·2⁶+3=729−192+3=540. If A and B share a queue, collapse them into one distinguished block, leaving five distinct assignment objects (AB),C,D,E,F. Onto assignments of these objects number 3⁵−3·2⁵+3=150. Expanding the block reverses the encoding, so 540−150=390. Positive occupancy does not prescribe equal sizes; 4,1,1, for example, can satisfy the original rules. Rubric: 3 for fixed-A/B method and unused-queue condition, 3 for onto-minus-collapse method, 2 for reversible model/coverage, 2 for total and distinction between positive/equal sizes.

P2 (10). Since all three queues are nonempty and there are six records, an over-capacity queue can hold at most four. A violation must therefore have pattern 4,1,1, with one unique large queue. Choose it in three ways. It cannot contain both A and B. If it contains exactly one, choose which in two ways, choose its three other records from C,D,E,F in four ways, and assign the remaining two records to the two singleton queues in two ways: 3·2·4·2=48. If it contains neither, its contents are exactly C,D,E,F; assign A and B to the singleton queues in two ways, giving 3·2=6. Total removed is 54, leaving 390−54=336.

For a second count, capacity-respecting positive patterns are 3,2,1 and 2,2,2. For 3,2,1, choose which named queue has each size in 3!=6 ways. For fixed size labels, total assignments are 6!/(3!2!1!)=60. Invalid A/B-together assignments: both in the size-three queue give 4 choices for its third record and C(3,2)=3 for the size-two queue, hence 12; both in the size-two queue give C(4,3)=4 choices for the size-three queue. Thus each size labelling has 60−12−4=44 valid assignments, giving 264. For 2,2,2, all labelled assignments number 90. To put A/B together, choose their queue in three ways and split the four others between the two remaining labelled queues in C(4,2)=6 ways, giving 18 invalid and 72 valid. Total 264+72=336. Rubric: 3 for exhaustive removed-pattern cases/54, 2 for retained total, 3 for independent pattern counts 264/72, 2 for justified label factors and case coverage.

P3 (10). In the capacity-three model, each target is a collection of three nonempty disjoint record sets. Every target has six assignments of its distinct member sets to X,Y,Z. Capacity bounds, positivity and A/B separation do not depend on names. Therefore 336/6=56 targets. Now require A in X. For each of those same targets, its unique A-containing member set must receive X, and the other two sets can receive Y,Z in two ways. Every target remains reachable, with fibre size two; there are 56·2=112 named assignments and still 56 targets. Dividing 112 by six would be unjustified; use 112/2. Equivalently symmetry of the three destination names makes exactly one-third of the 336 assignments put A in X. Rubric: 3 for original target count and six valid labellings, 3 for restricted source/target counts and two valid labellings, 2 for reachability, 2 for explaining why a prior denominator cannot be carried over.

P4 (10). Six objects across three queues force maximum occupancy at least two. A valid sharpness example is X={A,C}, Y={B,D}, Z={E,F}, so at least three is not forced. For nine records A,B,C,D,E,F,G,H,I, use X={A,C,D}, Y={B,E,F}, Z={G,H,I}. This meets positivity, capacities and A/B separation. Ten cannot be assigned while respecting three capacity-three limits because total capacity is nine. This is an impossibility of a capacity-respecting assignment, not a claim about what a real system does with a rejected record.

The audit should define a canonical destination tuple for six named records, filter the exact rules, count once per tuple and group by unordered member sets for the quotient. Exhaustive enumeration checks the finite counts 390,336,112 and the fibre sizes for those instances. The universal sum and constant-fibre arguments supply their stated proofs; sampled examples do not. Neither method establishes actual waiting times, software queue meanings, arrival rates or probabilities without additional definitions/data. Rubric: 3 for six-record bound and admissible sharpness example, 3 for nine-record construction/ten-record impossibility, 2 for auditable finite model and counting checks, 2 for distinguishing proof and model/performance limits.

Delayed follow-through

D1. Choose the distinct first two symbols in 3·2=6 ways. The last two positions must include the third symbol at least once, giving 3²−2²=5 possibilities. Total 30. Alternatively all length-four onto strings number 36. When the first two symbols coincide, collapse those two positions into one: the resulting three positions must use all three symbols, giving 3!=6 strings. Expand the first position back into a repeated pair to invert the encoding. Therefore 36−6=30. The collapsed block is a position in the encoded string, not an unordered choice of two positions.

D2. An adequate correction names the original unsupported step, the needed hypothesis, a repair and a changed-data check. For the fallback, 15 objects admit counts 3,3,3,3,3, so four is not forced. The correct guaranteed largest occupancy is three. To force four requires 5(4−1)+1=16; no five boxes each of size at most three can hold 16. The 15-object distribution proves minimality. Changing to four boxes would give threshold 13, with 3,3,3,3 at twelve as the avoiding witness.

Feedback use

Accept equivalent correct encodings, intersections, constructions and audits. Give method credit when subsequent arithmetic consistently follows an isolated earlier arithmetic slip, while separately flagging invalid universes, missing cases, false constant-fibre assumptions and quantifier mistakes. Do not convert these formative points into a reliable semester mark or mastery certificate. Assessment calibration and learner transfer/timing evidence remain unfinished.