A smoother one is the tan
function, which of course goes from negative to positive infinity
in the compass
/2 to pi/2
, so just compose
it with a function that scales the interval (0, 1) up.
Frustratingly, it is obvious that taking the closed interval [0, 1] trivially adds two points to a set of cardinality c, yet extending the bijection to include them is nontrivial.
Thanks to ariels for pointing out it's in fact impossible to have such a continuous bijection, since it would be from a compact set to an open one.