1
$\begingroup$

Is there a real continuous function that extends the domain of this function?

$$ f(k) \begin{cases} if \:k \equiv 1 \:\mod\:2, \quad f(k) = \frac{k+1}{k}\\ \\if \:k \equiv 0 \:\mod\: 2, \quad f(k) = \frac{k-1}{k} \end{cases} $$ Graph of the function

$\endgroup$
1
  • 1
    $\begingroup$ There are billion continuous functions that interpolate given points, where is the problem ? $\endgroup$
    – user65203
    May 16, 2018 at 13:25

3 Answers 3

2
$\begingroup$

What about

$$f(x)=\frac{x-1}x \cos^2 \left(\frac{\pi}2x\right)+\frac{x+1}x \sin^2 \left(\frac{\pi}2x\right)$$

which can be simplified by trigonometric identities

$$f(x)=1-\frac1x\left[2\cos^2 \left(\frac{\pi}2x\right)-1\right] =1-\frac{\cos \left(\pi x\right)}x$$

$\endgroup$
2
  • $\begingroup$ Yes! Thank you so much! That's perfect! $\endgroup$
    – ray lin
    May 16, 2018 at 13:26
  • $\begingroup$ @HenningMakholm Yes of course it can be simplified, I've let the full expression to see how it works. $\endgroup$
    – user
    May 16, 2018 at 13:29
1
$\begingroup$

example $$ f(x) = 1 - {1 \over x}\left( {\cos \pi x} \right) $$

$\endgroup$
1
  • $\begingroup$ Yo Nice Function! Thank you so much for the answer! $\endgroup$
    – ray lin
    May 16, 2018 at 13:30
0
$\begingroup$

$$ f(x)=\begin{cases} 1 & \text{when }x=0 \\ 1 - \frac1x\bigl(\cos(\pi x) - \sin(\pi x)/\pi x\bigr) & \text{otherwise} \end{cases} $$ is continuous (in fact real analytic) on all of $\mathbb R$ and agrees with your original definition at all points where it is defined.

$\endgroup$

Not the answer you're looking for? Browse other questions tagged or ask your own question.