失眠网,内容丰富有趣,生活中的好帮手!
失眠网 > matlab 点符号 matlab 中在运算符号前加一点是什么意思?

matlab 点符号 matlab 中在运算符号前加一点是什么意思?

时间:2019-09-10 22:16:06

相关推荐

matlab 点符号 matlab 中在运算符号前加一点是什么意思?

matlab 中在运算符号前加一点是什么意思?

mip版关注:210答案:2悬赏:20

解决时间 -01-23 18:50

已解决

-01-23 08:24

例如,矩阵A、B,A*B和A.*B有什么区别?

最佳答案

-01-23 09:51

*表示矩阵相乘(矩阵的乘法)

.*表示各个元素分别相乘

a=[0 1;2 3];

>> b=[3 2;0 1];

>> c=a*b

c =

0 1

6 7

%

c=[ 0*3+1*0 0*2+1*1

2*3+3*0 2*2+3*1]

%

>> c=a.*b

c =

0 2

0 3

%

c=[ 0*3 1*2

2*0 3*1]

%

>> help *

* Matrix multiply.

X*Y is the matrix product of X and Y. Any scalar (a 1-by-1 matrix)

may multiply anything. Otherwise, the number of columns of X must

equal the number of rows of Y.

C = mtimes(A,B) is called for the syntax 'A * B' when A or B is an

object.

See also times.

Overloaded methods:

gf/mtimes

codistributed/mtimes

LagOp/mtimes

fints/mtimes

idmodel/mtimes

localpoly/mtimes

icsignal/mtimes

InputOutputModel/mtimes

cvdata/mtimes

timeseries/mtimes

laurpoly/mtimes

laurmat/mtimes

Reference page in Help browser

doc mtimes

>> help .*

.* Array multiply.

X.*Y denotes element-by-element multiplication. X and Y

must have the same dimensions unless one is a scalar.

A scalar can be multiplied into anything.

C = times(A,B) is called for the syntax 'A .* B' when A or B is an

object.

See also mtimes.

Overloaded methods:

gf/times

codistributed/times

fints/times

DynamicSystem/times

cvdata/times

categorical/times

timeseries/times

Reference page in Help browser

doc times

全部回答

1楼

-01-23 10:54

a.*b 代表的是元素乘,即a、b对应位置的元素相乘

a*b 代表的是线性代数里的矩阵乘法

对于初学者,一般不需要矩阵乘法。所以养成在每个运算符前加个点是个好习惯。

我要举报

如果感觉以上信息为低俗/不良/侵权的信息,可以点下面链接进行举报,我们会做出相应处理,感谢你的支持!

点此我要举报以上信息!

推荐资讯

大家都在看

如果觉得《matlab 点符号 matlab 中在运算符号前加一点是什么意思?》对你有帮助,请点赞、收藏,并留下你的观点哦!

本内容不代表本网观点和政治立场,如有侵犯你的权益请联系我们处理。
网友评论
网友评论仅供其表达个人看法,并不表明网站立场。