# Is $\sqrt{x^2}$ even or odd?

Is the function $$x\mapsto \sqrt{x^2}$$ even or odd? Mentioning the square root does not have negative sign,

$$\sqrt{x^2} = \pm x$$

As it is clear LHS is even and RHS is odd for both sign, which one is true?

• $\sqrt{x^2} = |x|$ which is even Oct 18, 2019 at 7:32
• $\sqrt{x^2} = x,$ for $x> 0$, but $\sqrt{x^2} = -x$ for $x< 0$. In particular $\sqrt{x^2}$ is always positive. The function $\sqrt{x^2}$ is even. Oct 18, 2019 at 7:33
• Obviously even, since $\sqrt{x}$ implies the positive square root. Oct 18, 2019 at 7:33
• Why do you state "$\sqrt{x^2} = \pm x$" right after "the square root does not have negative sign"? Oct 18, 2019 at 7:45
• Any function of an even function is even if well-defined, since $f(-x)=f(x)\implies g(f(-x))=g(f(x))$.
– J.G.
Oct 18, 2019 at 7:48

Since $$\sqrt{x^2}=|x|$$ we have $$\sqrt{(-x)^2}=\sqrt{x^2}=|x|$$ so our function is even.

The symbol $$\sqrt y$$, when $$y>0$$, means explicitly the positive square root. If you want to express "either square root" you would need to write $$\pm\sqrt y$$. This is why the quadratic formula is written as $$\frac{-b\pm\sqrt{b^2-4ac}}{2a}:$$ you need the $$\pm$$ in order for it to cover both roots.

Therefore $$f(x)=\sqrt{x^2}$$ is a well-defined function (it has only one value for any given $$x$$), and that value is always non-negative. In particular it is even.

0) $$\sqrt {x^2} \ge 0$$, for $$x \in \mathbb{R}$$;

1) A function is even if $$f(x)=f(-x)$$ , $$x \in$$ domain ;

2) $$f(x):=\sqrt{x^2};$$

3) $$f(-x)=\sqrt{(-x)^2}=\sqrt{x^2}=f(x)$$, even.

To see why the right side of your equation is not really odd, you have to analyze it more thoroughly. When we say $$\:\sqrt{x^2} = \pm x\:$$, what we really mean is

$$\sqrt{x^2} = f(x)= \begin{cases} +x, & \text{if x \ge 0} \\[2ex] -x, & \text{if x \lt 0} \end{cases}$$

So is $$f$$ even or odd? If you graph it, it'll be immediately obvious that it's even; after all it's just $$\lvert x\rvert$$. But what about algebraically? The key is to realize that whichever case is used to evaluate $$\:f(x),\:$$ you have to use the opposite case when evaluating $$f(-x)$$. Specifically,

• if $$x \gt 0$$, then $$f(x) = +x\,;\;$$ but then $$-x \lt 0$$, so $$f(-x) = -(-x) = x = f(x)\,;\quad$$and
• if $$x \lt 0$$, then $$f(x) = -x\,;\;$$ but then $$-x \gt 0$$, so $$f(-x) = +(-x) = -x = f(x)\,.$$

So either way $$f(-x)=f(x)$$ and the function is even.

It’s the same thing as the absolute value of X, which is even. Why? Because squaring and then square rooting any real quantity keeps it the same but makes positive (from when we squared it).