matlab程序问题

[复制链接]
查看11 | 回复2 | 2010-8-18 19:58:05 | 显示全部楼层 |阅读模式
x =
Columns 1 through 11

1.0000
1.0050
1.0198
1.0440
1.0770
1.1180
1.1662
1.2207
1.2806
1.3454
1.4142
Columns 12 through 22

1.4866
1.5620
1.6401
1.7205
1.8028
1.8868
1.9723
2.0591
2.1471
2.2361
2.3259
Columns 23 through 33

2.4166
2.5080
2.6000
2.6926
2.7857
2.8792
2.9732
3.0676
3.1623
3.2573
3.3526
Columns 34 through 44

3.4482
3.5440
3.6401
3.7363
3.8328
3.9294
4.0262
4.1231
4.2202
4.3174
4.4147
Columns 45 through 55

4.5122
4.6098
4.7074
4.8052
4.9031
5.0010
5.0990
5.1971
5.2953
5.3935
5.4918
Columns 56 through 63

5.5902
5.6886
5.7871
5.8856
5.9841
6.0828
6.1814
6.2801
??? Error using ==> mrdivide
Matrix dimensions must agree.
Error in ==> c7 at 6
z=1/x
x的值为红体字,为什么错了,在线等,速度~~~~~谢

回复

使用道具 举报

千问 | 2010-8-18 19:58:05 | 显示全部楼层
/ 是矩阵除法,违反规则了;./ 才是数组除法,你试试1./x,就没问题了
回复

使用道具 举报

您需要登录后才可以回帖 登录 | 立即注册

本版积分规则

主题

0

回帖

4882万

积分

论坛元老

Rank: 8Rank: 8

积分
48824836
热门排行