14

I am trying to show the followng:

Show that $\sum_{n=1}^{\infty} \frac{(-1)^{n}}{\sqrt{n}}\sin(1 + \frac{x}{n})$ converges uniformly on $\mathbb{R}$.

I have shown it for a compact subset of $\mathbb{R}$ however, do not know how to extend it to the reals. Below is my proof for convergence on a compact subset.

I break up the sum into two parts and attack each individually

$\sum_{n=1}^{\infty} \frac{(-1)^{n}}{\sqrt{n}}\sin(1 + \frac{x}{n})$ = $\underbrace{\sum_{n=1}^{\infty} \frac{(-1)^{n}}{\sqrt{n}}\sin(1)}_{(1)}$ + $\underbrace{\sum_{n=1}^{\infty} \frac{(-1)^{n}}{\sqrt{n}}[\sin(1 + \frac{x}{n})-\sin(1)]}_{(2)}$.

$\textbf{Equation (1)}$

$\sum_{n=1}^{\infty} \frac{(-1)^{n}}{\sqrt{n}}\sin(1)$ converges because $\sum_{n=1}^{\infty} \frac{(-1)^{n}}{\sqrt{n}}$ converges by the alternating series test.

$\textbf{Equation (2)}$

we will first bound $\sin(1 + \frac{x}{n})-\sin(1)$ as follows:

\begin{align*} |\sin(1 + \frac{x}{n})-\sin(1)| &= \Big|\int_{1}^{1+\frac{x}{n}} \cos(t)dt\Big| \\ &\leq \Big|\int_{1}^{1+\frac{x}{n}} |\cos(t)| dt\Big| \\ &\leq \Big|\int_{1}^{1+\frac{x}{n}} dt\Big| \\ &\leq \Big|1+\frac{x}{n} - 1 \Big| \\ &= \frac{|x|}{n} \\ \end{align*} Therefore, on any compact interval $ x \in [-M, M]$ \begin{align*} |\sin(1 + \frac{x}{n})-\sin(1)| \leq \frac{M}{n} \end{align*}

It follows that

\begin{align*} \Big|\frac{(-1)^{n}}{\sqrt{n}} \Big( \sin(1 + \frac{x}{n})-\sin(1)\Big)\Big| &= \Big|\frac{(-1)^{n}}{\sqrt{n}}\Big|\Big|\sin(1 + \frac{x}{n})-\sin(1)\Big| \\ &= \frac{1}{\sqrt{n}}\Big|\sin(1 + \frac{x}{n})-\sin(1)\Big| \\ &\leq \frac{1}{\sqrt{n}}\frac{M}{n} \\ &= \frac{M}{n^{\frac{3}{2}}} \end{align*}

Hence,

\begin{align*} \sum_{n}^{\infty}\frac{1}{n^{\frac{3}{2}}} < \infty &\implies \sum_{n}^{\infty}\frac{M}{n^{\frac{3}{2}}} < \infty \\ &\implies \sum_{n=1}^{\infty}\Big|\frac{(-1)^{n}}{\sqrt{n}} \Big[ \sin(1 + \frac{x}{n})-\sin(1)\Big]\Big| < \infty \\ &\implies \sum_{n=1}^{\infty}\frac{(-1)^{n}}{\sqrt{n}} \Big[ \sin(1 + \frac{x}{n})-\sin(1)\Big] < \infty \end{align*}

Hence, we have that both $(1)$ and $(2)$ converge on a compact interval $[-M,M]$ which implies our original equation of interest does also.

I want to extend this proof to all $\mathbb{R}$ but I do not know how to. Could someone please help me with this. Anything is appreciated.

