正在加载图片...
Key to MATLAB Exercise 1 School of Mathematical Sciences Xiamen Univer httplgdipke.xmuedu 9)-14)omited 6.>>x=AB -0.5000 -0.5000 A/B ?? Error using=> mrdivide matrix dimensions must agree A/B is equivalent to the expression AB, but here B is a vector, there is no invert of B 8.1)>>X=0nes(6,1);A*x 0 0 0 0 0 From A*x, we get the sum of every row of A, so we know that the determinant of a equal to 0. that is a must be singular 9.>>A= magIc(8),sum(A(:,1:7) ans=260260260260260260260 10.>>a=[121;A=aa*2a*3];C=-1-1-l},D=-2-24 1)>>A°C >>A*D The results show that though A#0, AC=AD, but C is not equal to D. Therefore the proposition Is not true 2)>>A-round(10"rand( 3)); B-round(10*rand(3)) >>inv(A+B > inv(A)+inv(B) The proposition is not true 3)>(A+By2 >>A^2+2*A*B+B^2 The proposition is not true 4)>>A-round(10*rand(3)); B=A+A >>B=B We may try it more times. All results show the proposition is true Key to Ex1-2Key to MATLAB Exercise 1  School of Mathematical Sciences Xiamen University  http://gdjpkc.xmu.edu. Key to Ex1­2  9)­14) omited  6.  >> x=A\B ans x=  ­0.5000  1.0000  ­0.5000  7.  >> A/B ??? Error using ==> mrdivide matrix dimensions must agree.  A/B is equivalent to the expression  1 AB - , but here B is a vector, there is no invert of B.  8.  1) >> x=ones(6,1); A*x  ans = 0  0  0  0  0  0  From A*x, we get the sum of every row of A, so we know that the determinant of A equal to  0, that is A must be singular.  2) omited  9.  >> A = magic (8); sum(A(:,1:7)) ans =260  260  260  260  260  260  260  10.  >> a=[1 2 1]; A=[a;a*2;a*3]; C=[­1 ­1­1]'; D=[­2 ­2 4]';  1) >> A*C >> A*D  The results  show that  though  A≠0,  AC=AD,  but  C is not  equal  to D.  Therefore the proposition is not true.  2) >> A=round(10*rand(3)); B=round(10*rand(3));  >> inv(A+B)  >> inv(A)+inv(B) The proposition is not true.  3) >> (A+B)^2  >> A^2+2*A*B+B^2  The proposition is not true.  4) >> A=round(10*rand(3)); B=A+A’;  >> B == B’ ans =  1  1  1  1  1  1  1  1  1  We may try it more times. All results show the proposition is true.  11.  omited
<<向上翻页
©2008-现在 cucdc.com 高等教育资讯网 版权所有