To solve the problem, we need to analyze the function given by:
\[ f(x) = \prod_{i=1}^{3} (x - a_i) + \sum_{i=1}^{3} a_i - 3x \]
where \( a_1 < a_2 < a_3 \).
### Step 1: Understanding the Function
The function consists of two parts:
1. The product term \( \prod_{i=1}^{3} (x - a_i) \), which is a cubic polynomial that has roots at \( x = a_1, a_2, a_3 \).
2. The linear term \( \sum_{i=1}^{3} a_i - 3x \), which is a linear function of \( x \).
### Step 2: Analyzing the Roots
To find the roots of \( f(x) = 0 \), we will evaluate the function at the points \( a_1, a_2, \) and \( a_3 \).
1. **Evaluate \( f(a_1) \)**:
\[
f(a_1) = \prod_{i=1}^{3} (a_1 - a_i) + \sum_{i=1}^{3} a_i - 3a_1
\]
The product term becomes zero since \( (a_1 - a_1) = 0 \). Thus,
\[
f(a_1) = 0 + (a_1 + a_2 + a_3 - 3a_1) = a_2 + a_3 - 2a_1
\]
Since \( a_2 > a_1 \) and \( a_3 > a_1 \), we have \( a_2 + a_3 - 2a_1 > 0 \). Therefore, \( f(a_1) > 0 \).
2. **Evaluate \( f(a_2) \)**:
\[
f(a_2) = \prod_{i=1}^{3} (a_2 - a_i) + \sum_{i=1}^{3} a_i - 3a_2
\]
Again, the product term becomes zero since \( (a_2 - a_2) = 0 \). Thus,
\[
f(a_2) = 0 + (a_1 + a_2 + a_3 - 3a_2) = a_1 + a_3 - 2a_2
\]
Here, \( a_1 < a_2 < a_3 \) implies \( a_1 - 2a_2 + a_3 \) could be positive or negative, so we cannot conclude the sign of \( f(a_2) \).
3. **Evaluate \( f(a_3) \)**:
\[
f(a_3) = \prod_{i=1}^{3} (a_3 - a_i) + \sum_{i=1}^{3} a_i - 3a_3
\]
The product term becomes zero since \( (a_3 - a_3) = 0 \). Thus,
\[
f(a_3) = 0 + (a_1 + a_2 + a_3 - 3a_3) = a_1 + a_2 - 2a_3
\]
Since \( a_1 < a_2 < a_3 \), we have \( a_1 + a_2 < 2a_3 \), which implies \( f(a_3) < 0 \).
### Step 3: Conclusion from Evaluations
From the evaluations:
- \( f(a_1) > 0 \)
- \( f(a_2) \) is indeterminate
- \( f(a_3) < 0 \)
Since \( f(a_1) > 0 \) and \( f(a_3) < 0 \), by the Intermediate Value Theorem, there must be at least one root in the interval \( (a_1, a_3) \).
### Step 4: Behavior of the Function
The function \( f(x) \) is a cubic polynomial (since the leading term is \( x^3 \) from the product), and its end behavior is such that it goes to \( +\infty \) as \( x \to +\infty \) and \( -\infty \) as \( x \to -\infty \).
Given that it is continuous and changes signs, we can conclude that there are three distinct real roots.
### Final Answer
Thus, the function \( f(x) = 0 \) has **3 distinct real roots**.
---