I am having trouble finding the Fourier series of a 2nd order ODE. Should I be using the piecewise function as well to set up the range for t?
Solve 𝑦′′ + 𝜔^2𝑦 = 𝑟(𝑡)$ y'' + \omega^2 𝑦 = r(t) $, where 𝑟(𝑡) = |𝑡|, -𝜋 < 𝑡 < 𝜋$ r(t) = |t|, -\pi < t < \pi $ by using Fourier series.
So far I have set up the odeODE and set equal to r[t]
r[t]=y''[t]+omega^2*y[t]
Plot(r[t],{t,-Pi,Pi}]
Any
r[t] = y''[t] + ω^2 y[t]
Plot(r[t], {t, -π, π}]
Any help with the mathematicaMathematica code would be greatly appreciated. How can I find AnAn
, BnBn
with the function being an ODE?