A thin rod occupies with its ends held at temperature deviation

PHYSICS · Multi-part · Fermi University Physics · Mathematical Methods for Physics · Numerical and computational mathematics · Numerical and computational mathematics

Error, Chance and the Machine, Ch Approximating a function: interpolation and differentiation

Problem

A thin rod occupies x∈[0,1]x \in [0,1] with its ends held at temperature deviation θ=0\theta = 0. The steady-state deviation satisfies θ′′(x)=s(x)\theta''(x) = s(x) with s(x)=−π2sin⁡(πx) K m−2s(x) = -\pi^2\sin(\pi x)\,\mathrm{K\,m^{-2}}, and θ(0)=θ(1)=0\theta(0)=\theta(1)=0. Take four equal intervals of width h=0.25 mh = 0.25\,\mathrm{m}, giving interior nodes x1=0.25x_1=0.25, x2=0.5x_2=0.5, x3=0.75 mx_3=0.75\,\mathrm{m}. ((a)) Using the standard three-point central second-difference stencil for θ′′(xi)\theta''(x_i), write the linear system for θ1,θ2,θ3\theta_1,\theta_2,\theta_3 in terms of hh and s(xi)s(x_i). ((b)) Solve the resulting tridiagonal system by elimination (the Thomas algorithm) for θ1,θ2,θ3\theta_1,\theta_2,\theta_3. ((c)) Compare with the exact solution θ(x)=sin⁡(πx) K\theta(x) = \sin(\pi x)\,\mathrm{K} and comment on the size of the discrepancy given that the stencil's truncation error is O(h2)O(h^2).

Browse the problem library