Suppose f:<b>R</b>&rarr;<b>R</b> is a function. Let S={x&isin;<b>R</b>|f is continuous at x}. Does S have any nice properties?

Here are some observations about what S could be:

- S can be any closed set. For a closed set S, let g be a continuous function whose vanishing locus is S (for example, you could take g(x) to be the distance of x from S if S is non-empty). Then define f(x)=g(x) if x&isin;<b>Q</b> and f(x)=0 otherwise. Then the continuous locus of f is exactly S.
- S can be an open interval. For an open interval S, define f(x)=0 if x&isin;S or x&isin;<b>Q</b> and f(x)=1 otherwise. Then the continuous locus of f is exactly S.
- S can be the complement of any countable set. Let T={t<sub>1</sub>,t<sub>2</sub>,t<sub>3</sub>,...} be a countable set, and let &sum;a<sub>i</sub> be some absolutely convergent series all of whose terms is non-zero (like a<sub>i</sub>=1/2<sup>i</sup>). Define<br>
f(x) = &sum;<sub>i such that t<sub>i</sub> &lt; x</sub> a_i.<br>
Then the continuous locus of f is exactly the complement of T.

Here are some questions I'd like to know the answers to:

- Can S be any open set?
- Can S be non-measurable? (if f(x)=0 if x&isin;S and f(x)=1 otherwise, what will the continuous locus be?)