Let $g:\mathbb{R^d}\to[0,+\infty)$ be a measurable nonnegative function, and let $p, q \in (1, +\infty)$ with $p>q$. Consider the operator $$f\mapsto Tf(x)=g(x)f(x).$$ Find a condition on $g$ such that the above operator $T$ is a linear and bounded operator from $L^P(\mathbb{R^d})$ to $L^q(\mathbb{R^d})$.
If I am not wrong, according to the definition of linear operator, we need to find conditions on $g$ such that the following holds: $$\|Tf(x)\|_{L^{q}}\leq M \|f(x)\|_{L^{p}}$$ for some constant $M \geq 0$.
More precisely, $$\|g(x)f(x)\|_{L^{q}}\leq M \|f(x)\|_{L^{p}}$$
$$\implies \left(\int_{\mathbb{R^d}}|g(x)f(x)|^qdx\right)^{1/q} \leq M \left(\int_{\mathbb{R^d}}|f(x)|^pdx\right)^{1/p}.$$
The only idea I have is to define $g$ in some way in order to be able to use Hölder's inequality to get an expression in the form $\int_{\mathbb{R^d}}|g(x)f(x)|dx \leq \left(\int_{\mathbb{R^d}}|g(x)|{^q}dx\right)^{1/q} \left(\int_{\mathbb{R^d}}|f(x)|^pdx\right)^{1/p}$, and then saying also that $g$ is a function such that $\|g\|_{L^q} < +\infty$; but I do not know how to proceed.
Do you have any additional ideas?
HINT From Hölder's inequality, we have $$ \int_{\mathbb{R}^d}|g(x)f(x)|^q\ dx\leq \left(\int_{\mathbb{R}^d}|g(x)|^{p'q}\ dx \right)^{1/p'} \left(\int_{\mathbb{R}^d}|f(x)|^{p}\ dx \right)^{q/p}, $$ where $p'$ satisfies $1/p'+q/p=1.$