# If Y is a metric subspace of X. A subset E of Y is open relative to Y if and only if E=Y ∩ G for some open subset G of X.

If we take X=R and Y=Z and E=N i.e. {1,2,3,4,5.........} then since for this case E is open in Y (as Y is itself an entire metric space) however there does not exist any open set G in X for this particular set. then how E is open in Y.

Pl clarify

-
Why do you insist on extra notation? Just use $\mathbb{R,Z,N}$ instead of $X,Y,E$. Also what is "Pl clarify"? –  Asaf Karagila Aug 25 '12 at 16:29
Also, why does $Y$ being an "entire metric space" imply that it is open in $E$? Any subset of a metric space is a metric space. $Y$ is open in $E$ in this case, but still... –  ronno Aug 25 '12 at 19:52

Take $G = (0,\infty)$. 
If you want to be fancy, let $$U=\bigcup_{n\in\Bbb Z^+}\left(n-\frac12,n+\frac12\right)\;;$$ then $U$ is an open subset of $\Bbb R$, and $U\cap\Bbb Z=\Bbb Z^+$. But there’s no need to go to so much trouble, as Sean’s answer shows. For that matter, you could observe that $\Bbb Z_{\le0}=\Bbb Z\setminus\Bbb Z^+$ is a closed set in $\Bbb R$, so $\Bbb R\setminus\Bbb Z_{\le0}$ is an open set in $\Bbb R$ whose intersection with $\Bbb Z$ is clearly $\Bbb Z^+$.