Proving a function $f(x + T)=k\;f(x)$ satisfies $f(x)=a^x g(x)$ for periodical $g$ I need to prove the following:

If a function $\,f$ satisfies
$$f(x+T)=k\;f(x), \forall x \in \mathbb R$$
for some $k \in \mathbb N$ and $T > 0$, prove that $\,f$ can be written as $f(x)=a^xg(x)$ where $g$ is a periodical function with period $T$. Prove reverse statement/reversal.

I would need some tips/hints how to begin, since I have no idea how to start.
 A: Clearly, some function $g$ does exist such that
$f(x)=a^x g(x)$ for some $a$. If we, in particular, choose $a$ such that $a^T=k$, then we can determine $g$ as
$$\frac{f(x)}{a^x}=g(x)$$
but note that if we substitute $x+T$ into this equation for $x$ we get
$$\frac{f(x+T)}{a^{x+T}}=g(x+T)$$
$$\frac{f(x+T)}{a^Ta^x}=g(x+T)$$
then from definition of $a^T$ and $f(x+T)$ we get
$$\frac{kf(x)}{ka^x}=g(x+T)$$
$$\frac{f(x)}{a^x}=g(x+T)$$
$$g(x)=g(x+T)$$
so $g$ is periodic in $T$.
A: If you do the reverse statement, then it is suggestive that $a=k^{1/T}$.
So let us set $a=k^{1/T}$ and consider $g(x)\equiv f(x)/a^x$. To check the periodicity of $g$:
$$
g(x+T)=\frac{f(x+T)}{a^{x+T}}=\frac{kf(x)}{a^{x+T}}=\frac{a^Tf(x)}{a^{x+T}}=\frac{f(x)}{a^x}=g(x).
$$
A: Log f( x + T ) = log k + log f( x ).
Thus log f( x + T ) - (log k )/ T * ( x + T )= log f( x ) - ( log k )/ T * x, and the right side is a periodic function.
A: Note that value of $f$ on entire $\mathbb{R}$ determined if only you know 
its value on interval $[x_0,x_0+T)$ for some $x_0$. define $g$ to be a peridic 
function with same values in that interval. Rest may be straight forward. 
A: \begin{align}
& f(0+3T) = f((0+2T)+ T) = f((\text{something})+T) = k f(\text{something}) \\[8pt]
= {} & kf(0+2T) = kf((0+T)+T)=kf((\text{something})+T) = k\Big(kf(\text{something})\Big) \\[8pt]
= {} & k^2 f(0+T) = k^2 \Big( kf(0)\Big) = k^3 f(0).
\end{align}
Generally, $f(0+nT) = k^n f(0)$, for reason that the above should make clear.   If $x=nT$ then
$$
f(x) = f(nT) = k^n f(0) = k^{x/T} f(0) = \left( k^{1/T} \right)^x f(0) = a^x f(0).
$$
But this works only if $n$ is an integer.  So say we had started with $0.2$ instead of $0$.  We'd have $x^2 f(0.2)$.  So that's what the function $f$ gives you.
