To solve the problem of finding the number of functions from set A to set B that are not one-to-one and include the value 2 in their range, we can break it down into steps.
### Step-by-Step Solution:
1. **Identify the Sets**:
- Let \( A = \{a, b, c\} \) (3 elements)
- Let \( B = \{1, 2, 3, 4\} \) (4 elements)
2. **Total Functions from A to B**:
- The total number of functions from set A to set B is given by \( |B|^{|A|} \).
- Here, \( |B| = 4 \) and \( |A| = 3 \).
- Thus, the total number of functions is \( 4^3 = 64 \).
3. **Functions that are One-to-One**:
- A one-to-one function from A to B can only be formed if the number of elements in A is less than or equal to the number of elements in B.
- The number of one-to-one functions can be calculated using permutations of the elements in B taken |A| at a time, which is \( P(4, 3) = 4!/(4-3)! = 4! = 24 \).
4. **Functions that are Not One-to-One**:
- To find the number of functions that are not one-to-one, we subtract the number of one-to-one functions from the total functions:
- Number of not one-to-one functions = Total functions - One-to-one functions = \( 64 - 24 = 40 \).
5. **Functions that Include 2 in the Range**:
- We need to ensure that the value 2 is included in the range of the functions.
- We can approach this by using complementary counting. First, we find the number of functions that do not include 2 in their range.
6. **Functions Excluding 2**:
- If we exclude 2 from B, we have \( B' = \{1, 3, 4\} \) (3 elements).
- The total number of functions from A to \( B' \) is \( 3^3 = 27 \).
7. **Functions Including 2**:
- The number of functions that include 2 in their range is then:
- Functions including 2 = Total functions - Functions excluding 2 = \( 64 - 27 = 37 \).
8. **Final Count of Not One-to-One Functions Including 2**:
- Now, we need to find the number of not one-to-one functions that include 2.
- From the previous step, we found that there are 40 not one-to-one functions in total, and 27 of these do not include 2.
- Therefore, the number of not one-to-one functions that include 2 is:
- Not one-to-one functions including 2 = Total not one-to-one functions - Not one-to-one functions excluding 2 = \( 40 - 27 = 13 \).
### Conclusion:
The total number of functions from A to B that are not one-to-one and include the value 2 in their range is **13**.