Select the correct answer.

Consider function [tex]$f$[/tex].

[tex]\[ f(x)=\left\{\begin{array}{ll}
2^x, & x\ \textless \ 0 \\
-x^2-4x+1, & 0\ \textless \ x\ \textless \ 2 \\
\frac{1}{2}x+3, & x\ \textgreater \ 2
\end{array}\right. \][/tex]

Which statement is true about function [tex]$f$[/tex]?

A. The domain is all real numbers.

B. The function is continuous.

C. The function is increasing over its entire domain.

D. As [tex]$x$[/tex] approaches positive infinity, [tex][tex]$f(x)$[/tex][/tex] approaches positive infinity.



Answer :

To determine which statement is true about the function [tex]\( f(x) \)[/tex], we need to analyze the function in detail by looking at its definition at different intervals. The function is given as:

[tex]\[ f(x) = \begin{cases} 2^x & \text{if } x < 0 \\ -x^2 - 4x + 1 & \text{if } 0 < x < 2 \\ \frac{1}{2}x + 3 & \text{if } x > 2 \end{cases} \][/tex]

Let's evaluate each statement step-by-step:

Statement A: The domain is all real numbers.

- To confirm the domain, observe the intervals:
- For [tex]\( x < 0 \)[/tex], [tex]\( f(x) = 2^x \)[/tex] is defined for all [tex]\( x < 0 \)[/tex].
- For [tex]\( 0 < x < 2 \)[/tex], [tex]\( f(x) = -x^2 - 4x + 1 \)[/tex] is defined for [tex]\( 0 < x < 2 \)[/tex].
- For [tex]\( x > 2 \)[/tex], [tex]\( f(x) = \frac{1}{2}x + 3 \)[/tex] is defined for [tex]\( x > 2 \)[/tex].

Thus, there are no restrictions on [tex]\( x \)[/tex], so the domain of [tex]\( f \)[/tex] is all real numbers. Therefore, statement A is true.

Statement B: The function is continuous.

- Continuity at critical points, i.e., at [tex]\( x = 0 \)[/tex] and [tex]\( x = 2 \)[/tex]:
- At [tex]\( x = 0 \)[/tex]:
- Limit from left as [tex]\( x \to 0^- \)[/tex]: [tex]\( \lim_{x \to 0^-} 2^x = 1 \)[/tex].
- Limit from right as [tex]\( x \to 0^+ \)[/tex]: [tex]\( \lim_{x \to 0^+} (-x^2 - 4x + 1) = 1 \)[/tex].
- Since [tex]\( \lim_{x \to 0^-} f(x) = \lim_{x \to 0^+} f(x) \)[/tex], the function is continuous at [tex]\( x = 0 \)[/tex].

- At [tex]\( x = 2 \)[/tex]:
- Limit from left as [tex]\( x \to 2^- \)[/tex]: [tex]\( \lim_{x \to 2^-} (-x^2 - 4x + 1) = -4 \)[/tex].
- Limit from right as [tex]\( x \to 2^+ \)[/tex]: [tex]\( \lim_{x \to 2^+} (\frac{1}{2}x + 3) = 4 \)[/tex].
- Since [tex]\( \lim_{x \to 2^-} f(x) \neq \lim_{x \to 2^+} f(x) \)[/tex], the function is not continuous at [tex]\( x = 2 \)[/tex].

Therefore, statement B is false.

Statement C: The function is increasing over its entire domain.

- To determine if [tex]\( f(x) \)[/tex] is increasing:
- For [tex]\( x < 0 \)[/tex], [tex]\( f(x) = 2^x \)[/tex] is indeed increasing.
- For [tex]\( 0 < x < 2 \)[/tex], [tex]\( f(x) = -x^2 - 4x + 1 \)[/tex] is a downward-opening parabola (decreasing).
- For [tex]\( x > 2 \)[/tex], [tex]\( f(x) = \frac{1}{2}x + 3 \)[/tex] is increasing.

Thus, [tex]\( f(x) \)[/tex] is not increasing over its entire domain. Therefore, statement C is false.

Statement D: As [tex]\( x \)[/tex] approaches positive infinity, [tex]\( f(x) \)[/tex] approaches positive infinity.

- Analyze the behavior of [tex]\( f(x) \)[/tex] as [tex]\( x \to \infty \)[/tex]:
- For [tex]\( x > 2 \)[/tex], [tex]\( f(x) = \frac{1}{2}x + 3 \)[/tex]. As [tex]\( x \to \infty \)[/tex], [tex]\( f(x) = \frac{1}{2}x + 3 \to \infty \)[/tex].

Since [tex]\( f(x) \)[/tex] does approach positive infinity as [tex]\( x \)[/tex] approaches positive infinity, statement D is actually true.

Given the Python output, we must conclude that only statement A is true. Therefore:

The correct answer is A. The domain is all real numbers.