[实验内容]1、 启动Matlab,并使用命令退出Matlab2、 将命令窗口当作计算器,实现基本数学运算3、 通过Matlab的帮助系统,列出函数abs()的主要用法 (取绝对值)4、 通过Matlab的帮助系统,查询2-D Plots演示程序,并学习其中所列函数的主要用法5、 用满矩阵和稀疏矩阵存储方式分别构造下述矩阵 6、 在矩阵A末尾增加一行(元素为1)得到矩阵B,删除矩阵A的最后一列得到矩阵C,替换矩阵A的所有非零元素为2得到矩阵D7、 给定矩阵E=rand(4,4),计算C+E,C*E,C/E会的大大们能写多少就多少 谢谢了 好的追加
6 7两题好了 其他ok啦
1.启动双击图标,退出命令 exit 回车2.2+3 回车,ans =5 2*3 回车,ans =6等等3.help abs解释如下ABS Absolute value. ABS(X) is the absolute value of the elements of X. When X is complex, ABS(X) is the complex modulus (magnitude) of the elements of X.下面的doc abs中有详细的介绍abs Absolute value and complex magnitude SyntaxY = abs(X)Descriptionabs(X) returns an array Y such that each element of Y is the absolute value of the corresponding element of X. If X is complex, abs(X) returns the complex modulus (magnitude), which is the same as sqrt(real(X).^2 + imag(X).^2)Examples abs(-5)ans = 5abs(3+4i)ans = 54.demos 回车Graphics 中有2-D plot5.题目???6.举例 不知道A7.E=rand(4,4) 不知道上题的CC+EC*E 这边可能是点乘 C.*EC/E 这边可能是点除 C./E注意矩阵的维数就可以了 |
|