# Question of pointwise convergence of a sequence of functions

Define $$f_n:[-1,1]\to \Bbb R$$ by $$f_n(x)=\begin{cases}1 , \text{ for -1 \leq x \leq -1/n} \\ -\sin(n\pi x/2) , \text{ for -1/n \leq x \leq 1/n}\\-1 , \text{ for 1/n\leq x\leq 1} \end{cases}$$

So I need to sketch find the pointwise limit of $$(f_n)$$. And need to deduce if the convergence is uniform. Then, I need to calculate $$f'_n$$ and find the limit of $$f'_n$$.

So here's how I go with it:

I sketch the first 3 $$f_n$$'s, and he's what I see,

That for every consecutive $$n$$, $$f_n$$ converges pointwise to the function $$f(x)$$ which is the line that lies on the y axis from $$[-1,1]$$.

So, to determine whether the function converges uniformly, I check whether $$||f_n-f||_{\infty}=||0-1||_{\infty}=1$$

Since the supremum of $$|f_n|$$ on $$0$$ is $$0$$ and Supremum of my upper defined function is $$1$$ on $$0$$. Is this correct? (So no uniform convergence)

Now to $$f'_n$$ is:

$$f'_n=\begin{cases}0,\text{ for -1\leq x \leq -1/n}\\ n\pi/2\cos(\frac{n\pi x}{2}), \text{ for -1/n \leq x \leq 1/n}\\0 ,\text{for 1/n \leq x \leq 1}\end{cases}$$

So, $$f'_n \rightarrow f''(x)$$ where $$f''(x) : 0\to 0$$ as $$n\to \infty$$?

Please, if possible, tell me whether I have mistakes in my thinking, and correct it. Any help is appreciated!

I believe that there are some weak spots in your reasoning. Recall that pointwise convergence means fixing $$x\in[-1,1]$$ and figuring out what happens to the sequence $$\{f_n(x)\}_n$$ as $$n\rightarrow\infty$$.
If $$x\in[-1,1]$$ and $$x\neq0$$ then, for $$n$$ large enough $$f_n(x)$$ will be identically $$1$$ or $$-1$$ depending on the sign of $$x$$ (check this!). I'll leave it to you to check what happens if $$x=0$$ and to get the pointwise convergence from there (in particular you need to find the pointwise limiting function $$f$$).
Further, let me give you a hint on the uniform convergence: $$f_n$$ is continuous in $$[-1,1]$$ (check this!) and by now you have the explicit form of the pointwise limit $$f$$. Now, what do we know about uniform convergence of continuous functions? Can this happen in our example?