# Example of complete but not closed Riemannian submanifold

I am working on an exercise where I am asked to construct an example of a complete Riemannian metric $$(M,g)$$ and a connected embedded Riemannian submanifold $$P \subseteq M$$ that is complete, but not closed. And I am not certain that such an example exists.

Suppose $$x \in M \setminus P$$ is a limit point of $$P$$. Then there is a sequence $$\left\{x_n\right\}_{n \geq 1} \subset P$$ that converges to $$x$$ in the metric $$d_g$$ induced by the Riemannian metric on $$M$$. In particular, $$\left\{x_n\right\}$$ is a Cauchy sequence in $$M$$. So in order for this to be true, we would need $$\left\{x_n\right\}$$ to fail to be a Cauchy sequence in $$P$$; otherwise by completeness of $$P$$, $$x_n\to x \in P$$ in the induced topology on $$P$$, contradicting our hypothesis.

What I need: I want an example of a complete Riemannian manifold $$(M,g)$$ admitting a connected, complete, embedded submanifold $$P \subset M$$ where Cauchy sequences in $$M$$ are not necessarily Cauchy in $$P$$. But I'm not sure how to construct such a thing. Any tips?

Your goal is to have points which are arbitrarily close in $$M$$ but far apart in $$P$$. In other words, you want to have points that get close together in $$M$$ but such that to get between them in $$P$$, you have to travel a large distance. Intuitively, this is easy: for instance, you can draw a curve that keeps revisiting a location infinitely often (getting closer and closer each time) while moving a fixed distance away each time.
Let $$M=\mathbb{R}^2$$ with its usual metric, and let $$P=\{(x,\sin(1/x)):x>0\}$$. As $$x$$ approaches $$0$$, $$\sin(1/x)$$ oscillates between $$-1$$ and $$1$$ infinitely often, so the curve accumulates at $$(0,y)$$ for all $$y\in[-1,1]$$ and $$P$$ is not closed. But $$P$$ is complete in its induced metric, since the arc length required to approach $$x=0$$ is infinite.