overrated3245w

2022-09-01

Find the inverse of a piecewise function, namely:
$f\left(x\right)=\left\{\begin{array}{ll}x-1,& 0\le x<1\\ 2-x,& 1
For the first case
$f:y=x-1$ when $0\le x<1\to {f}^{-1}:x=y+1$ when $-1\le x<0$
But I find this because I only have to subtract 1 from the endpoints of the inequality. I don't have a clear intuition how to do this with 2−x

### Answer & Explanation

lascosasdeali3v

Suppose that ${f}^{-1}$ there exists, then you have $f\left(x\right)=x-1$ when $0⩽x<1$ then setting $y=f\left(x\right)$ we get $y=x-1$ when $0⩽x<1$ then $x=y+1$ when $0⩽y+1<1$. Hence ${f}^{-1}\left(x\right)=x+1$ when $-1⩽x<0$.Also $f\left(x\right)=2-x$ when $0 then setting y=f(x) we get $y=2-x$ when $1 then $x=2-y$ when $1<2-y⩽2$. Hence ${f}^{-1}\left(x\right)=2-x$ when $0⩽x<1$
Therefore, the inverse of function f is given by
$\overline{){f}^{-1}:x↦\left\{\begin{array}{l}x+1,\phantom{\rule{1em}{0ex}}\text{if}\phantom{\rule{1em}{0ex}}-1⩽x<0,\\ 2-x,\phantom{\rule{1em}{0ex}}\text{if}\phantom{\rule{1em}{0ex}}0⩽x<1\end{array}}$
Now check $\left({f}^{-1}\circ f\right)\left(x\right)=x$ for all $x\in \mathrm{D}\mathrm{o}\mathrm{m}\left({f}^{-1}\right)$ and $\left(f\circ {f}^{-1}\right)\left(x\right)=x$ for all $x\in \mathrm{D}\mathrm{o}\mathrm{m}\left(f\right)$

Do you have a similar question?

Recalculate according to your conditions!