Tomislav
  • 519
  • 2
  • 12
  • As soon as you have to reach out to a specific interval it's game over for uniform convergence. It may just be best to use the alternating series test on the original series since $\sin$ is bounded. – Ninad Munshi Dec 20 '19 at 03:15
  • So you are thinking that it is not uniformly convergent on $\mathbb{R}$? I think it is. Maybe we can use a diagonalization technique? Taking elements that are convergence on each compact interval? – Tomislav Dec 20 '19 at 03:17
  • My apologies for misunderstanding. – Tomislav Dec 20 '19 at 03:19
  • Could you please elaborate on your technique? – Tomislav Dec 20 '19 at 03:21
  • That being said, if alternating series test makes you feel uneasy because of the conditional convergence (it certainly would trouble me if I were faced with that problem), one can use the angle addition formula to get $\sin(1)\cos(x/n) + \cos(1)\sin(x/n)$. Bound the summation on the left by the alternating series (since $\cos(x) \leq 1$ for small $x$), then the summation on the right becomes $|x|/n^{3/2}$ (since $|\sin(x)| \leq |x|$) which is absolutely convergent for all $x$. – Ninad Munshi Dec 20 '19 at 03:22
  • My apologies I am quite lost here. – Tomislav Dec 20 '19 at 03:24
  • I've written an answer. – Ninad Munshi Dec 20 '19 at 03:31
  • 1
    Since the series does not converges absolutely, I don’t see why we can break up the sum into two parts and attack each individually. – Alex Ravsky May 04 '20 at 16:59
  • I have revised my proof. I think this is the right answer. – Nikos Bagis Dec 24 '20 at 15:35

3 Answers3

7

EDIT: Since this is now a bountied question, I will explain the major sticking point in my proof where I began to hand-wave. For a fixed $N$, I have to show that

$$\inf_{x\in\mathbb{R}} \left \{\sum_{n=N+1}^{2N}\left(\sin\left(1+\frac{x}{n}\right)+(-1)^n\right)^2\right\}=0$$

I proved this fact by showing that a subsequence was equidistributed over $[0,1]$. Unfortunately, this portion of the proof is hand-wavy at best. However, the rest of the proof is solid.


We will attempt to prove that

$$\sum_{n=1}^\infty\frac{(-1)^n}{\sqrt{n}}\sin\left(1+\frac{x}{n}\right)$$

does not converge uniformly on the reals. Unfortunately, some details of the proof require more careful attention to the analysis of special functions in the complex plain. While these details might be lacking in a formal proof, I feel that enough progress has been made here to write everything down.

Suppose that it converges uniformly. Let $N_0\in\mathbb{N}$ such that for all $M\geq N\geq N_0$

$$\left|\sum_{n=1}^{M}\frac{(-1)^n}{\sqrt{n}}\sin\left(1+\frac{x}{n}\right)-\sum_{n=1}^{N}\frac{(-1)^n}{\sqrt{n}}\sin\left(1+\frac{x}{n}\right) \right|=\left|\sum_{n=N+1}^{M}\frac{(-1)^n}{\sqrt{n}}\sin\left(1+\frac{x}{n}\right)\right|<1$$

(this is the Cauchy criteria for uniform convergence with $\epsilon=1$). In fact, as long as $M\geq N\geq N_0$, we are free to choose any natural numbers. As such, choose $N= \text{max}(2,N_0)$ and $M=2N$ to get

$$\left|\sum_{n=N+1}^{2N}\frac{(-1)^n}{\sqrt{n}}\sin\left(1+\frac{x}{n}\right)\right|<1$$

Now, consider the function

$$f(x)=\sum_{n=N+1}^{2N}\left(\sin\left(1+\frac{x}{n}\right)+(-1)^n\right)^2$$

Clearly, this function is defined for all $x\in\mathbb{R}$ and we know

$$0\leq \sum_{n=N+1}^{2N}\left(\sin\left(1+\frac{x}{n}\right)+(-1)^n\right)^2\leq \sum_{n=N+1}^{2N}4=4(2N-N)=4N$$

Thus, we know that the infimum of $f(x)$ over the reals exists (as well as the supremum) and is well defined. We shall show that this infimum is $0$. To do this, we will show that a subsequence of real numbers is equidistributed over $[0,4N]$. First normalize by $4N$ so that

$$0\leq \frac{f(x)}{4N}\leq 1$$

Next, consider the sequence $x_k=k(2N)!$ for $k\in\mathbb{N}$. If we can show that

$$a_k=\frac{1}{4N}\sum_{n=N+1}^{2N}\left(\sin\left(1+\frac{k(2N)!}{n}\right)+(-1)^n\right)^2$$

