产生两个0-1之间均匀分布的、4´4阶的随机数矩阵A和B,然后对两个矩阵进行求和、相乘、元素群相乘和相除(A为被除矩阵)以及A矩阵的3次方运算。下列完成以上运算的哪个程序正确?
A: A=rand(4,4); B=rand(4,4); A+B A*B A.*B A./B A.^3
B: A=rand(4,4); B=rand(4,4); A.+B A*B A.*B A./B A^3
C: A=rand(4,4); B=rand(4,4); A+B A*B A.*B A./B A^3
D: A=rand(4,4); B=rand(4,4); A+B A*B A.*B B./ A A^3
A: A=rand(4,4); B=rand(4,4); A+B A*B A.*B A./B A.^3
B: A=rand(4,4); B=rand(4,4); A.+B A*B A.*B A./B A^3
C: A=rand(4,4); B=rand(4,4); A+B A*B A.*B A./B A^3
D: A=rand(4,4); B=rand(4,4); A+B A*B A.*B B./ A A^3
举一反三
- 产生两个0-1之间均匀分布的、4´4阶的随机数矩阵A和B,然后对两个矩阵进行求和、相乘、元素群相乘和相除(A为被除矩阵)以及A矩阵的3次方运算。下列完成以上运算的哪个程序正确?
- 线性方程组的系数矩阵为[1 3;2 4],右端常向量为2阶随机矩阵,则下列命令中可以求得线性方程组解的命令为________ A: A = [1 3;2 4]; b = rand(2,1); x = inv(A)*b; B: A = reshape(1:4,2,2); b = rand(2,1); x = inv(A)*b; C: A = [1 3;2 4]; b = rand(2,1); x = A?; D: A = [1 3;2 4]; b = rand(2,1); x = b/A;
- |x|>4的解集用区间表示是() A: (-4,4) B: [-4,4] C: (-∞,-4)U(4,+∞) D: (-∞,-4]U[4,+∞)
- 数列-4,4,-4,4,-4…….
- Which one is written to generate a 4 × 4 identity matrix. ( ) A: ones(4) B: eye(4) C: zeros(4) D: rand(4)