Question:

Consider the function \(f:\mathbb{R}\to\mathbb{R}\) defined as follows:
\[f(x)=\begin{cases}c_1e^x-c_2\log_e\!\left(\frac1x\right),&x>0,\\3,&\text{otherwise},\end{cases}\]
where \(c_1,c_2\in\mathbb{R}\). If \(f\) is continuous at \(x=0\), then \(c_1+c_2=\underline{\hspace{1cm}}\).
(answer in integer)

Show Hint

For continuity, the right-hand limit as x tends to 0 must equal f(0)=3; since log_e x diverges at x=0, the coefficient of the log term must be zero.
Updated On: Aug 4, 2026
Show Solution
collegedunia
Verified By Collegedunia

Correct Answer: 3

Solution and Explanation

Step 1: For \(x>0\), \(f(x) = c_1 e^x - c_2 \log_e\left(\frac{1}{x}\right)\). Since \(\log_e\left(\frac{1}{x}\right) = -\log_e x\), this simplifies to \(f(x) = c_1 e^x + c_2 \log_e x\) for \(x>0\).

Step 2: Continuity of \(f\) at \(x=0\) requires \(\lim_{x \to 0^+} f(x) = f(0) = 3\).

Step 3: As \(x \to 0^+\), \(\log_e x \to -\infty\). If \(c_2 \neq 0\), the term \(c_2 \log_e x\) blows up to \(+\infty\) or \(-\infty\), so the limit would not be finite. Continuity therefore forces \(c_2 = 0\).

Step 4: With \(c_2 = 0\), \(\lim_{x \to 0^+} f(x) = \lim_{x \to 0^+} c_1 e^x = c_1 e^0 = c_1\).

Step 5: Setting this equal to \(f(0)=3\) gives \(c_1 = 3\). Therefore \(c_1 + c_2 = 3 + 0 = 3\).

Final Answer: \[\boxed{c_1 + c_2 = 3}\]

Was this answer helpful?
0
0

Top GATE CS Engineering Mathematics Questions

View More Questions