I have a question set that is asking me to determine if the following two statements are true and justify my answer.
If $f(x)$ is even then $g(x)=[f(x)] $is even and If$ f(x)$ is odd then$ g(x)=[f(x)]$ is odd.
I am struggling with this question because I am not really sure how to bring all of my knowledge together. I have read some fantastic posts here about the outcome of composing even and odd functions,however I am struggling to understand the effect that the floor function has on these statements. In my course we've been told that if a function is symmetrical around the y-axis it is even and odd if it is symmetrical around the $x$-axis.
We have also been given the definition that if$ f(x) = f(-x) $then the function is even and a function is odd if$ -f(x) = f(-x)$
But the problem I am having is how to apply all of this to my problem and what effect the floor function has on these statements
Any advice or points would be greatly appreciated.
Thank you
If $f(x)$ is even, then, since $f(-x)=f(x)$:
$g(-x)=\lfloor f(-x)\rfloor=\lfloor f(x)\rfloor=g(x)$
so $g(x)$ is even, and this proves Statement 1. In fact, you can see that the proof depends only in the fact the $f(x)$ is even, so that we can prove the more general statement:
If $f(x)$ is even, then the composition of any function $h(x)$ after $f(x)$, $g(x)=h(f(x))$, is even (and it doesn't matter if $h(x)$ is even, odd or neither). Proof: $g(-x)=h(f(-x))=h(f(x))=g(x)$
Statement 2 (If $f(x)$ is odd then $g(x)=\lfloor f(x)\rfloor$ is odd) has been proved false by Jack Lam counterexample, but let's try something similar. If $f(x)$ is odd, then, since $f(-x)=-f(x)$:
$g(-x)=\lfloor f(-x)\rfloor=\lfloor -f(x)\rfloor$
Now, in order to follow, we need to know if the floor function is even, odd or neither. If the floor function was even, then $\lfloor -f(x)\rfloor= \lfloor f(x)\rfloor=g(x)$, so that $g(x)$ would be even. If it was odd, then $\lfloor -f(x)\rfloor= -\lfloor f(x)\rfloor=-g(x)$, so that $g(x)$ would be odd.
But, you can easily check that the floor function is neither odd nor even, because $\lfloor-x\rfloor=-\lfloor x\rfloor$ only if $x\in\mathbb{Z}$, otherwise $\lfloor-x\rfloor=-\lfloor x\rfloor -1$. Then, $g(x)$ is neither even nor odd:
$g(-x)=\lfloor f(-x)\rfloor=\lfloor -f(x)\rfloor=\left\{ \begin{array}{l} -\lfloor f(x)\rfloor =-g(x), f(x)\in\mathbb{Z}\\ -\lfloor f(x)\rfloor-1=-g(x)-1, f(x)\notin\mathbb{Z} \end{array} \right.$
So we have proved Statement 2 false in general; but think about this: it is true if $f$ is a function that only takes values in $\mathbb{Z}$, that is whose codomain is $\mathbb{Z}$.