Define the closure of a set $A\subset \Bbb R$ as $clA.$ Show that $x\in clA,$ iff $d(x,A)=0$ where $d(x,A)=\text{inf}\{|x-a|:a\in A\}.$
I tried solving the probllrm like this:
We know that $clA=A\cup L,$ where $L$ is the set of limit points (or derived set) of $A.$
Let $x\in clA.$ This implies $x\in A$ or $x\in L.$ If $x\in A,$ then $d(x,A)=\text{inf}\{|x-a|:a\in A\}=0,$ trivially and we are done. If $x\in L,$ then it means that $x$ is a limit point of the set $A,$ and which implies that $\exists (a_n)\in A$ such that $\lim a_n=x.$ So, for all $\epsilon \gt 0$ there exists a $K\in \Bbb N$ such that if $n\geq K,$ $|a_n-x|\lt\epsilon.$ If we place $|a_n-x|=p$ in a set $d(x,A),$ then it follows, that $inf(d(x,A))=0,$ which proves the fact that:" $x\in clA,$ if $d(x,A)=0$ where $d(x,A)=\text{inf}\{|x-a|:a\in A\}.$"
Now, we wish to prove the converse part i.e " If $d(x,A)=0$ where $d(x,A)=\text{inf}\{|x-a|:a\in A\},$ then, $x\in clA.$"
So, let $x\in \Bbb R$ such that $d(x,A)=0.$ Let $S=\{|x-a|:a\in A\}.$ If, $0\in S,$ then it simply implies that $\exists a\in A,$ such that $|x-a|=0\implies x=a\in A.$ Thus, $x\in A\cup L=clA,$ and we are done.
Now if, $0\notin S,$ then we claim $x\in clA.$ We try to show that this claim is true.
If, $d(x,A)=0$ and $0\notin S$ then, for a particular $\epsilon \gt 0$ there must exist an $a\in A$ such that $|x-a|\lt \epsilon.$ For if, such an $a\in A$ does not exist, then it means $\forall a\in A,$ $|x-a|\geq \epsilon,$ implies that $\text{inf}(S)=\epsilon,$ as opposed to $0$ as, $\epsilon\gt 0,$ a contradiction. So, this is never the case. Hence, if in particular, we choose, $\epsilon =\frac 1n,n\in \Bbb N$ then it means $\exists a_n\in A$ such that $|a_n-x|\lt \frac 1n.$ We thus, get a convergent sequence $(a_n)\in A$ such that $\lim a_n=x.$ This implies, that $x$ is a limit point of $A$ i.e $x\in L\implies x\in clA.$ This completes the proof.
I hope my solution is correct. However, I want to know if I can improve the proof to make it more understandable or is it good to go, as this. Any suggestions to improve the proof or to make it simpler will be highly appreciated. Lastly, if something looks/is wrong with my proof, then please do let me know.
It is correct but there are better ways to put it, yes, especially this part here.
The idea is correct, but the above could have been written better. Also on a technical note, $d(x,A)$ is the infimum so you should have just written $d(x,A)$ instead of $\inf(d(x,A))$, and the set as $\{|x-a|:a\in A\}$. Regardless, here is a better way to put it.
Everything else is fine. Hope it helps. :)