Find the number of possible functions from one set to another

  • Thread starter Thread starter HaRgIlIN
  • Start date Start date
  • Tags Tags
    Functions Set
Click For Summary
The discussion focuses on calculating the number of functions from one set to another under various conditions. The total number of unrestricted functions is given by n^m, while specific conditions, such as excluding certain values or ensuring at least one occurrence of a value, lead to derived formulas. The calculations for functions that exclude values 1 and 2, as well as those that include them at least once, are thoroughly examined. The final formula for part (d) consolidates these findings, confirming the accuracy of the derived expressions. Overall, the analysis appears correct and comprehensive.
HaRgIlIN
Messages
2
Reaction score
0
Homework Statement
Consider ##S_m = \{1, 2, 3, . . . , m\}## and ##S_n = \{1, 2, 3, . . . , n\}## with ##m, n \geq 3##.

(a) How many functions ##f## are there from ##S_m## to ##S_n## such that ##f(x) = 1## for at least one ##x \in S_m##?

(b) How many functions ##f## are there from ##S_m## to ##S_n## such that ##f(x) \in \{1, 2\}## for at least one ##x \in S_m##?

(c) How many functions ##f## are there from ##S_m## to ##S_n## such that ##f(x) = 1## for at least one ##x \in S_m## and ##f(y) \neq 2## for any ##y \in S_m##?

(d) How many functions ##f## are there from ##S_m## to ##S_n## such that ##f(x) = 1## for at least one ##x \in S_m## and ##f(y) = 2## for at least one ##y \in S_m##?
Relevant Equations
N/A
I have tried to solve them. I would like to know if my answers are correct.

(a)
The total number of functions without any restrictions
##=n^m##

The number of functions such that ##f(x)## is never ##1##
##=(n-1)^m##

The number of functions such that ##f(x)=1## for at least one ##x\in S_m##
##=n^m-(n-1)^m##

(b)
The number of functions such that ##f(x) \notin \{1,2\}##
##=(n-2)^m##

The number of functions such that ##f(x)\in \{1,2\}## for at least one ##x\in S_m##
##=n^m-(n-2)^m##

(c)
Total number of functions such that ##f(y)\neq 2## for any ##y\in S_m##
##=(n-1)^m##

Number of functions such that ##f(x)## is never ##1## and and ##f(y)## is never ##2##
##=(n-2)^m##

Number of functions that satisfy the requirements in this part
##=(n-1)^m-(n-2)^m##

(d)
Since the answer from part (b) includes:

-The number of functions such that ##f(x)=1## for at least one ##x\in S_m## and ##f(y)\neq 2## for any ##y\in S_m##; (which is just part(c))

-The number of functions such that ##f(x)=2## for at least one ##x\in S_m## and ##f(y)\neq 1## for any ##y\in S_m##; (the number is equivalent to part(c)) and

-The number of functions such that ##f(x)=1## for at least one ##x\in S_m## and ##f(y)=2## for at least one ##y\in S_m##

Answer for part (d) is just ##[##part(b)##-2\times##part(c)##]##
Hence,
the number of functions
##=n^m-(n-2)^m-2\times[(n-1)^m-(n-2)^m]##
##=n^m-2(n-1)^m+(n-2)^m##
 
Physics news on Phys.org
All looks good.
 
haruspex said:
All looks good.

Thank you for your help.
 
Question: A clock's minute hand has length 4 and its hour hand has length 3. What is the distance between the tips at the moment when it is increasing most rapidly?(Putnam Exam Question) Answer: Making assumption that both the hands moves at constant angular velocities, the answer is ## \sqrt{7} .## But don't you think this assumption is somewhat doubtful and wrong?

Similar threads

  • · Replies 3 ·
Replies
3
Views
893
Replies
1
Views
2K
Replies
8
Views
2K
Replies
3
Views
2K
  • · Replies 8 ·
Replies
8
Views
2K
  • · Replies 20 ·
Replies
20
Views
3K
Replies
3
Views
2K
  • · Replies 3 ·
Replies
3
Views
2K
  • · Replies 6 ·
Replies
6
Views
2K
  • · Replies 11 ·
Replies
11
Views
1K