Plotting Lyapunov Functions Using MATLAB PDF
Plotting Lyapunov Functions Using MATLAB PDF
F.L. Lewis
updated Tuesday, February 04, 2003
Example 2
Slotine and Li p. 63
V ( x) = (1 - cosq ) + q& 2 / 2
>> x=[-4:.04:4];
>> y=x;
>> [X,Y]=meshgrid(x,y);
>> z=(1-cos(X))+(Y.^2)/2;
>> meshc(X,Y,z)
Example 3
Slotine and Li p. 67
V ( x) = 2(1 - cosq ) + q& 2 / 2 + q& 2 + q 2 / 2
>> x=[-4:.04:4];
>> y=x;
>> [X,Y]=meshgrid(x,y);
>> z=2*(1-cos(X))+(X.^2 + Y.^2)/2 + (Y.^2)/2;
>> meshc(X,Y,z)