求助高手!!Inner matrix dimensions must agree.
clcp=300
m=2000
h=2
t=1
NP=28
NodeCor=[1 0 2
2 0 1
3 0 0
4 1 2
5 1 0
6 2 2
7 2 1
8 2 0
9 3 2
10 3 0
11 4 2
12 4 1
13 4 0
14 5 2
15 5 0
16 5 2
17 6 1
18 6 0
19 7 2
20 7 0
21 8 2
22 8 1
23 8 0
24 9 2
25 9 0
26 10 2
27 10 1
28 10 0]
NE=5
[1 1 2 3 5 8 7 6 4;2 6 7 8 10 13 12 11 9;3 11 12 13 15 18 17 16 14;4 16 17 18 20 23 22 21 19;5 21 22 23 25 28 27 26 24]
M=zeros(46,1)
P=zeros(46,1)
M(41,1)=m/h
M(45,1)=-m/h
P(42,1)=-p/4
P(44,1)=-p/2
P(46,1)=-p/4
for e=1:5
i=[e,2]
j=[e,3]
n=[e,4]
r=[e,5]
s=[e,6]
o=[e,7]
p=[e,8]
q=[e,9]
x1=NodeCor(i,2)
y1=NodeCor(i,3)
x2=NodeCor(j,2)
y2=NodeCor(j,3)
x3=NodeCor(n,2)
y3=NodeCor(n,3)
x4=NodeCor(r,2)
y4=NodeCor(r,3)
x5=NodeCor(s,2)
y5=NodeCor(s,3)
x6=NodeCor(o,2)
y6=NodeCor(o,3)
x7=NodeCor(p,2)
y7=NodeCor(p,3)
x8=NodeCor(q,2)
y8=NodeCor(q,3)
D1=[1 x1 y1 x1*x1 x1*y1 y1*y1 x1*x1*y1 x1*y1*y1
1 x2 y2 x2*x2 x2*y2 y2*y2 x2*x2*y2 x2*y2*y2
1 x3 y3 x3*x3 x3*y3 y3*y3 x3*x3*y3 x3*y3*y3
1 x4 y4 x4*x4 x4*y4 y4*y4 x4*x4*y4 x4*y4*y4
1 x5 y5 x5*x5 x5*y5 y5*y5 x5*x5*y5 x5*y5*y5
1 x6 y6 x6*x6 x6*y6 y6*y6 x6*x6*y6 x6*y6*y6
1 x7 y7 x7*x7 x7*y7 y7*y7 x7*x7*y7 x7*y7*y7
1 x8 y8 x8*x8 x8*y8 y8*y8 x8*x8*y8 x8*y8*y8]
end
??? Error using ==> mtimes
Inner matrix dimensions must agree.
Error in ==> sibisnxing at 70
D1=[1 x1 y1 x1*x1 x1*y1 y1*y1 x1*x1*y1 x1*y1*y1