Courses
Courses for Kids
Free study material
Offline Centres
More
Store Icon
Store
seo-qna
SearchIcon
banner

Let \[f(x)=-1+|x-1|,-1\le x\le 3\] and \[g(x)=2-|x+1|,-2\le x\le 2\] then $(fog)(x)$, is equal to
A. \[\left\{ \begin{matrix}
   x+1\,\,\,\,\,\,\,\,-2\le x\le 0 \\
   x-1\,\,\,\,\,\,\,\,0<\,\,x\le 2 \\
\end{matrix} \right.\]
B. \[\left\{ \begin{matrix}
   x-1\,\,\,\,\,\,\,\,-2\le x\le 0 \\
   x+1\,\,\,\,\,\,\,\,0<\,\,x\le 2 \\
\end{matrix} \right.\]
C. \[\left\{ \begin{matrix}
   -1-x\,\,\,\,\,\,\,\,-2\le x\le 0 \\
   x-1\,\,\,\,\,\,\,\,0<\,\,x\le 2 \\
\end{matrix} \right.\]
D. None of these.

Answer
VerifiedVerified
162.6k+ views
Hint: To solve this question, we need to determine the value of the composite function $\left( fog \right)(x)$. First we will write both the functions as piecewise functions because both have absolute functions present.
The composite function $\left( fog \right)(x)$ can be calculated by determining $f(g(x))$ that is $\left( fog \right)(x)=f(g(x))$. We will substitute the value of the term $x$ in $g(x)$ and then substitute the value of $g(x)$ in $f(x)$.

Complete step by step solution: We are given two functions \[f(x)=-1+|x-1|,-1\le x\le 3\], \[g(x)=2-|x+1|,-2\le x\le 2\] and we have to find the value of $(fog)(x)$.
As we know that a modulus function $f(x)=|x|$ always gives a non-negative result irrespective of the sign .Then if the value of $x$ is negative, the function will give a same magnitude as $x$ but different sign that is $f(x)=-x$ and if value of $x$ is positive then the function will have similar value as $x$ that is $f(x)=x$ and is depicted as piecewise function as\[f(x)=|x|=\left\{ \begin{matrix}
   x,x\ge 0 \\
   -x,x<0 \\
\end{matrix} \right.\].
The piecewise function of \[f(x)=-1+|x-1|,-1\le x\le 3\] is,
\[f(x)=\left\{ \begin{array}{*{35}{l}}
   -1-(x-1) & -1\le x\le 1 \\
   -1+(x-1) & 1\le x\le 3 \\
\end{array} \right.\]
\[f(x)=\left\{ \begin{align}
  & x,-1\le x\le 1 \\
 & x-2,1\le x\le 3 \\
\end{align} \right.\]
The piecewise function of \[g(x)=2-|x+1|,-2\le x\le 2\] is,
\[g(x)=\left\{ \begin{array}{*{35}{l}}
   2+(x-1) & -2\le x\le -1 \\
   2-(x-1) & -1\le x\le 2 \\
\end{array} \right.\]
\[g(x)=\left\{ \begin{array}{*{35}{l}}
   x+3 & -2\le x\le -1 \\
   1-x & -1\le x\le 2 \\
\end{array} \right.\]
We will now calculate $\left( fog \right)(x)=f(g(x))$.
\[f(g(x))=\left\{ \begin{array}{*{35}{l}}
   -g(x) & -1\le g(x)\le 1 \\
   g(x)-2 & 1\le g(x)\le 3 \\
\end{array} \right.\]
\[f(g(x))=\left\{ \begin{array}{*{35}{l}}
   -(x+3) & -2\le x\le 1,-2\le 3+x\le 1 \\
   (3+x)-2 & -2\le x\le 1,1\le (3+x)\le 3 \\
\end{array} \right.\]
\[f(g(x))=\left\{ \begin{array}{*{35}{l}}
   -(x+3) & -2\le x\le -1,-4\le x\le -2 \\
   (1+x) & -2\le x\le -1,-2\le x\le 0 \\
   (x-1) & -1\le x\le 2,0\le x\le 2 \\
   -(1+x) & -2\le x\le -1,-2\le x\le 0 \\
\end{array} \right.\]
We can see that the function $\left( fog \right)(x)$ is continuous at $x=-1$ which is not present in any of the options given. Therefore, the correct option will be none of the above.

The value of $\left( fog \right)(x)$ is \[(fog)(x)=\left\{ \begin{align}
  & -(x+3),\,\,\,\,-2\le x\le -1,-4\le x\le -2 \\
 & (1+x),\,\,\,\,\,\,\,\,-2\le x\le -1,-2\le x\le 0 \\
 & (x-1),\,\,\,\,\,\,\,\,\,-1\le x\le 2,0\le x\le 2 \\
 & -(1+x),\,\,\,\,\,-2\le x\le -1,-2\le x\le 0\,\,\, \\
\end{align} \right.\]when \[f(x)=-1+|x-1|,-1\le x\le 3\] and \[g(x)=2-|x+1|,-2\le x\le 2\]. Hence the correct option is (D).


Note: The composite function $(fog)(x)$ is read as “$f$ of $g$ of $x$”. The domain of this function will contain all those inputs for which the function $g(x)$ is in the domain of $f$ while the range of this function will be the intersection of the ranges inner and outer function.