4.3. Stability Functions for Implicit Runge-Kutta Methods#
In the previous section, we derived the stability function for a general Runge-Kutta method solution to the text equation \(y' = \lambda y\) which is
where \(z = h\lambda\) and \(\mathbf{e} = (1, \ldots, 1)^\mathsf{T}\).
For implicit methods, \(A\) is not lower triangular so we cannot use a power series summation to determine the stability function. Instead, we can use a result from linear algebra to to express the stability function as a quotient of determinants. The matrix determinant lemma is
where \(M\) is an invertible square matrix and \(\mathbf{u}, \mathbf{v}\) are column vectors. Let \(M = I - zA\), \(\mathbf{u} = z \mathbf{e}\) and \(\mathbf{v} = \mathbf{b}\) then
therefore
This is the stability function for an implicit Runge-Kutta method.
Definition 4.5 (Stability function of an implicit Runge-Kutta method)
The stability function of an implicit Runge-Kutta method is
Note that \(\mathbf{eb}^\mathsf{T}\) is the outer product of the column vector \(\mathbf{e} = (1, \ldots, 1)^\mathsf{T}\) and the row vector \(\mathbf{b}^\mathsf{T} = (b_1, b_2, \ldots, b_s)\)
Since each entry of \(I - zA\) is a polynomial in \(z\), both the numerator and denominator are polynomials. Therefore the stability function of an implicit Runge-Kutta method is a rational function
Example 4.2
The Radau IA IRK method is defined by the following Butcher tableau
Determine the stability function of this method
Solution
Using equation (4.8)
4.3.1. Code#
The Python and MATLAB code used to determine the stability function for the IRK method from Example 4.2 is given below.
import sympy as sp
# Define IRK method
A = sp.Matrix([[sp.Rational(1,4), -sp.Rational(1,4)],
[sp.Rational(1,4), sp.Rational(5,12)]])
b = sp.Matrix([[sp.Rational(1,4)],
[sp.Rational(3, 4)]])
s = len(b)
e = sp.ones(s, 1)
# Define P(z) and Q(z) functions
def P(z):
return (sp.eye(s) - z * A + z * e * b.T).det()
def Q(z):
return (sp.eye(s) - z * A).det()
# Determine R(z)
z = sp.symbols('z')
sp.pprint(P(z) / Q(z))
% Define IRK method
A = [1/4, -1/4 ; 1/4, 5/12];
b = [1/4 ; 3/4];
s = length(b);
e = ones(s, 1);
% Define P(z) and Q(z) functions
P = @(z) det(eye(s) - z * A + z * e * b');
Q = @(z) det(eye(s) - z * A);
% Determine R(z)
syms z
Rz = P(z) / Q(z)