You are on page 1of 5

# Matlab

1714071

171407105
171407129

2008 12 27

1 matlab

2 matlab
3

abs
sum
jacdd
normx,inf

1 jacdd;
2, jacdd
3;
4 X matlab
jX
5 max|X-jX|<wucha
6 djwcX,wucha,a,X,jX

MATLAB

mn=size(A)

K=1,2,3,n
a(i)<0?

1k

i=1,2,3n

k=n?

k+1k

i1,2,,n

A=[1020;0101;1243;0103];
b=[53177]';
X0=[0000]';
X=jacdd(A,b,X0,inf,0.01,5)

functionX=jacdd(A,b,X0,p,wucha,max1)%
[nm]=size(A);% A
forj=1:m
a(j)=sum(abs(A(:,j)))2*(abs(A(j,j)));%
end
ifa(i)>=0;
disp('A ');
end
ifa(i)<0;
disp('A ');
end
fork=1:max1
k
fori=1:m
X(i)=(b(i)A(i,[1:i1,i+1:m])*X0([1:i1,i+1:m]))/A(i,i);%
end
X,X0=X';X1=A\b;jX=X1',
djwcX=norm(X1X0,p)% max|X-jX|<wucha
end
if(djwcX<wucha);
disp(' jX X');
end
if(djwcX>wucha);
disp(' max1');
end
djwcX
wucha%
a,X=X,jX=X1'

a=0
a=02
a=022
a=0221
A
k=1
X=5.00003.00004.25002.3333
djwcX=4
k=2
X=3.50000.66670.25001.3333
djwcX=4.5000
k=3
X=5.50001.66673.79172.1111
djwcX=4
X=2.58330.88890.45831.7778
djwcX=3.5833
k=5
X=4.08331.22223.11812.0370
djwcX=3.0833
max1
djwcX=3.0833
wucha=0.0100
a=0221
X=4.08331.22223.11812.0370
jX=1122

1 for if
2 for if end

3 MATLAB a(j)=sum(abs(A(:,j))-2*(abs(A(j,j)))

2
3

MATLAB

matlab matlab

matlab
matlab

C
;matlab

matlab matlab

AX=b B;
B mH=p(B)

FunctionH=ddpbj(B)
H=eig(B);% B
mH=norm(H,inf);%
IfMh>=1
disp( 1)
else
disp( 1)
end
H,mH

20081227

MATLAB

matlab Mathworks

C
matlab
matlab

1
matlab
2 help demo

6
matlab

matlab

2008-12-27

MATLAB

MATLAB -(MATLAB6.0X.7.X )