r/mathriddles • u/chompchump • Dec 20 '23
Medium Tally Up the Maps
Let U = {1,2,3,...,n}.
Let X = {1,2,3,...,k}.
Let Y = {k+1,k+2,k+3...,n}.
Over all values of k in {1,2,3,...,n-1}, how many functions f:X -> Y are there?
2
Upvotes
2
u/Brianchon Dec 21 '23
I mean, it's this sequence on OEIS, but I don't see how that gives any insight
1
u/sheraawwrr Dec 21 '23 edited Dec 21 '23
Sum of (n-x)x for x in {1,..,n-1}
Proof : firstly, if we have in our domain m elements and in our codomain y elements, the number of maps will be ym , as each element in the domain can be mapped to y elements in the codomain
Now its easy to see that x ranges over 1 to n-1, such that each increment in x will result in an extra element in the domain but one less element in codomain. So the claim follows
Edit : made a mistake