%
% Example 6 from Sec 2.8/Example 3 from Sec 4.2
%
A = [-3 6 -1 1 -7; 1 -2 2 3 -1; 2 -4 5 8 -4]
b = [0 0 0]'
rref([A b])
% We can identify a basis for null A.
v1 = [2 1 0 0 0]'
v2 = [1 0 -2 1 0]'
v3 = [-3 0 2 0 1]'
% Use Matlab/Octave command null()
B = null(A)
rref([B v1 v2 v3])
rref([v1 v2 v3 B])
