finding weird examples of continuous functions (or, maybe, they're tricks?) I need to find examples of the following, but I feel like they're trick questions.


*

*A unbounded function on a bounded closed interval (the function must be defined at every point in the interval)


I was thinking something like 1/x, but it's not defined at 0 (it'd need to be (0,1] ), so I don't see how I can provide something that is defined at the boundary points and unbounded on the interval. I would think I'd need something that blows up, but then it won't be defined at every point in the interval 


*f : [0, 1] → [0, 1], having the intermediate-value property but continuous at only one point


For a function to experience the intermediate-value property, doesn't it need to be continuous on its domain (the whole closed interval)? How can I provide an example when it's only continuous at one point? 
 A: f(x) = 0 if x = 0.  f(x) = 1/x if x $ne$ 1.
Unbounded, defined everywhere, but not continuous.
A: The second example:


*

*Take the Conway base 13 function $F(x)$, which is known to take on every real value on each interval (and is, therefore, nowhere continuous), and the interval $(0,1)$.

*Consider $g(t)=\frac12+\frac{1}{\pi}\arctan t$. The function $g\circ F$ takes on every value in $(0,1)$ on each real interval in $(0,1)$.

*Define
$$
f(x)=\left\{
\begin{array}{ll}
0, &\text{ if } x=0,\\
1, &\text{ if } x=1,\\
x\cdot (g\circ F)(x)&\text{ if } x\in(0,1).
\end{array}
\right.
$$
The function $f\colon[0,1]\to[0,1]$ takes on every real value in $(0,b)$ on each interval $(a,b)\subset[0,1]$ and, thus, satisfies IVP on $[0,1]$ and continuous only at $x=0$.

A: I will attempt the second part. To do this I will assume the result that the Cantor set can be mapped surjectively onto $[0,1]$ (which can be done, for example, by sending ternary expansions with 0's and 2's into binary expansions with the corresponding 0's and 1's). 
We will construct a set $S \subset [0,1]$ which can be written as the union of countably many disjoint Cantor sets $C_{n,k}$, where each $C_{n,k}$ is contained in the dyadic interval $[k2^{-n}, (k+1)2^{-n}]$. The term "Cantor set" refers to a translate and dilate of the usual $1/3$-Cantor set in $[0,1]$.
If we can construct this set $S$ then we would be done. Indeed, for each $n,k$ there exists a surjection $\phi_{n,k}:C_{n,k} \to [0,1]$. Then we can define a map $\phi: [0,1] \to [0,1]$ as $$\phi(x)=\begin{cases} 0, \;\;\;\;\;\;\;\;\text{ if } x \notin S \\ \phi_{n,k}(x), \;\text{ if } x \in C_{n,k} \text{ for some } n,k \end{cases}$$
This function is discontinuous at every point and has IVT, since any subinterval of $[0,1]$ must contain one of the $C_{n,k}$, which is mapped onto $[0,1]$ by $\phi$. If you want continuity at exactly $1$ point, then just consider $x\phi(x)$.
To finish, we will now construct the sets $C_{n,k}$, for $n \geq 0$ and $k\in \{0,...,2^n-1\}$. We apply induction on $n$ for this construction. First, let $C_{0,0}$ be the usual Cantor set in $[0,1]$. For the inductive step of the construction, suppose that $N \geq 1$ and that we have constructed disjoint Cantor sets $C_{n,k} \subset [k2^{-n},(k+1)2^{-n}]$ for all $k \in \{0,...,2^n-1\}$ with $n<N$. Since each of the sets $C_{n,k}$ is closed and nowhere dense, it follows that the union of these $C_{n,k}$ (for $n<N$ and $0\leq k \leq 2^n-1$) is also closed and nowhere dense. Hence each dyadic interval $[k2^{-N},(k+1)2^{-N}]$ contains an open interval $J_{N,k}$ not intersecting any of these $C_{n,k}$. Now for each $0 \leq k \leq 2^N-1$, just define $C_{N,k}$ to be any Cantor set contained in $J_{N,k}$. Clearly these $C_{N,k}$ are disjoint from the previously constructed $C_{n,k}$. Thus we have defined disjoint Cantor sets $C_{n,k}\subset [k2^{-n},(k+1)2^{-n}]$ for all $0 \leq k \leq 2^n-1$ with $n< N+1$. So continue inductively...
