Question:easy

If \[ f(x)=\max\{\sin x,\cos x\} \] and \[ g(x)=\min\{\sin x,\cos x\}, \] then \[ \int_0^{\pi} f(x)\,dx+\int_0^{\pi} g(x)\,dx= \]

Show Hint

For any two quantities \(a\) and \(b\), always remember that \(\max(a,b)+\min(a,b)=a+b\). This identity avoids unnecessary case-wise integration.
Updated On: Jun 22, 2026
  • \(2\sqrt{2}+2\)
  • \(2\sqrt{2}-2\)
  • \(2\)
  • \(2\sqrt{2}\)
Show Solution

The Correct Option is C

Solution and Explanation

Step 1: Use the max-plus-min identity.
For any two numbers, $\max\{a,b\}+\min\{a,b\}=a+b$. With $a=\sin x$ and $b=\cos x$, we get $f(x)+g(x)=\sin x+\cos x$.
Step 2: Combine the two integrals.
Therefore $\int_0^{\pi} f\,dx+\int_0^{\pi} g\,dx=\int_0^{\pi}\big(f(x)+g(x)\big)\,dx=\int_0^{\pi}(\sin x+\cos x)\,dx$.
Step 3: Integrate $\sin x$.
$\int_0^{\pi}\sin x\,dx=\big[-\cos x\big]_0^{\pi}=-\cos\pi+\cos 0=1+1=2$.
Step 4: Integrate $\cos x$.
$\int_0^{\pi}\cos x\,dx=\big[\sin x\big]_0^{\pi}=\sin\pi-\sin 0=0$.
Step 5: Add the parts.
The total is $2+0=2$.
Step 6: Conclude.
Hence the required sum of integrals equals $2$, matching the key. \[ \boxed{2} \]
Was this answer helpful?
0