#set document(title: "4.5 Applications of Fourier Series", author: "Jiří Lebl") #set page(width: 8.5in, height: auto, margin: 1in) #import "@preview/cetz:0.5.2" #set text(font: ("STIX Two Text", "Libertinus Serif", "New Computer Modern"), size: 10.5pt, lang: "en") #show math.equation: set text(font: ("STIX Two Math", "New Computer Modern Math")) #set par(justify: true, leading: 0.62em, spacing: 0.9em) #set enum(spacing: 1.1em) // room between list items so tall inline fractions don't collide #set list(spacing: 1.1em) #set table(stroke: 0.5pt + rgb("#c7ccd3")) #let BLUE = rgb("#183B6F") // brand navy — section bars + example/solution labels (white on navy 11.09:1) #let ORANGE = rgb("#A94509") // brand primary-700 — AA-safe deep orange for TEXT (5.93:1 on white; raw brand #F37021 is 2.94:1 and must never carry text) #let RED = rgb("#DC2626") // brand error-600 #let GREEN = rgb("#059669") // brand success-600 (decoration only; small green text uses green-text #007942) #show heading.where(level: 1): it => block(width: 100%, above: 0pt, below: 16pt, fill: gradient.linear(BLUE, rgb("#2C5AA0")), inset: (x: 14pt, y: 12pt), radius: 3pt, text(fill: white, weight: "bold", size: 19pt, it.body)) #show heading.where(level: 2): it => block(width: 100%, above: 18pt, below: 10pt, fill: BLUE, inset: (x: 10pt, y: 6pt), radius: 2pt, text(fill: white, weight: "bold", size: 12pt, it.body)) #show heading.where(level: 3): it => text(fill: ORANGE, weight: "bold", size: 12.5pt, it.body) #show heading.where(level: 4): it => text(fill: BLUE, weight: "bold", size: 10.5pt, it.body) #let examplebox(label, title, body) = block(width: 100%, breakable: true, fill: rgb("#EFF1F5"), stroke: 0.5pt + rgb("#CFDDF0"), radius: 4pt, inset: 10pt, above: 12pt, below: 12pt)[ #block(below: 6pt)[#box(fill: BLUE, inset: (x: 6pt, y: 2pt), radius: 2pt, text(fill: white, weight: "bold", size: 8.5pt, label)) #h(0.4em) #strong[#title]] #body] // rail = decorative left rule (raw brand token); labelcolor = AA-safe label text shade #let notebox(label, rail, labelcolor, tint, body) = block(width: 100%, breakable: true, fill: tint, stroke: (left: 3pt + rail), inset: (left: 10pt, rest: 8pt), radius: (right: 4pt), above: 11pt, below: 11pt)[ #text(fill: labelcolor, weight: "bold", size: 7.5pt, tracking: 0.5pt)[#upper(label)] #linebreak() #body] #let solutionbox(body) = block(above: 4pt, below: 8pt)[ #text(fill: BLUE, weight: "bold", size: 8.5pt)[Solution] #linebreak() #body] #let figph(msg) = block(width: 100%, height: 60pt, fill: rgb("#f6f7f9"), stroke: (paint: rgb("#c7ccd3"), dash: "dashed"), radius: 4pt, inset: 10pt)[ #align(center + horizon, text(fill: rgb("#889"), style: "italic", size: 9pt, msg))] // Standardize inlined figure sizes: measure the natural CeTZ canvas, then scale to a // consistent envelope (aspect-aware; see build_typst.py FIG_* constants). Unlike the // print preamble, dimensions are FLOORED: in an editor a user can trim a figure to a // degenerate 1-D shape (a bare line), and w/h or tw/w would then divide by zero. #let _STD_W = 3.5 #let _WIDE_W = 5.6 #let _MAX_H = 3.4 #let _ASPECT_WIDE = 2.2 #let _UPSCALE_MAX = 1.15 #let stdfig(body) = context { let m = measure(body) let w = calc.max(m.width / 1in, 0.01) let h = calc.max(m.height / 1in, 0.01) let tw = if w / h > _ASPECT_WIDE { _WIDE_W } else { _STD_W } let s = calc.min(tw / w, _MAX_H / h, _UPSCALE_MAX) align(center, box(scale(x: s * 100%, y: s * 100%, reflow: true, body))) } #show figure: set block(breakable: false) #set figure(gap: 8pt) #show figure.caption: set text(size: 8.5pt, fill: rgb("#555")) == 4.5#h(0.6em)Applications of Fourier Series === Periodically Forced Oscillation Let us return to the forced oscillations. Consider a mass-spring system as before, where we have a mass #math.equation(block: false, alt: "m")[$m$] on a spring with spring constant #math.equation(block: false, alt: "k")[$k$], with damping #math.equation(block: false, alt: "c")[$c$], and a force #math.equation(block: false, alt: "F open parenthesis t close parenthesis")[$F ( t )$] applied to the mass. Suppose the forcing function #math.equation(block: false, alt: "F open parenthesis t close parenthesis")[$F ( t )$] is #math.equation(block: false, alt: "2 L")[$2 L$]-periodic for some #math.equation(block: false, alt: "L greater than 0")[$L > 0$]. We have already seen this problem in chapter 2 with a simple #math.equation(block: false, alt: "F open parenthesis t close parenthesis")[$F ( t )$]. #figure(figph[Diagram of a block m joined to a fixed wall by a spring k, with a bold arrow labelled F of t pushing right on the block and damping c marked along the surface beneath.], alt: "Diagram of a block m joined to a fixed wall by a spring k, with a bold arrow labelled F of t pushing right on the block and damping c marked along the surface beneath.", caption: [Figure #math.equation(block: false, alt: "1")[$1$]]) The equation that governs this particular setup is #math.equation(block: true, alt: "m x double prime open parenthesis t close parenthesis plus c x prime open parenthesis t close parenthesis plus k x open parenthesis t close parenthesis equals F open parenthesis t close parenthesis .")[$m x^(″) ( t ) + c x^(′) ( t ) + k x ( t ) = F ( t ) .$] The general solution consists of (4.5.1) consists of the complementary solution #math.equation(block: false, alt: "x sub c")[$x_(c)$], which solves the associated homogeneous equation #math.equation(block: false, alt: "m x double prime plus c x prime plus k x equals 0")[$m x^(″) + c x^(′) + k x = 0$], and a particular solution of Equation (4.5.1) we call #math.equation(block: false, alt: "x sub p")[$x_(p)$]. For #math.equation(block: false, alt: "c greater than 0")[$c > 0$], the complementary solution #math.equation(block: false, alt: "x sub c")[$x_(c)$] will decay as time goes by. Therefore, we are mostly interested in a particular solution #math.equation(block: false, alt: "x sub p")[$x_(p)$] that does not decay and is periodic with the same period as #math.equation(block: false, alt: "F open parenthesis t close parenthesis")[$F ( t )$]. We call this particular solution the steady periodic solution and we write it as #math.equation(block: false, alt: "x sub s p")[$x_(s p)$] as before. What will be new in this section is that we consider an arbitrary forcing function #math.equation(block: false, alt: "F open parenthesis t close parenthesis")[$F ( t )$] instead of a simple cosine. For simplicity, let us suppose that #math.equation(block: false, alt: "c equals 0")[$c = 0$]. The problem with #math.equation(block: false, alt: "c greater than 0")[$c > 0$] is very similar. The equation #math.equation(block: true, alt: "m x double prime plus k x equals 0")[$m x^(″) + k x = 0$] has the general solution #math.equation(block: true, alt: "x open parenthesis t close parenthesis equals A cos open parenthesis ω sub 0 t close parenthesis plus B sin open parenthesis ω sub 0 t close parenthesis ,")[$x ( t ) = A cos ( ω_(0) t ) + B sin ( ω_(0) t ) ,$] where #math.equation(block: false, alt: "ω sub 0 equals the square root of the fraction k over m")[$ω_(0) = sqrt(frac(k, m))$]. Any solution to #math.equation(block: false, alt: "m x double prime open parenthesis t close parenthesis plus k x open parenthesis t close parenthesis equals F open parenthesis t close parenthesis")[$m x^(″) ( t ) + k x ( t ) = F ( t )$] is of the form #math.equation(block: false, alt: "A cos open parenthesis ω sub 0 t close parenthesis plus B sin open parenthesis ω sub 0 t close parenthesis plus x sub s p")[$A cos ( ω_(0) t ) + B sin ( ω_(0) t ) + x_(s p)$]. The steady periodic solution #math.equation(block: false, alt: "x sub s p")[$x_(s p)$] has the same period as #math.equation(block: false, alt: "F open parenthesis t close parenthesis")[$F ( t )$]. In the spirit of the last section and the idea of undetermined coefficients we first write #math.equation(block: true, alt: "F open parenthesis t close parenthesis equals the fraction c sub 0 over 2 plus ∑ n equals 1 infinity c sub n cos open parenthesis the fraction n π over L t close parenthesis plus d sub n sin open parenthesis the fraction n π over L t close parenthesis .")[$F ( t ) = frac(c_(0), 2) + ∑_(n = 1)^(∞) c_(n) cos ( frac(n π, L) t ) + d_(n) sin ( frac(n π, L) t ) .$] Then we write a proposed steady periodic solution #math.equation(block: false, alt: "x")[$x$] as #math.equation(block: true, alt: "x open parenthesis t close parenthesis equals the fraction a sub 0 over 2 plus ∑ n equals 1 infinity a sub n cos open parenthesis the fraction n π over L t close parenthesis plus b sub n sin open parenthesis the fraction n π over L t close parenthesis ,")[$x ( t ) = frac(a_(0), 2) + ∑_(n = 1)^(∞) a_(n) cos ( frac(n π, L) t ) + b_(n) sin ( frac(n π, L) t ) ,$] where #math.equation(block: false, alt: "a sub n")[$a_(n)$] and #math.equation(block: false, alt: "b sub n")[$b_(n)$] are unknowns. We plug #math.equation(block: false, alt: "x")[$x$] into the differential equation and solve for #math.equation(block: false, alt: "a sub n")[$a_(n)$] and #math.equation(block: false, alt: "b sub n")[$b_(n)$] in terms of #math.equation(block: false, alt: "c sub n")[$c_(n)$] and #math.equation(block: false, alt: "d sub n")[$d_(n)$]. This process is perhaps best understood by example. #examplebox("Example 1")[][ Suppose that #math.equation(block: false, alt: "k equals 2")[$k = 2$], and #math.equation(block: false, alt: "m equals 1")[$m = 1$]. The units are again the mks units (meters-kilograms-seconds). There is a jetpack strapped to the mass, which fires with a force of 1 newton for 1 second and then is off for 1 second, and so on. We want to find the steady periodic solution. #solutionbox[ The equation is, therefore, #math.equation(block: true, alt: "x double prime plus 2 x equals F open parenthesis t close parenthesis ,")[$x^(″) + 2 x = F ( t ) ,$] where #math.equation(block: false, alt: "F open parenthesis t close parenthesis")[$F ( t )$] is the step function #math.equation(block: true, alt: "0 i f minus 1 less than t less than 0 ,; 1 i f 0 less than t less than 1 ,")[$0 upright(i) upright(f) − 1 < t < 0 , \ 1 upright(i) upright(f) 0 < t < 1 ,$] extended periodically. We write #math.equation(block: true, alt: "F open parenthesis t close parenthesis equals the fraction c sub 0 over 2 plus ∑ n equals 1 infinity c sub n cos open parenthesis n π t close parenthesis plus d sub n sin open parenthesis n π t close parenthesis .")[$F ( t ) = frac(c_(0), 2) + ∑_(n = 1)^(∞) c_(n) cos ( n π t ) + d_(n) sin ( n π t ) .$] We compute #math.equation(block: true, alt: "c sub n equals ∫ minus 1 1 F open parenthesis t close parenthesis cos open parenthesis n π t close parenthesis d t equals ∫ 0 1 cos open parenthesis n π t close parenthesis d t equals 0 f o r n greater than or equal to 1 ,; c sub 0 equals ∫ minus 1 1 F open parenthesis t close parenthesis d t equals ∫ 0 1 d t equals 1 ,; d sub n equals ∫ minus 1 1 F open parenthesis t close parenthesis sin open parenthesis n π t close parenthesis d t; equals ∫ 0 1 sin open parenthesis n π t close parenthesis d t; equals [ the fraction minus cos open parenthesis n π t close parenthesis over n π ] t equals 0 1; equals the fraction 1 minus open parenthesis minus 1 close parenthesis to the power n over π n equals { the fraction 2 over π n, i f n o d d ,; 0, i f n e v e n .")[$c_(n) = ∫_(− 1)^(1) F ( t ) cos ( n π t ) d t = ∫_(0)^(1) cos ( n π t ) d t = 0 " " " " " " " " " " upright(f) upright(o) upright(r) " " n ≥ 1 , \ c_(0) = ∫_(− 1)^(1) F ( t ) d t = ∫_(0)^(1) d t = 1 , \ d_(n) = ∫_(− 1)^(1) F ( t ) sin ( n π t ) d t \ = ∫_(0)^(1) sin ( n π t ) d t \ = attach([ frac(− cos ( n π t ), n π) ], t: 1, b: t = 0) \ = frac(1 − ( − 1 )^(n), π n) = \{ frac(2, π n) & upright(i) upright(f) " " n " " upright(o) upright(d) upright(d) , \ 0 & upright(i) upright(f) " " n " " upright(e) upright(v) upright(e) upright(n) .$] So #math.equation(block: true, alt: "F open parenthesis t close parenthesis equals the fraction 1 over 2 plus ∑ n equals 1 n o d d infinity the fraction 2 over π n sin open parenthesis n π t close parenthesis .")[$F ( t ) = frac(1, 2) + ∑_(limits(n = 1)_(n " " upright(o) upright(d) upright(d)))^(∞) frac(2, π n) sin ( n π t ) .$] We want to try #math.equation(block: true, alt: "x open parenthesis t close parenthesis equals the fraction a sub 0 over 2 plus ∑ n equals 1 infinity a sub n cos open parenthesis n π t close parenthesis plus b sub n sin open parenthesis n π t close parenthesis .")[$x ( t ) = frac(a_(0), 2) + ∑_(n = 1)^(∞) a_(n) cos ( n π t ) + b_(n) sin ( n π t ) .$] Once we plug into the differential equation #math.equation(block: false, alt: "x double prime plus 2 x equals F open parenthesis t close parenthesis")[$x^(″) + 2 x = F ( t )$], it is clear that #math.equation(block: false, alt: "a sub n equals 0")[$a_(n) = 0$] for #math.equation(block: false, alt: "n greater than or equal to 1")[$n ≥ 1$] as there are no corresponding terms in the series for #math.equation(block: false, alt: "F open parenthesis t close parenthesis")[$F ( t )$]. Similarly #math.equation(block: false, alt: "b sub n equals 0")[$b_(n) = 0$] for #math.equation(block: false, alt: "n")[$n$] even. Hence we try #math.equation(block: true, alt: "x open parenthesis t close parenthesis equals the fraction a sub 0 over 2 plus ∑ n equals 1 n o d d infinity b sub n sin open parenthesis n π t close parenthesis .")[$x ( t ) = frac(a_(0), 2) + ∑_(limits(n = 1)_(n " " upright(o) upright(d) upright(d)))^(∞) b_(n) sin ( n π t ) .$] We plug into the differential equation and obtain #math.equation(block: true, alt: "x double prime plus 2 x equals ∑ n equals 1 n o d d infinity [ minus b sub n n squared π squared sin open parenthesis n π t close parenthesis ] plus a sub 0 plus 2 ∑ n equals 1 n o d d infinity [ b sub n sin open parenthesis n π t close parenthesis ]; equals a sub 0 plus ∑ n equals 1 n o d d infinity b sub n open parenthesis 2 minus n squared π squared close parenthesis sin open parenthesis n π t close parenthesis; equals F open parenthesis t close parenthesis equals the fraction 1 over 2 plus ∑ n equals 1 n o d d infinity the fraction 2 over π n sin open parenthesis n π t close parenthesis .")[$x^(″) + 2 x = ∑_(limits(n = 1)_(n " " upright(o) upright(d) upright(d)))^(∞) [ − b_(n) n^(2) π^(2) sin ( n π t ) ] + a_(0) + 2 ∑_(limits(n = 1)_(n " " upright(o) upright(d) upright(d)))^(∞) [ b_(n) sin ( n π t ) ] \ = a_(0) + ∑_(limits(n = 1)_(n " " upright(o) upright(d) upright(d)))^(∞) b_(n) ( 2 − n^(2) π^(2) ) sin ( n π t ) \ = F ( t ) = frac(1, 2) + ∑_(limits(n = 1)_(n " " upright(o) upright(d) upright(d)))^(∞) frac(2, π n) sin ( n π t ) .$] So #math.equation(block: false, alt: "a sub 0 equals the fraction 1 over 2")[$a_(0) = frac(1, 2)$], #math.equation(block: false, alt: "b sub n equals 0")[$b_(n) = 0$] for even #math.equation(block: false, alt: "n")[$n$], and for odd #math.equation(block: false, alt: "n")[$n$] we get #math.equation(block: true, alt: "b sub n equals the fraction 2 over π n open parenthesis 2 minus n squared π squared close parenthesis .")[$b_(n) = frac(2, π n ( 2 − n^(2) π^(2) )) .$] The steady periodic solution has the Fourier series #math.equation(block: true, alt: "x sub s p open parenthesis t close parenthesis equals the fraction 1 over 4 plus ∑ n equals 1 n o d d infinity the fraction 2 over π n open parenthesis 2 minus n squared π squared close parenthesis sin open parenthesis n π t close parenthesis .")[$x_(s p) ( t ) = frac(1, 4) + ∑_(limits(n = 1)_(n " " upright(o) upright(d) upright(d)))^(∞) frac(2, π n ( 2 − n^(2) π^(2) )) sin ( n π t ) .$] We know this is the steady periodic solution as it contains no terms of the complementary solution and it is periodic with the same period as #math.equation(block: false, alt: "F open parenthesis t close parenthesis")[$F ( t )$] itself. See Figure #math.equation(block: false, alt: "1")[$1$] for the plot of this solution. #figure(figph[Plot of the steady periodic solution over time 0 to 10, oscillating with constant undecayed amplitude between about 0.17 and 0.33, with period 2.], alt: "Plot of the steady periodic solution over time 0 to 10, oscillating with constant undecayed amplitude between about 0.17 and 0.33, with period 2.", caption: [Figure #math.equation(block: false, alt: "1")[$1$]: Plot of the steady periodic solution #math.equation(block: false, alt: "x sub s p")[$x_(s p)$] of Example #math.equation(block: false, alt: "1")[$1$].]) ] ] ==== Resonance Just like when the forcing function was a simple cosine, resonance could still happen. Let us assume #math.equation(block: false, alt: "c equals 0")[$c = 0$] and we will discuss only pure resonance. Again, take the equation #math.equation(block: true, alt: "m x double prime open parenthesis t close parenthesis plus k x open parenthesis t close parenthesis equals F open parenthesis t close parenthesis .")[$m x^(″) ( t ) + k x ( t ) = F ( t ) .$] When we expand #math.equation(block: false, alt: "F open parenthesis t close parenthesis")[$F ( t )$] and find that some of its terms coincide with the complementary solution to #math.equation(block: false, alt: "m x double prime plus k x equals 0")[$m x^(″) + k x = 0$], we cannot use those terms in the guess. Just like before, they will disappear when we plug into the left hand side and we will get a contradictory equation (such as #math.equation(block: false, alt: "0 equals 1")[$0 = 1$]). That is, suppose #math.equation(block: true, alt: "x sub c equals A cos open parenthesis ω sub 0 t close parenthesis plus B sin open parenthesis ω sub 0 t close parenthesis ,")[$x_(c) = A cos ( ω_(0) t ) + B sin ( ω_(0) t ) ,$] where #math.equation(block: false, alt: "ω sub 0 equals the fraction N π over L")[$ω_(0) = frac(N π, L)$] for some positive integer #math.equation(block: false, alt: "N")[$N$]. In this case we have to modify our guess and try #math.equation(block: true, alt: "x open parenthesis t close parenthesis equals the fraction a sub 0 over 2 plus t open parenthesis a sub N cos open parenthesis the fraction N π over L t close parenthesis plus b sub N sin open parenthesis the fraction N π over L t close parenthesis close parenthesis plus ∑ n equals 1 n not equal to N infinity a sub n cos open parenthesis the fraction n π over L t close parenthesis plus b sub n sin open parenthesis the fraction n π over L t close parenthesis .")[$x ( t ) = frac(a_(0), 2) + t ( a_(N) cos ( frac(N π, L) t ) + b_(N) sin ( frac(N π, L) t ) ) + ∑_(limits(n = 1)_(n ≠ N))^(∞) a_(n) cos ( frac(n π, L) t ) + b_(n) sin ( frac(n π, L) t ) .$] In other words, we multiply the offending term by #math.equation(block: false, alt: "t")[$t$]. From then on, we proceed as before. Of course, the solution will not be a Fourier series (it will not even be periodic) since it contains these terms multiplied by #math.equation(block: false, alt: "t")[$t$]. Further, the terms #math.equation(block: false, alt: "t open parenthesis a sub N cos open parenthesis the fraction N π over L t close parenthesis plus b sub N sin open parenthesis the fraction N π over L t close parenthesis close parenthesis")[$t ( a_(N) cos ( frac(N π, L) t ) + b_(N) sin ( frac(N π, L) t ) )$] will eventually dominate and lead to wild oscillations. As before, this behavior is called #emph[pure resonance] or just #emph[resonance]. Note that there now may be infinitely many resonance frequencies to hit. That is, as we change the frequency of #math.equation(block: false, alt: "F")[$F$] (we change #math.equation(block: false, alt: "L")[$L$]), different terms from the Fourier series of #math.equation(block: false, alt: "F")[$F$] may interfere with the complementary solution and will cause resonance. However, we should note that since everything is an approximation and in particular #math.equation(block: false, alt: "c")[$c$] is never actually zero but something very close to zero, only the first few resonance frequencies will matter. #examplebox("Example 2")[][ Find the steady periodic solution to the equation #math.equation(block: true, alt: "2 x double prime plus 18 π squared x equals F open parenthesis t close parenthesis ,")[$2 x^(″) + 18 π^(2) x = F ( t ) ,$] where #math.equation(block: true, alt: "minus 1 i f minus 1 less than t less than 0 ,; 1 i f 0 less than t less than 1 ,")[$− 1 upright(i) upright(f) − 1 < t < 0 , \ 1 upright(i) upright(f) 0 < t < 1 ,$] extended periodically. We note that #math.equation(block: true, alt: "F open parenthesis t close parenthesis equals ∑ n equals 1 n o d d infinity the fraction 4 over π n sin open parenthesis n π t close parenthesis .")[$F ( t ) = ∑_(limits(n = 1)_(n " " upright(o) upright(d) upright(d)))^(∞) frac(4, π n) sin ( n π t ) .$] ] #notebox("Your Turn", rgb("#8a94a6"), rgb("#556666"), rgb("#f7f8fa"))[ Compute the Fourier series of #math.equation(block: false, alt: "F")[$F$] to verify the above equation. ] As #math.equation(block: false, alt: "the square root of the fraction k over m equals the square root of the fraction 18 π squared over 2 equals 3 π")[$sqrt(frac(k, m)) = sqrt(frac(18 π^(2), 2)) = 3 π$], the solution to (4.5.2) is #math.equation(block: true, alt: "x open parenthesis t close parenthesis equals c sub 1 cos open parenthesis 3 π t close parenthesis plus c sub 2 sin open parenthesis 3 π t close parenthesis plus x sub p open parenthesis t close parenthesis")[$x ( t ) = c_(1) cos ( 3 π t ) + c_(2) sin ( 3 π t ) + x_(p) ( t )$] for some particular solution #math.equation(block: false, alt: "x sub p")[$x_(p)$]. If we just try an #math.equation(block: false, alt: "x sub p")[$x_(p)$] given as a Fourier series with #math.equation(block: false, alt: "sin open parenthesis n π t close parenthesis")[$sin ( n π t )$] as usual, the complementary equation, #math.equation(block: false, alt: "2 x double prime plus 18 π squared x equals 0")[$2 x^(″) + 18 π^(2) x = 0$], eats our #math.equation(block: false, alt: "3 to the power rd")[$3^("rd")$] harmonic. That is, the term with #math.equation(block: false, alt: "sin open parenthesis 3 π t close parenthesis")[$sin ( 3 π t )$] is already in in our complementary solution. Therefore, we pull that term out and multiply it by #math.equation(block: false, alt: "t")[$t$]. We also add a cosine term to get everything right. That is, we try #math.equation(block: true, alt: "x sub p open parenthesis t close parenthesis equals a sub 3 t cos open parenthesis 3 π t close parenthesis plus b sub 3 t sin open parenthesis 3 π t close parenthesis plus ∑ n equals 1 n o d d n not equal to 3 infinity b sub n sin open parenthesis n π t close parenthesis .")[$x_(p) ( t ) = a_(3) t cos ( 3 π t ) + b_(3) t sin ( 3 π t ) + ∑_(limits(n = 1)_(limits(n " " upright(o) upright(d) upright(d))_(n ≠ 3)))^(∞) b_(n) sin ( n π t ) .$] Let us compute the second derivative. #math.equation(block: true, alt: "x p ′ prime open parenthesis t close parenthesis equals minus 6 a sub 3 π sin open parenthesis 3 π t close parenthesis minus 9 π squared a sub 3 t cos open parenthesis 3 π t close parenthesis plus 6 b sub 3 π cos open parenthesis 3 π t close parenthesis minus 9 π squared b sub 3 t sin open parenthesis 3 π t close parenthesis plus ∑ n equals 1 n o d d n not equal to 3 infinity open parenthesis minus n squared π squared b sub n close parenthesis sin open parenthesis n π t close parenthesis .")[$x_(p)^(′)^(′) ( t ) = − 6 a_(3) π sin ( 3 π t ) − 9 π^(2) a_(3) t cos ( 3 π t ) + 6 b_(3) π cos ( 3 π t ) − 9 π^(2) b_(3) t sin ( 3 π t ) + ∑_(limits(n = 1)_(limits(n " " upright(o) upright(d) upright(d))_(n ≠ 3)))^(∞) ( − n^(2) π^(2) b_(n) ) sin ( n π t ) .$] We now plug into the left hand side of the differential equation. #math.equation(block: true, alt: "2 x p ′ prime plus 18 π squared x sub p equals minus 12 a sub 3 π sin open parenthesis 3 π t close parenthesis minus 18 π squared a sub 3 t cos open parenthesis 3 π t close parenthesis plus 12 b sub 3 π cos open parenthesis 3 π t close parenthesis minus 18 π squared b sub 3 t sin open parenthesis 3 π t close parenthesis; plus 18 π squared a sub 3 t cos open parenthesis 3 π t close parenthesis plus 18 π squared b sub 3 t sin open parenthesis 3 π t close parenthesis; plus ∑ sub n equals 1; n odd; n ⧸ equals 3 } } to the power infinity open parenthesis minus 2 n squared π squared b sub n plus 18 π squared b sub n close parenthesis sin open parenthesis n π t close parenthesis .")[$2 x_(p)^(′)^(′) + 18 π^(2) x_(p) = − 12 a_(3) π sin ( 3 π t ) − 18 π^(2) a_(3) t cos ( 3 π t ) + 12 b_(3) π cos ( 3 π t ) − 18 π^(2) b_(3) t sin ( 3 π t ) \ " " + 18 π^(2) a_(3) t cos ( 3 π t ) " " + 18 π^(2) b_(3) t sin ( 3 π t ) \ + ∑_(n = 1) \ n " " "odd" \ n "⧸" = 3 \} \}^(∞) ( − 2 n^(2) π^(2) b_(n) + 18 π^(2) b_(n) ) sin ( n π t ) .$] If we simplify we obtain #math.equation(block: true, alt: "2 x p ′ prime plus 18 π squared x equals minus 12 a sub 3 π sin open parenthesis 3 π t close parenthesis plus 12 b sub 3 π cos open parenthesis 3 π t close parenthesis plus ∑ n equals 1 n o d d n not equal to 3 infinity open parenthesis minus 2 n squared π squared b sub n plus 18 π squared b sub n close parenthesis sin open parenthesis n π t . close parenthesis")[$2 x_(p)^(′)^(′) + 18 π^(2) x = − 12 a_(3) π sin ( 3 π t ) + 12 b_(3) π cos ( 3 π t ) + ∑_(limits(n = 1)_(limits(n " " upright(o) upright(d) upright(d))_(n ≠ 3)))^(∞) ( − 2 n^(2) π^(2) b_(n) + 18 π^(2) b_(n) ) sin ( n π t . )$] This series has to equal to the series for #math.equation(block: false, alt: "F open parenthesis t close parenthesis")[$F ( t )$]. We equate the coefficients and solve for #math.equation(block: false, alt: "a sub 3")[$a_(3)$] and #math.equation(block: false, alt: "b sub n")[$b_(n)$]. #math.equation(block: true, alt: "a sub 3 equals the fraction 4 / open parenthesis 3 π close parenthesis over minus 12 π equals the fraction minus 1 over 9 π squared ,; b sub 3 equals 0 ,; b sub n equals the fraction 4 over n π open parenthesis 18 π squared minus 2 n squared π squared close parenthesis equals the fraction 2 over π cubed n open parenthesis 9 minus n squared close parenthesis f o r n o d d a n d n not equal to 3 .")[$a_(3) = frac(4 / ( 3 π ), − 12 π) = frac(− 1, 9 π^(2)) , \ b_(3) = 0 , \ b_(n) = frac(4, n π ( 18 π^(2) − 2 n^(2) π^(2) )) = frac(2, π^(3) n ( 9 − n^(2) )) " " " " " " " " " " " " upright(f) upright(o) upright(r) " " n " " upright(o) upright(d) upright(d) " " upright(a) upright(n) upright(d) " " n ≠ 3 .$] That is, #math.equation(block: true, alt: "x sub p open parenthesis t close parenthesis equals the fraction minus 1 over 9 π squared t cos open parenthesis 3 π t close parenthesis plus ∑ n equals 1 n o d d n not equal to 3 infinity the fraction 2 over π cubed n open parenthesis 9 minus n squared close parenthesis sin open parenthesis n π t . close parenthesis")[$x_(p) ( t ) = frac(− 1, 9 π^(2)) t cos ( 3 π t ) + ∑_(limits(n = 1)_(limits(n " " upright(o) upright(d) upright(d))_(n ≠ 3)))^(∞) frac(2, π^(3) n ( 9 − n^(2) )) sin ( n π t . )$] When #math.equation(block: false, alt: "c greater than 0")[$c > 0$], you will not have to worry about pure resonance. That is, there will never be any conflicts and you do not need to multiply any terms by #math.equation(block: false, alt: "t")[$t$]. There is a corresponding concept of practical resonance and it is very similar to the ideas we already explored in #link("https://math.libretexts.org/Bookshelves/Differential_Equations/Differential_Equations_for_Engineers_(Lebl)/2%3A_Higher_order_linear_ODEs")[Chapter 2]. Basically what happens in practical resonance is that one of the coefficients in the series for #math.equation(block: false, alt: "x sub s p")[$x_(s p)$] can get very big. We will not go into details here. - - #link("http://www.jirka.org/diffyqs/")[Jiří Lebl] (#link("http://www.math.okstate.edu/")[Oklahoma State University]).These pages were supported by NSF grants DMS-0900885 and DMS-1362337.