Marion Problem 3.30

Find the Fourier expansion of the function F(t)=(Piecewise[{{-sin ωt,, -π/ω<t<0}, {+sin ωt,, 0<t<π/ω}}])  in the interval-π/ω<t<π/ω.

f2[t_,ω_,m_]:=((2/π)+Sum[(4/( π(1-(n^2))))Cos[n ω t] ,{n,2,2(m-1),2}]);
g2[t_,ω_]:=Piecewise[{{-Sin[ω t],-(π/ω)≤t≤0},{+Sin[ω t],0≤t≤(π/ω)}}]

In the periodical interval, calculate and plot the sums of the first three terms
to demonstrate the convergence of the series.

Manipulate[Plot[{g2[t,ω],f2[t,ω,m]},{t,-(π/ω),(π/ω)},
PlotRange->{{-(π/ω),(π/ω)},{-0.2,1.2}},
AxesLabel->{t,F[t]},
PlotStyle->{{RGBColor[0, 0.501961, 1],Thickness[0.010]},{Thick,Orange}},
ImageSize->600
],
{{m,3,"Number of terms"},{1,2,3,4,5,10,25,50,100},Setter},
{{ω,π},0.1,10,0.01, Appearance->"Labeled"}
]