# How to show a function is even/odd

1. ### mcfc

17
1. The problem statement, all variables and given/known data
Hi,
I'm new to this site, I've had a look around and there are alot of useful sections, particularly the section with math and science learning materials.
Anyway, I need to show that the following function is odd
$$f(x)=\left\{\begin{array}{ccc} -\sin x&\mbox{ for }-\pi \leq x< \frac{-\pi}{ 2}\\ \sin x &\mbox{ for } \frac{-\pi}{2} \leq x \leq \frac{\pi}{2}\\ -\sin x &\mbox{ for } \frac{\pi}{2}<x<\frac{\pi}{2} \end{array}\right.$$

$$\mbox{ and }f(x + 2 \pi) = f(x) \mbox{ for all other values of x, is an odd function.}$$

2. Relevant equations

I know an odd function is definded as $$f(-x) = -f(x)$$

3. The attempt at a solution
In the interval
$$-\pi\leq x < {-\pi \over 2} \mbox{ if I substiture } -\pi \mbox{ it becomes }-\sin(-x) = -\sin[-(-{\pi \over 2})] = -\sin({\pi \over 2})$$

Is that the correct way to solve it?
But I'm not sure how to show it's odd in the other intervals!

Last edited: Aug 22, 2009
2. ### zcd

200
If f(-x)=f(x), then the function is even. If f(-x)=-f(x), then the function is odd.

3. ### robphy

4,463
This might be a useful variation of the definitions:

If the function f(x) is even, then f(x)-f(-x)=0 for all x.
If the function f(x) is odd, then f(x)+f(-x)=0 for all x.

4. ### mcfc

17
To show it's odd:
look at values in the intervals?
$$-\sin(-\pi) - \sin({\pi }) = 0$$

$$\sin({-\pi \over 2}) + \sin({\pi \over 2}) = 0$$

$$-\sin({3 \pi \over 4}) - \sin({-3 \pi \over 4}) = 0$$

do I need to show anything else?

5. ### mathie.girl

32
You would have to show that it's true for every value in the interval, not just at a few random points. So you'd have to let $$a$$ be a random value in each interval, and then look at $$f(a)$$ and $$f(-a)$$. Since the intervals are symmetric, once you've assigned an interval for $$a$$, it will be obvious what interval $$-a$$ is in and therefore which definition of the function you need to use.