The physics
A drag force −bv takes energy away from a swing. With light damping, the amplitude falls along a curve, not a straight line.
A = A₀ e^(−bt/2m) E = E₀ e^(−bt/m)
The energy goes as A². So it falls twice as fast as the amplitude.
A swing has its own period, T₀ = 2π√(L/g). A push that repeats at that period adds energy on every swing. This is resonance.
Push a block at rest with F₀ sin ωt. It moves as a steady swing at ω plus a free swing at ω₀.
x = (F₀/m) / (ω₀² − ω²) × (sin ωt − (ω/ω₀) sin ω₀t)