$$
\newcommand{\uex}{{u_{\small\mbox{e}}}}
\newcommand{\Aex}{{A_{\small\mbox{e}}}}
\newcommand{\half}{\frac{1}{2}}
\newcommand{\Oof}[1]{\mathcal{O}(#1)}
$$
Verification via manufactured solutions
- Choose any formula for \( u(t) \).
- Fit \( I \), \( a(t) \), and \( b(t) \) in \( u'=-au+b \), \( u(0)=I \),
to make the chosen formula a solution of the ODE problem.
- Then we can always have an analytical solution (!).
- Ideal for verification: testing convergence rates.
- Called the method of manufactured solutions (MMS)
- Special case: \( u \) linear in \( t \), because all sound numerical
methods will reproduce a linear \( u \) exactly (machine precision).
- \( u(t) = ct + d \). \( u(0)=0 \) means \( d=I \).
- ODE implies \( c = -a(t)u + b(t) \).
- Choose \( a(t) \) and \( c \), and set \( b(t) = c + a(t)(ct + I) \).
- Any error in the formula for \( u^{n+1} \) makes \( u\neq ct+I \)!