Detailed Explanation
A function \( f \) is continuous at a point \( x = a \) if three conditions hold: the function is defined at \( a \), the limit \( \lim_{x \to a} f(x) \) exists, and this limit equals \( f(a) \). For a piecewise function, the limit exists only when the left-hand limit (LHL) equals the right-hand limit (RHL). Here the rule for \( f \) changes at \( x = \pi \): for \( x \le \pi \) we use \( kx + 1 \) and for \( x > \pi \) we use \( \cos x \). To make \( f \) continuous at \( x = \pi \), we force the two pieces to meet, which gives an equation we solve for \( k \).
Formula Used
\( f \) is continuous at \( x = a \) if \[ \lim_{x \to a^-} f(x) = \lim_{x \to a^+} f(x) = f(a) \]
Solution
- Step 1: Identify the value of the function at the point. Since \( x = \pi \) satisfies \( x \le \pi \), we use the first piece: \[ f(\pi) = k\pi + 1 \]
- Step 2: Find the left-hand limit (LHL). For \( x \le \pi \), the function is \( kx + 1 \), so \[ \lim_{x \to \pi^-} f(x) = \lim_{x \to \pi^-} (kx + 1) = k\pi + 1 \]
- Step 3: Find the right-hand limit (RHL). For \( x > \pi \), the function is \( \cos x \), so \[ \lim_{x \to \pi^+} f(x) = \lim_{x \to \pi^+} \cos x = \cos \pi = -1 \]
- Step 4: Apply the continuity condition. For continuity at \( x = \pi \), the LHL must equal the RHL (and both equal \( f(\pi) \)). Therefore \[ k\pi + 1 = -1 \]
- Step 5: Solve for \( k \). Rearranging the equation: \[ k\pi = -1 - 1 = -2 \] Hence \[ k = \frac{-2}{\pi} \]
Final Answer
\( k = -\dfrac{2}{\pi} \)
Common Mistake
A common mistake is writing \( \cos \pi = 1 \) instead of the correct value \( \cos \pi = -1 \), which leads to the wrong value of \( k \). Always evaluate the trigonometric value carefully at the given point.