is equidistributed over $[0,1]$ then we are done. To do this, we will use Weyl's criterion. That is, a sequence $a_k$ is equidistributed over $[0,1]$ if and only if for all $l\in\mathbb{N}$ the limit

$$\lim_{m\to\infty}\frac{1}{m}\sum_{k=1}^m e^{2\pi i l a_k}=0$$

Now, plugging our sequence into the test we get

$$\lim_{m\to\infty}\left|\frac{1}{m}\sum_{k=1}^m e^{2\pi i l a_k}\right|=\lim_{m\to\infty}\left|\frac{1}{m}\sum_{k=1}^m \exp\left[ \frac{2\pi i l}{4N}\sum_{n=N+1}^{2N}\left(\sin\left(1+\frac{k(2N)!}{n}\right)+(-1)^n\right)^2\right]\right|$$

$$\lim_{m\to\infty}\left|\frac{1}{m}\sum_{k=1}^m \prod_{n=N+1}^{2N}\exp\left[ \frac{2\pi i l}{4N}\left(\sin\left(1+\frac{k(2N)!}{n}\right)+(-1)^n\right)^2\right]\right|$$

Since these are finite sums and products, there is no issue with reversing their order:

$$=\lim_{m\to\infty}\left| \prod_{n=N+1}^{2N}\frac{1}{m}\sum_{k=1}^m\exp\left[ \frac{2\pi i l}{4N}\left(\sin\left(1+\frac{k(2N)!}{n}\right)+(-1)^n\right)^2\right]\right|$$

$$=\prod_{n=N+1}^{2N}\lim_{m\to\infty}\left|\frac{1}{m}\sum_{k=1}^m\exp\left[ \frac{2\pi i l}{4N}\left(\sin\left(1+\frac{k(2N)!}{n}\right)+(-1)^n\right)^2\right]\right|$$

Thus, if we can show that

$$\lim_{m\to\infty}\left|\frac{1}{m}\sum_{k=1}^m\exp\left[ \frac{2\pi i l}{4N}\left(\sin\left(1+\frac{k(2N)!}{n}\right)+(-1)^n\right)^2\right]\right|=0$$

for arbitrary $n\leq 2N$ then we are done. To begin, since $n\leq 2N$, it is clear that

$$1+\frac{k(2N)!}{n}=1+k\frac{(2N)!}{n}$$

is an arithmetic sequence that increases by $(2N)!/n$ at each step. To simplify notation, we may as well call this natural number $b$. Then the problem simplifies to showing that

$$\lim_{m\to\infty}\left|\frac{1}{m}\sum_{k=1}^m\exp\left[ \frac{2\pi i l}{4N}\left(\sin\left(bk+1\right)+(-1)^n\right)^2\right]\right|=0$$

for some $b\in\mathbb{N}$ and all $l\in\mathbb{N}$. Next, we will separate the $\sin(x)$ function

$$\sin(kb+1)=\cos(1)\sin(kb)+\sin(1)\cos(kb)$$

Now,

$$\left|\sum_{k=1}^m\exp\left[ \frac{2\pi i l}{4N}\left(\sin\left(bk+1\right)+(-1)^n\right)^2\right]\right|=\left|\sum_{k=1}^m\exp\left[ \frac{2\pi i l}{4N}\left(\cos(1)\sin(kb)+\sin(1)\cos(kb)+(-1)^n\right)^2\right]\right|$$

$$=\left|\sum_{k=1}^m\exp\left[ \frac{2\pi i l}{4N}\left(\cos^2(1)\sin^2(kb) + 2 \cos(1)\sin(kb) \sin(1)\cos(kb) + \sin(1)^2\cos^2(kb) + 2 \cos(1)\sin(kb) (-1)^n + 2 \sin(1)\cos(kb) (-1)^n + 1\right)\right]\right|$$

As this is extremely difficult to read, let us rename these terms $s_1$ through $s_5$ (where $s_i$ is real):

$$=\left|\sum_{k=1}^m\exp\left[ i\left(s_1\sin^2(kb) + s_2\sin(kb) \cos(kb) + s_3\cos^2(kb) + s_4\sin(kb) + s_5\cos(kb) + 1\right)\right]\right|$$

Now, we can rewrite the exponential as

$$\exp\left[ i\left(s_1\sin^2(kb) + s_2\sin(kb) \cos(kb) + s_3\cos^2(kb) + s_4\sin(kb) + s_5\cos(kb) + 1\right)\right]$$ $$=e^{i}\exp\left[ i\left(s_1\sin^2(kb) + s_2\sin(kb) \cos(kb) + s_3\cos^2(kb) + s_4\sin(kb) + s_5\cos(kb) \right)\right]$$

$$=e^{i}\exp\left[ i\left((s_3+s_5)+(s_2+s_4)kb+\frac{1}{2}(2s_1-2s_3-s_5)k^2b^2+\cdots \right)\right]$$

where the infinite series is the Taylor series expansion for the trigonometric functions from the previous equality. What is important to note is that each power of $k$ will have an imaginary coefficient (as the addition of real numbers $s_i$ is multiplied by $i$) which go to zero (as sums and products of sinusoids are analytic, the coefficients must go to zero). Thus, we can rewrite this exponential as

$$=e^{i+g_0}\exp\left({\sum_{q=1}^\infty g_q k^q}\right)$$

where $g_q$ is a purely imaginary number. Having thoroughly run roughshod over all of our math at this point, we can put this series back into our original sum from $k=1$ to $m$:

$$\left|\sum_{k=1}^m\exp\left[ \frac{2\pi i l}{4N}\left(\sin\left(bk+1\right)+(-1)^n\right)^2\right]\right|=\left|\sum_{k=1}^me^{i+g_0}\exp\left({\sum_{q=1}^\infty g_q k^q}\right)\right|$$

$$\left|e^{i(1+\text{Im}(g_0)}\right|\left|\sum_{k=1}^m\prod_{q=1}^\infty\exp\left( g_q k^q\right)\right|$$

As the infinite product converges absolutely, we can switch it with the finite sum (and discard $e^{i(1+\text{Im}(g_0)}$)

$$=\left|\prod_{q=1}^\infty\sum_{k=1}^m\exp\left( g_q k^q\right)\right|=\prod_{q=1}^\infty\left|\sum_{k=1}^m\exp\left( g_q k^q\right)\right|$$

At this point, we are leaving what I at least am familiar with and instead journey into the land of special functions and limits in mathematica. That is, if anyone can fill in more details than what I will put down in this next section, please feel free.

First, note that we can approximate the finite sum with its integral counterpart to get

$$\sum_{k=1}^m\exp\left( g_q k^q\right)\approx\int_1^m\exp\left( g_q x^q\right)dx=\frac{E_{\frac{q-1}{q}}(-g_q)-m E_{\frac{q-1}{q}}\left(-g_q m^q\right)}{q}$$

Now, note that the next detail is slightly ambiguous, but it seems that since $Re(g_q)=0$ and $q>0$

$$\lim_{m\to\infty}m E_{\frac{q-1}{q}}\left(-g_q m^q\right)=0$$

Again, I do not have a proof for this and am only able to submit the following graph produced in mathematica as evidence

Evidence

As you can see, for $1\leq q\leq 10$ and $-10\leq \text{Im}(g_q)\leq 10$ (with Re$(g_q)=0$) the limit is always $0$ (the artifact at the origin is simply because I set $m=1000$ to get this plot). Then for large $m$, the expression above becomes

$$\frac{E_{\frac{q-1}{q}}(-g_q)-m E_{\frac{q-1}{q}}\left(-g_q m^q\right)}{q}\approx \frac{E_{\frac{q-1}{q}}(-g_q)}{q}$$

In much the same way as above, I conjecture (and numerical evidence supports), that

$$\left|E_{\frac{q-1}{q}}(-g_q)\right|$$

goes to $0$ for large $q$ (mainly since $|g_q|\to 0$). Especially, it should be the case that this expression is bounded above by some constant (let us call it $Q$). Perhaps someone with more experience with complex analysis could investigate? With this, we get

$$\lim_{m\to\infty}\frac{1}{m}\prod_{q=1}^\infty\left|\sum_{k=1}^m\exp\left( g_q k^q\right)\right|\leq \lim_{m\to\infty}\frac{1}{m}\prod_{q=1}^\infty\left|\frac{Q}{q}\right|=0$$

After all that handwaving and limits by inspection, we have finally arrived at our original goal: namely that

$$a_k=\frac{1}{4N}\sum_{n=N+1}^{2N}\left(\sin\left(1+\frac{k(2N)!}{n}\right)+(-1)^n\right)^2$$

is equidistributed on $[0,1]$. Now, we can return to more solid ground. By definition, there exist infinite $k$ such that $a_k<1/(64\cdot 4N)$. Define $x=k_0(2N)!$ where $k_0$ is the smallest such $k$ where the inequality holds. Then we have

$$\frac{1}{64\cdot 4N}>\frac{f(x)}{4N}=\frac{1}{4N}\sum_{n=N+1}^{2N}\left(\sin\left(1+\frac{x}{n}\right)+(-1)^n\right)^2$$

$$\sum_{n=N+1}^{2N}\left(\sin\left(1+\frac{x}{n}\right)+(-1)^n\right)^2<\frac{1}{64}$$

Since this must hold as we sum from $N+1\leq n\leq 2N$, it must hold for the individual $n$. That is, for $N+1\leq n\leq 2N$

$$\left(\sin\left(1+\frac{x}{n}\right)+(-1)^n\right)^2<\frac{1}{64}$$ $$\left|\sin\left(1+\frac{x}{n}\right)+(-1)^n\right|<\frac{1}{8}$$

This implies that

$$\frac{7}{8} <\sin\left(1+\frac{x}{n}\right)\leq 1$$

for even $n$ and

$$-1 \leq\sin\left(1+\frac{x}{n}\right)<-\frac{7}{8}$$

for odd $n$. We can use these bounds in our original equation

$$\left|\sum_{n=N+1}^{2N}\frac{(-1)^n}{\sqrt{n}}\sin\left(1+\frac{x}{n}\right)\right|>\frac{7}{8}\left|\sum_{n=N+1}^{2N}\frac{1}{\sqrt{n}}\right|$$

Now, one bound for this sum is

$$\frac{7}{8}\left|\sum_{n=N+1}^{2N}\frac{1}{\sqrt{n}}\right|=\frac{7}{8}\sum_{n=N+1}^{2N}\frac{1}{\sqrt{n}}>\frac{7}{8}\int_N^{2N+1}\frac{1}{\sqrt{x}}dx$$

$$=\frac{7}{4}(\sqrt{2N+1}-\sqrt{N})>\frac{7}{4}\sqrt{2N}-\sqrt{N})=\frac{7}{4}\sqrt{N}(\sqrt{2}-1)$$

$$\geq\frac{7}{4}\sqrt{2}(\sqrt{2}-1)=\frac{7}{2}-\frac{7}{2 \sqrt{2}}=1.02513>1$$

This is a contradiction. Thus, the series in question does not uniformly converge.

In conclusion, we have proved that

$$\sum_{n=1}^\infty\frac{(-1)^n}{\sqrt{n}}\sin\left(1+\frac{x}{n}\right)$$

does not converge uniformly on the reals. Unfortunately, there are a few details in the middle that need to be cleaned up by someone other than me as I do not trust my knowledge/expertise to do so.

QC_QAOA
  • 11,796
4

The sum is not uniformly convergent on $\mathbb{R}$.

Take $\epsilon \in (0,\frac{1}{10})$. Suppose $N$ is large such that $|\sum_{N \le n \le 2N} \frac{(-1)^n}{\sqrt{n}}\sin(1+\frac{x}{n})| \le \epsilon$ for all $x \in \mathbb{R}$. Take $X = 2\pi\prod_{N \le n \le 2N} n$. Independent of the specific choice of $X$, we of course have $$\frac{1}{X}\int_0^{X} \left|\sum_{N \le n \le 2N} \frac{(-1)^n}{\sqrt{n}}\sin(1+\frac{x}{n})\right|^2dx \le \epsilon^2.$$ But due to the specific choice, we have $$\frac{1}{X}\int_0^{X} \left|\sum_{N \le n \le 2N} \frac{(-1)^n}{\sqrt{n}}\sin(1+\frac{x}{n})\right|^2dx$$ $$= \frac{1}{X}\int_0^X \sum_{N \le n,m \le 2N} \frac{(-1)^{n+m}}{\sqrt{nm}}\sin(1+\frac{x}{n})\sin(1+\frac{x}{m})dx$$ $$ = \frac{1}{X}\sum_{N \le n \le 2N} \frac{1}{n}\left(\frac{X}{2}-\frac{1}{4}n\sin(\frac{2(n+X)}{n})+\frac{1}{4}n\sin(2)\right),$$ where we used $\int \sin(1+\frac{x}{n})\sin(1+\frac{x}{m})dx = \frac{1}{2}mn\left(\frac{\sin(x(\frac{1}{n}-\frac{1}{m}))}{m-n}-\frac{\sin(\frac{x}{m}+\frac{x}{n}+2)}{m+n}\right)$ for $m \not = n$ (which takes the same value at $0$ and $X$ by our choice of $X$) and $\int \sin^2(1+\frac{x}{n})dx = \frac{x}{2}-\frac{1}{4}n\sin(\frac{2(n+x)}{n})$. And once again by our choice of $X$, we end up with $$\frac{1}{X}\sum_{N \le n \le 2N} \frac{X}{2n},$$ which is around $\frac{1}{2}\ln(2)$, much greater than $\frac{1}{100}$.

mathworker21
  • 34,399
  • 1
    Nice proof. I think there is a typo: $\frac{1}{4}\sin(\frac{2(n+X)}{n})$ should be $\frac{1}{4}n\sin(\frac{2(n+X)}{n})$ correct? Also, I'm not sure you actually need $K$ in your answer. When you say "choose $K$ large enough to basically get $\frac{1}{X}\sum_{N \le n \le 2N} \frac{X}{2n}$", I think that it is exactly equal to this quantity regardless of $K$. Everything else seems to cancel out. Other than those two things, again great proof. The integral was a great insight. – QC_QAOA May 04 '20 at 16:25
  • 2
    @QC_QAOA the idea was as follows. The only reason that $\sum_{n \le N} \frac{(-1)^n}{\sqrt{n}}\sin(1+\frac{x}{n})$ converges for a fixed $x$ is that as $n \to \infty$, $\sin(1+\frac{x}{n})$ is basically $\frac{x}{n}$. However, when talking about uniform convergence, $N$ is fixed and $x$ is arbitrary. And since $x$ is arbitrary, $\sin(1+\frac{x}{n})$ is basically arbitrary. I'm sure you can choose an explicit, smartly chosen, $x$ to make the sum large, but the sum should be large on average, since $\sin(1+\frac{x}{n})$ is then like a constant (bounded away from $0$). – mathworker21 May 04 '20 at 16:35
  • 1
    @QC_QAOA and the easiest way to compute is via $L^2$ integral. anyways, i liked a lot of the ideas in your answer also! – mathworker21 May 04 '20 at 16:35
  • Maybe I am missing something, but first of all, why should there be an $N$ large enough to make the sum in the second paragraph small for all $x\in\mathbb{R}$? I am also missing how the integral you are computing bounds the sum pointwise for all $x$. – robjohn May 04 '20 at 22:20
  • @robjohn I assume that the sum is uniformly convergent, so the existence of such an $N$ follows from the Cauchy criterion for uniform convergence: $\sum_n f_n(x)$ converges uniformly if and only if for any $\epsilon > 0$, there is an $N_0$ so that for all $N,M \ge N_0$, $|\sum_{N \le n \le M} f_n(x)| \le \epsilon$ for all $x$. I am just using the specific choice $M=2N$. Also, I don't bound the sum pointwise for all $x$. I get an upper bound on the integral and a lower bound on the integral; these two contradict. – mathworker21 May 04 '20 at 22:34
  • (+1) Oh, my bad. I missed that's you were showing it NOT uniformly convergent. – robjohn May 04 '20 at 22:57
  • Do you think that this method can be used to classify the convergence behaviour of $\sum (-1)^n n^{-\epsilon} \sin(c+x/n)$ for any $c \in \mathbb{R}, \epsilon \in (0,1)$? Or do you think the general problem is sufficiently complicated to warrant its own question? – MathematicsStudent1122 May 11 '20 at 04:27
  • @MathematicsStudent1122 im assuming you're still talking about uniform convergence. And yea, still not uniformly convergent. I'm not sure why you're interested in that question. As I explained in my comment above, it's just obvious that these things are not uniformly convergent, since $x$ can be anything, so you can't expect $\sin(c+\frac{x}{n})$ to be small enough.. – mathworker21 May 11 '20 at 04:36
-1

REVISED

Consider the sum $$ S(x):=\sum^{\infty}_{n=1}\frac{(-1)^n}{\sqrt{n}}\sin\left(1+\frac{x}{n}\right)\tag 1 $$ It holds $$ S_1=\sum_{k\geq 1}\left[\frac{(-1)^k}{\sqrt{k}}\sin\left(1+\frac{x}{k}\right)-\sin(1)\frac{(-1)^k}{\sqrt{k}}\right]= $$
$$ =\sum_{k\geq1}\sum_{n\geq 0}[\frac{(-1)^k}{\sqrt{k}}\sin(1)\frac{(-1)^nx^{2n}}{k^{2n}(2n)!}-\frac{(-1)^k}{\sqrt{k}}\cos(1)\frac{(-1)^nx^{2n+1}}{k^{2n+1}(2n+1)!}- $$ $$ -\sin(1)\frac{(-1)^k}{\sqrt{k}}\delta_{n,0}]. $$ This last sum is absolutely convergent.

Hence we can interchange the oder of summation to get $$ S_1=\sum_{n\geq0}\sum_{k\geq 1}[\frac{(-1)^k}{\sqrt{k}}\sin(1)\frac{(-1)^nx^{2n}}{k^{2n}(2n)!}-\frac{(-1)^k}{\sqrt{k}}\cos(1)\frac{(-1)^nx^{2n+1}}{k^{2n+1}(2n+1)!}- $$ $$ -\sin(1)\frac{(-1)^k}{\sqrt{k}}\delta_{n,0}]= $$ $$ =\sum_{n\geq 0}\frac{(-1)^{n+1} \sin (1) x^{2 n} \zeta \left(2 n+\frac{1}{2}\right)}{(2 n)!}+\sum_{n\geq0}\frac{(-1)^{n+2} 2^{\frac{1}{2}-2 n} \sin (1) x^{2 n} \zeta \left(2 n+\frac{1}{2}\right)}{(2 n)!}+ $$ $$ +\sum_{n\geq 0}\frac{(-1)^{n+1} \cos (1) x^{2 n+1} \zeta \left(2 n+\frac{3}{2}\right)}{(2 n+1)!}+ $$ $$ +\sum_{n\geq 0}\frac{(-1)^{n+2} 2^{-2 n-\frac{1}{2}} \cos (1) x^{2 n+1} \zeta \left(2 n+\frac{3}{2}\right)}{(2 n+1)!}-c= $$ $$ =\sum_{n\geq 1}\frac{Im(s(n))}{n!}x^n=S_0(x)-c,\tag 2 $$ where $c=(-1+\sqrt{2})\zeta(1/2)\sin(1)$ and $$ S_0(x)=c+\sum_{n\geq 1}\frac{Im(s(n))}{n!}x^n,\tag 3 $$ $$ s(m)=i^me^{i}(2^{1/2-m}-1)\zeta\left(\frac{1}{2}+m\right).\tag 4 $$ Clearly $S_0(x)$ is analytic in all $\textbf{R}$. Hence $S(x)$ converges always and uniformly to an analytic function of $x\in\textbf{R}$ (since also the $s(m)$ are bounded).

REMARKS

Set $$ C_N(x)=\sum^{N}_{n=1}\frac{(-1)^n}{\sqrt{n}}\sin\left(1+\frac{x}{n}\right).\tag 5 $$ Then $$ a_N(m)=\left[\frac{d^{2m}}{dx^{2m}}C_N(x)\right]_{x=0}=(-1)^m\sum^{N}_{n=1}\frac{(-1)^n}{\sqrt{n}}\sin(1)\frac{1}{n^{2m}}\tag 6 $$ $$ b_N(m)=\left[\frac{d^{2m+1}}{dx^{2m+1}}C_N(x)\right]_{x=0}=(-1)^m\sum^{N}_{n=1}\frac{(-1)^n}{\sqrt{n}}\cos(1)\frac{1}{n^{2m+1}}.\tag 7 $$ Hence from Taylor's theorem for the finite sum (5) we get $$ C_N(x)=C_N(0)+\sum^{\infty}_{m=1}a_N(m)\frac{x^{2m}}{(2m)!}+\sum^{\infty}_{m=0}b_N(m)\frac{x^{2m+1}}{(2m+1)!}x^{2m+1}\tag 8 $$ and $$ C_N(x)=s_N(0)+\sum^{\infty}_{m=1}\frac{s_N(m)}{m!}x^m,\tag 9 $$ where $s_N(m)$ is such that (for $m=0,1,2,3,\ldots$): $$ s_N(2m)=a_N(m)\textrm{, }s_N(2m+1)=b_N(m).\tag{10} $$ Hence $$ |C_N(x)-C_M(x)|=|\left(\sum^{\infty}_{m=1}a_N(m)\frac{x^{2m}}{(2m)!}+\sum^{\infty}_{m=0}b_N(m)\frac{x^{2m+1}}{(2m+1)!}\right)- $$ $$ -\left(\sum^{\infty}_{m=1}a_M(m)\frac{x^{2m}}{(2m)!}+\sum^{\infty}_{m=0}b_M(m)\frac{x^{2m+1}}{(2m+1)!}\right)|= $$ $$ = |\left(\sum^{\infty}_{m=1}a_N(m)\frac{x^{2m}}{(2m)!}-\sum^{\infty}_{m=1}a_M(m)\frac{x^{2m}}{(2m)!}\right)+ $$ $$ +\left(\sum^{\infty}_{m=0}b_N(m)\frac{x^{2m+1}}{(2m+1)!}-\sum^{\infty}_{m=0}b_M(m)\frac{x^{2m+1}}{(2m+1)!}\right)|\leq $$ $$ \leq\sum^{\infty}_{m=1}\frac{|x|^{2m}}{(2m)!}\left|a_{N}(m)-a_{M}(m)\right|+ $$ $$ +\sum^{\infty}_{m=0}\frac{|x|^{2m+1}}{(2m+1)!}\left|b_{N}(m)-b_{M}(m)\right|= $$ $$ =|\sin(1)|\sum^{\infty}_{m=1}\frac{|x|^{2m}}{(2m)!}\left|\sum^{M}_{n=N}\frac{(-1)^n}{n^{2m+1/2}}\right|+ $$ $$ +|\cos(1)|\sum^{\infty}_{m=0}\frac{|x|^{2m+1}}{(2m+1)!}\left|\sum^{M}_{n=N}\frac{(-1)^n}{n^{2m+3/2}}\right|\leq $$ $$ \leq|\sin(1)|\sum^{\infty}_{m=1}\frac{|x|^{2m}}{(2m)!}\sum^{M}_{n=N}\frac{1}{n^{2m+1/2}}+|\cos(1)|\sum^{\infty}_{m=0}\frac{|x|^{2m+1}}{(2m+1)!}\sum^{M}_{n=N}\frac{1}{n^{2m+3/2}}\tag{11} $$ But when $M>N>0$ and $m=0,1,2,\ldots$ $$ \sum^{M}_{n=N}n^{-2m-3/2}\leq\sum^{M}_{n=N}n^{-3/2}\tag{12} $$ Hence (using $|\cos(1)|,|\sin(1)|\leq 1$): $$ |C_N(x)-C_M(x)|\leq $$ $$ \leq\left( |\sin(1)|\sum^{\infty}_{m=1}\frac{|x|^{2m}}{(2m)!}+|\cos(1)|\sum^{\infty}_{m=0}\frac{|x|^{2m+1}}{(2m+1)!}\right)\left|\sum^{M}_{n=N}n^{-3/2}\right|< $$ $$ <\left(e^{|x|}-1\right)\left|\sum^{M}_{n=N}n^{-3/2}\right|<\epsilon,\tag{13} $$ for all fixed $x\in\textbf{R}$ when $M>N>0$. Hence $S(x)$ is uniformly convergent in $\textbf{R}$.