Is a smooth function with bounded partial derivatives defined on an open set in Euclidean space bounded? This question is a follow up to this one, which was answered essentially in the negative. So I am trying to find another way.
I have a connected bounded open set $X \subset R^n$; then I know it is also path-connected. I also have a smooth (say at least $C^2$) function $u$ on $X$ to the positive reals $P$. I also know that the absolute value of the partials $\partial u/\partial x_i,\; 1 \leq i \leq n$ are uniformly bounded on $X$. Finally, I have a limit point $z$ of $X$ and a sequence $\{z_n\} \subset X$ approaching $z$ . I would like to show that $\{u(z_n)\}$ is bounded (so I can extend it).
I don't know that $X$ is convex, so I can't use that. Instead, my idea is to integrate $u$ along paths $l(z_1,z_k) \subset X, \; k = 2,3,\ldots$, where $l(z_1,z_k)$ is of course the path in $X$ connecting $z_1$ and $z_k$. I would then show that this sequence of integrals is bounded by using the boundedness of the partials of $u$. I could then conclude that $u(z_n)$ itself is bounded. There's only one problem: While I believe, because $u$ is $C^2$, that $l(z_1,z_k)$ has finite length, I don't know that $\lim_{k \rightarrow \infty} l(z_1,z_k)< \infty$ (so I can't use the typical argument that the value of the integral is bounded by the bound on the partials times the length of the domain of integration). Is there any way to show that in this particular situation the limit of the length of the paths is finite? Perhaps by showing there is a neighborhood $U(z)$ of $z$ such that $u$ is bounded on the "last piece" $U(z) \bigcap X$? I am wary of drawing any conclusions in this situation because I know how crazy paths (even in $R^n$) can be.
Any ideas appreciated. Really.
Edit: Thanks to Paul Frost for suggesting edits (above in bold) to make things clearer. The partials being bounded uniformly means that there exist positive constants $K_i,\; 1 \leq i \leq n$ such that $\lvert \partial u(x)/\partial x_i(x) \rvert < K_i,\; \forall x \in X, 1 \leq i \leq n$.
Edit: Martin R seems to have provided a clever counter-example showing the answer to my question is no. I am still hopeful of getting the result I need as $X$ is actually the image, by an open map (a projection), of an $n$-dimensional integral manifold $L$. Given bounds on the partial derivatives of $L$ (and perhaps an additional restriction on the second derivative) I can use estimates on the minimum size of the image, in $X$, of any open "ball" in $L$ to show that, for every $x \in X$, if $U_x$ is a neighborhood of $x$ completely contained in $X$ then it must contain a ball of minimum radius (I have questions about these estimates, I will create another post to pose them). This obviously would get around counter examples such as the one provided by Martin R. My thanks to all who posted and tried to help.
 A: The conjecture is wrong for $n=2$ (and therefore also in all higher dimensions). The idea of the following counterexample is to construct a domain $X$ where some boundary points can be reached only via a path of infinite length.
Let $X \subset \Bbb R^2$ be the open square $(0, 1)^2$, with the line segments
$$
 A_n = \left\{ (x, \frac 1n) \mid 0 \le x \le \frac 45 \right\} \, , n = 2, 4, 6, \ldots 
$$
and
$$
 B_n = \left\{ (x, \frac 1n) \mid \frac 15 \le x \le  1 \right\} \, , n = 3, 5, 7, \ldots 
$$
removed.
For $0 < x < 1/5$, define $f(x, y)$ as $1, 3, 5, \ldots$ in the squares between the line segments $A_n$, starting at the top.
For $4/5 < x < 1$, define $f(x, y)$ as $2, 4, 6, \ldots$ in the squares between the line segments $B_n$, starting at the top.
In each of the the remaining “stripes” let $f$ smoothly increase (or decrease) from $n$ to $n+1$, with bounded derivative in $x$ direction and constant in $y$-direction.
(One can for example set
$$
 f(x, y) = n + \frac{\phi(x-1/5)}{\phi(x-1/5)+\phi(4/5-x)}
$$
in each stripe where $f$ increases from $n$ to $n+1$, where $\phi$ is the well-known smooth function
$$
 \phi(x) = \begin{cases}
 0 & \text{ if } x \le 0 \, ,\\
\exp(-1/x)^2 & \text{ if } x > 0 \, .
\end{cases}
$$
Note that $\frac{\partial f}{\partial x}$ is bounded independently of $n$.)
The resulting function $f$ has the property that $\frac{\partial f}{\partial x}$ is bounded, and $\frac{\partial f}{\partial y} = 0$ everywhere. But for any sequence $(z_n)$ converging to a point $(x, 0)$, $0 \le x \le 1$, the sequence $f(z_n)$ is unbounded.

