1
$\begingroup$

Let A and B be two disjoint closed sets of any Metric space X.I have to construct a continuous function such that
$f(x):= 0$ if x belongs to $A$
$f(x) = 1$ if x belongs to $B$

My idea is to use the concept of distance between a point and a set.So I tried like this..
$f(x):= 0$ if $d(x,A) = 0$ and
$f(x) = 1$ if $d(x,A) \neq 0$

I am able to prove $f$ is continuous if both $x$ and $y$ belongs to $A$ or Both belongs to $B$.. But how to prove if $d(x,y)$ less than $\delta$ ($x$ belongs to $A$ and $y$ belongs to $B$) $\Rightarrow d(f(x),f(y))$ less than $\epsilon$.

$\endgroup$
3
  • 4
    $\begingroup$ Something like $d(x,A)/(d(x,A)+d(x,B))$ should work, no? $\endgroup$ Jun 22, 2014 at 8:28
  • $\begingroup$ how.. if u consider that then f(x)= 0 if x belongs to A and if x belongs to B WHAT HAPPENED..can u explain me that.. because since A is closed, d(x,A)=0 if x belongs to A. $\endgroup$
    – user157562
    Jun 22, 2014 at 8:33
  • $\begingroup$ See also: math.stackexchange.com/questions/47360/… (Not sure whether this should be considered duplicate.) $\endgroup$ Jun 22, 2014 at 9:07

1 Answer 1

0
$\begingroup$

The problem with your approach is that your function may have a jump discontinuity at the boundary of $A$. Consider for instance what would happen at $x=1/3$ if $X=\mathbb [0,1]$, $A=[0,1/3]$, and $B=[2/3,1]$.

For $K\subseteq X$ define $d(x,K)=$inf{$d(x,y):x\in K$}. Show that this function is continuous.Then define $f:X\to\mathbb R$ by $f(x)=d(x,A)/(d(x,A)+d(x,B))$. Using the fact that $A$ and $B$ are closed, you should be able to show $f(x)=0$ iff $x\in A$ and $f(x)=1$ iff $x\in B$. Now you can also show $f$ is defined on all of $X$. It will be continuous as sums and quotients of continuous real-valued functions are continuous everywhere they're defined.

$\endgroup$
2
  • $\begingroup$ thank you..i can understand now. $\endgroup$
    – user157562
    Jun 22, 2014 at 9:11
  • $\begingroup$ no problem, glad I could help $\endgroup$ Jun 22, 2014 at 9:16

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .