Finding the first three nonzero terms in the Maclaurin series: $y=\frac{x}{\sin(x)}$ As the title says I would like to find the first three nonzero terms in the Maclaurin series $$y=\frac{x}{\sin(x)}$$
I have the first few terms for the expansion for $\sin(x)=x-\frac{x^3}{6}+\frac{x^5}{120}-\frac{x^7}{5040}....$
For the next step can I just say the next few terms are: $1-\frac{6}{x^2}+\frac{120}{x^4}....$ or should I do algebraic long division? If so what by and could anyone start me off?
Thank you!
 A: The Bernoulli polynomials $B_k(x)$ for $k\ge0$ are defined by the exponential generating function
\begin{equation*}
\frac{z\textrm{e}^{xz}}{\textrm{e}^z-1}=\sum_{k=0}^\infty B_k(x)\frac{z^k}{k!}, \quad |z|<2\pi
\end{equation*}
for $x\in\mathbb{R}$. By the Euler formula
$$
\textrm{e}^{\textrm{i}x}=\cos x+\textrm{i}\sin x,
$$
we find the relation
$$
\sin x=\frac{\textrm{e}^{\textrm{i}x}-\textrm{e}^{-\textrm{i}x}}{2\textrm{i}}.
$$
Then
\begin{align*}
\frac{x}{\sin x}&=\frac{2\textrm{i}x} {\textrm{e}^{\textrm{i}x}-\textrm{e}^{-\textrm{i}x}}\\
&=\frac{(2\textrm{i}x)\textrm{e}^{(2\textrm{i}x)/2}} {\textrm{e}^{(2\textrm{i}x)}-1}\\
&=\sum_{k=0}^\infty B_k\biggl(\frac12\biggr)\frac{(2\textrm{i}x)^k}{k!}\\
&=\sum_{k=0}^\infty (2\textrm{i})^kB_k\biggl(\frac12\biggr)\frac{x^k}{k!}\\
&=\sum_{k=0}^\infty (2\textrm{i})^{2k}B_{2k}\biggl(\frac12\biggr)\frac{x^{2k}}{(2k)!}\\
&=\sum_{k=0}^\infty (-1)^k2^{2k}B_{2k}\biggl(\frac12\biggr)\frac{x^{2k}}{(2k)!}\\
&=\sum_{k=0}^\infty (-1)^{k+1}2^{2k}\biggl(1-\frac1{2^{2k-1}}\biggr)B_{2k}\frac{x^{2k}}{(2k)!}\\
&=2\sum_{k=0}^\infty (-1)^{k+1}\bigl(2^{2k-1}-1\bigr)B_{2k}\frac{x^{2k}}{(2k)!}
\end{align*}
for $|x|<\pi$, where $B_k(0)=B_k$ and
\begin{align*}
B_0&=1, & B_2&=\frac{1}{6},& B_4&=-\frac{1}{30},& B_6&=\frac{1}{42},& B_8&=-\frac{1}{30},\\
B_{10}&=\frac{5}{66},& B_{12}&=-\frac{691}{2730},& B_{14}&=\frac{7}{6},& B_{16}&=-\frac{3617}{510}, & B_{18}&=\frac{43867}{798}.
\end{align*}
A: You certainly cannot so: it is not a Maclaurin series.
Hint:
First simplify the fraction:
$$\frac x{\sin x}=\frac x{x-\cfrac{x^3}6+\cfrac{x^5}{120}+o(x^5)}=\frac 1{1-\cfrac{x^2}6+\cfrac{x^4}{120}+o(x^4)},$$
then perform the division by increasing powers of the numerator $1$ by $1-\frac{x^2}6+\frac{x^4}{120}$ up to degree $4$.
