Help me understand $y=f(x)$ vs. $y=f(|x|)$ intuitively

1.1k Views Asked by At

I am writing this because I want to fill the hole in my understanding of elementary functions in Euclidean plane. In class, we discussed parallel examples, such as $y = f(x)$ vs. $y = |f(x)|$. Plotting $f(x) = x^2 - 2$ and $f(x) = |x^2 - 2|$ gives:

enter image description here

I can intuitively understand the graph of $f(x) = |x^2 - 2|$; it is derived from the definition of absolute value:

$$|a| = \begin{cases} \hfill a & \text{if $x\geq 0$}\\ -a & \text{if $x<0$} \end{cases}.$$

Therefore all values produced by $y = |x^2 - 2|$ are positive. If $x^2 - 2$ is negative, then by definition we take its negative — therefore, all points that originally had negative values for $y$ coordinate are reflected over $x$ axis. I believe I understand these examples properly.

Now to the example I don't understand. In class we also discussed $y = f(x)$ vs. $y = f(|x|)$. I do not understand the logic behind such graphs! For example, let's plot $f(x) = -x^3 + 2$ and $f(x) = -|x^3| + 2$:

enter image description here

In class we observed that to get a graph of $f(|x|)$ one has to reflect the points of I. and IV. quadrants of the normal $f(x)$ over $y$ axis. My professor said this is apparent from the definition of the absolute value, but I still can't grasp how.

Please help me understand this observation we made (and if the observation is by any chance false, please help me understand why the graph is as it is altogether). Thank you in advance.

5

There are 5 best solutions below

0
On BEST ANSWER

That's because$$f\bigl(|x|\bigr)=\begin{cases}f(x)&\text{ if }x\geqslant 0\\f(-x)&\text{ otherwise.}\end{cases}$$But this means that, in order to draw the graph of $f\bigl(|x|\bigr)$, with draw the graph of $f(x)$ for $x\geqslant0$ and then, to get the rest, you reflect this on th $y$-axis.

0
On

The function $f(|x|)$ take all non negative values for x thus the function is reflected with respect to the y axis.

Indeed

  • for $x\ge 0 \implies f(|x|)=f(x)$
  • for $x< 0 \implies f(|x|)=f(-x)$ and note that $-x$ is positive

Note also that

$$f(|x|)=f(|-x|)$$

and thus $f(|x|)$ is always an even function and thus it is symmetric with respect to the y axis.

Moreover note that if $f(x)$ is even we have $$f(x)=f(|x|)$$ since |x| has no effect on the value of f(x).

EG $$f(x)=x^2\implies x^2=|x|^2$$

0
On

The absolute value will take any negative input $x$ and return the positive input $|x|$. So any behavior you see for positive values of $x$ in your graph will be repeated for the negative values of $x$ since they will be replaced by positive values $|x|$. This is exactly why you have a reflection.

Some more concrete examples: if you look at your function at $x=-1$ then, because absolute value will change $-1\rightarrow 1$, you can expect that you will get whatever you function outputs when $x=1$. More generally, any negative number you put into your function will get "flipped" to a positive number by the absolute value. So whatever output your function has for positive numbers will be the same for the negative of those numbers, because of the "flipping" caused by absolute value.

0
On

For simplification, find the relationship between $x^3$ and $|x^3|$. What do you see?

Continue doing this for more graphs, like $y=-\left|x^3\right|+2\left|x^2\right|-2\left|x\right|$ and $y=-x^3+2x^2-2x$.

There should be something obvious pointing out.

0
On

The graph of $f(|x|)$ is the same as the graph of $f(x)$ for $x\geq0$ (i.e. graph is the same on the "right half" of the plane). But on the left half, it may be different. For the function $f(|x|)$, the vertical axis is like a mirror, and the left half will look like a reflection of the right, like the blue function in your picture.