Rank: 109495 based on 0 downloads (last 30 days) and 0 file submitted
photo

Stefan

E-mail

Personal Profile:

 

Watch this Author's files

 

Comments and Ratings by Stefan View all
Updated File Comments Rating
07 Jun 2010 LPDU decomposition LPDU decompostion. Author: Yi Zhang

The function fails for "higher" dimension. E.g.

>> A=rand(4,4);
>> det(A)

ans =

0.0149

>> [L,P,D,U]=lpdu(A)

Warning: Matrix is close to singular or badly scaled.
Results may be inaccurate. RCOND = 1.421637e-033.
> In LPDU at 83

L =

1.0e+016 *

0.0000 0 0 0
-1.2269 0.0000 0 -0.0000
-1.2245 0.0000 0.0000 0.0000
1.1595 0.0000 -0.0000 0.0000

P =

1 1 0 0
1 0 1 0
1 0 0 1
1 0 0 0

D =

1.0e+014 *

1.9878 0 0 0
0 0.0000 0 0
0 0 -0.0000 0
0 0 0 0.0000

U =

1.0000 3.1587 12.4369 11.8480
0 1.0000 -4.0000 4.0000
0 0 1.0000 0.2882
0 0 0 1.0000

>> norm(L*P*D*U-A)

ans =

7.2518e+031

24 Feb 2010 LU decomposition This program obtains the LU decomposition of a matrix using Crout’s Method Author: Timothee

Some comments:

- insufficient H1 line

These lines:

check=int8 (L*U)

if check==A
disp(sprintf (' the equation L*U=A is correct '))
else
disp(sprintf ('error'))
end

will almost always state an error, because of the casting. Why did you do it that way?

With this sample data:

A=[0 2;3 4];
B=[5;6];

your function gives:

x_soln =

NaN
NaN

There is just no pivoting. You didn't limit the usage to strictly regular matrices A. No error check supplied.

Regards,
Stefan

07 Apr 2009 Workflow Design Thoughts: How to create lecture notes, homework examples or book figures easily. A style guide on how to create published figures for books and lecture notes. M-Files included Author: Tom Gaudette

I cannot open the document. A pdf file would be more appropriate.

19 Nov 2008 Nonlinear Control of 3 DOF PUMA Robot Nonlinear Control of 3 DOF PUMA Robot Author: Abdel-Razzak

Still the same error. You should do proper testing before publishing your work.

14 Nov 2008 Nonlinear Control of 3 DOF PUMA Robot Nonlinear Control of 3 DOF PUMA Robot Author: Abdel-Razzak

A library is missing, so the model isn't running:

Failed to find library 'aerolibutil' referenced by 'sliding_mode_control/3-Link PUMA Robot-Block 2/I matrix/B matrix/b112/SinCos(2*teta2+teta3)'. This library must be on your MATLAB path.

Contact us