A B = = { 1 , 2 , 3 , 4 , 5 } { 6 , 7 , 8 , 9 , 1 0 }
Let f : A → B be a function defined on the sets above.
Find the number of non-decreasing functions f .
This section requires Javascript.
You are seeing this because something didn't load right. We suggest you, (a) try
refreshing the page, (b) enabling javascript if it is disabled on your browser and,
finally, (c)
loading the
non-javascript version of this page
. We're sorry about the hassle.
Perfect solution! Thanks. Umm.. maybe I'm wrong, but shouldn't it be ( 4 9 ) ?
Log in to reply
Thanks! Going by Theorem two in the link it would be ( 5 9 ) , but of course that is exactly the same as ( 4 9 ) . :)
Log in to reply
Yes, I do realize that ( 4 9 ) = ( 5 9 ) . But the equation that I remember is ( r − 1 n + r − 1 ) for n stars and r bins. Seems that you use ( n n + r − 1 ) ... Again, old habits die hard ;)
Log in to reply
@Raghav Vaidyanathan – Haha. Yes, they do. :) I was just trying to be consistent with the link, but at this point I can no longer recall whether I first learned it as the link's version or your version.
Let N ( n , m ) denote the number of such non-decreasing functions f : { 1 , 2 , … , n } → B such that f ( n ) = m ( m ≥ 6 ). Then because of non-decreasing property of f , we have f ( n ) ≥ f ( n − 1 ) . Hence, N ( n , m ) = k = 6 ∑ m N ( n − 1 , k ) with the initial conditions N ( 1 , m ) = 1 , N ( n , 6 ) = 1 ∀ m ≥ 6 , n . The above recursion can be solved either analytically or computationally ( we just need to fill up a 5 × 5 table). We require m = 6 ∑ 1 0 N ( 5 , m ) = 1 2 6
Problem Loading...
Note Loading...
Set Loading...
Let a k for 6 ≤ k ≤ 1 0 be the number of (unspecified) elements of A that f maps to element k of B . Then there is a one-to-one correspondence between the set of non-decreasing functions f and the set of non-negative integer solutions to the equation
a 6 + a 7 + a 8 + a 9 + a 1 0 = 5 , (A).
(This is because for any solution to (A), there will be only one way to then form the mapping f , and any non-decreasing mapping corresponds to a unique solution of (A). For example, the solution a 6 = 0 , a 7 = 2 , a 8 = a 9 = a 1 0 = 1 corresponds to the mapping f ( 1 ) = f ( 2 ) = 7 , f ( 3 ) = 8 , f ( 4 ) = 9 and f ( 5 ) = 1 0 . )
This is now a stars and bars calculation, and according to Theorem two in the link the number of solutions to (A), and hence the number of non-decreasing functions f , is
( 5 5 + 5 − 1 ) = ( 5 9 ) = 1 2 6 .