A method for numerically solving second‐order non‐homogeneous linear differential equations with variable coefficients