This Matlab code illustrates the Eigenvalue Method for studying stability of steady states for DISCRETE-TIME dynamical system described in the docking problem.
Declare the variables
clear all, close all, clc syms x1 x2
c = 5; % time to make a control adjustment w = 10; % delay time before the next observation k = 0.1; % ratio between acceleration and velocity (control law)
The discrete-time dynamical system is given by delta_x1=f1; delta_x2=f2 where
f1 = -k*w*x1-k*c*x2; f2 = x1-x2;
or, equivalently, x1=g1(=x1+f1), x2=g2(=x2+f2):
g1 = x1+f1; g2 = x2+f2;
First, compute the Jacobian matrix
A = [diff(g1,x1), diff(g1,x2); diff(g2,x1), diff(g2,x2)];
Eigenvalues are
lambda = eig(A)'
lambda = [ -1/2*i*2^(1/2), 1/2*i*2^(1/2)]
and have modulus
double(abs(lambda(1))), double(abs(lambda(2)))
ans = 0.7071 ans = 0.7071
Conclusion: Based on the eigenvalues obtained above, one concludes that the origin (0,0) is a stable (sink) equilibrium. You can also visualize this by plotting a few trajectories of the dynamical system, e.g. using pplane7.m