I have a function $u(x) \in L^2(\mathbb{R}^n)$ ($n \geq 2$). Suppose we define another function $v$ as $$v:[0,1] \to \mathbb{R} $$ $$\quad \quad \quad \quad \quad \quad \ t \to u(x+th)$$ where $h \in \mathbb{R}^n$ is fixed.
Does $v $ belong to $L^2((0,1))$?
I think the answer should be yes considering the fact that (Let's say $n=2$) $\int_{\mathbb{R}^2} u \ dx= \int_{\mathbb{R}} \int_{\mathbb{R}}u \ dx_1 dx_2$, so both integrals over $\mathbb{R}$ are finite and: $$\int_{(0,1)}u\leq \int_{\mathbb{R}}u$$
But the "direction" of $h$ bothers me.
Consider this counterexample. Let $u:\mathbb{R}^2\to\mathbb{R}$ s.t. $$ u(x,y)=\begin{cases} \frac{1}{\sqrt{x^2+y}} & (x,y)\in [0,1]\times[0,1]\\ 0 & \text{otherwise} \end{cases} $$
We can show this function is in $L^2(\mathbb{R}^2)$ (according to wolfram alpha, $$ \int \vert u(x,y)\vert^2 dxdy=\int_0^1 \int_0^1 \frac{1}{x^2+y}dxdy \approx 2.26394 $$ ). However, $v(t)=u(t,0)\notin L^2([0,1])$, since $\int_0^1 v(t)^2dt=\int_0^1\frac{1}{t}dt$ is not convergent.