how can solve vpa function problem?
Show older comments
ne=input('Number of elements ');
Ke=zeros(6,6,ne);
Kg=zeros(150,150,1);
for i=1:1:ne
L1=input('please enter starting length ');
L2=input('ending length ');
A1=input('A1 ')
A2=input('A2 ')
n=input('Beam Type- 1 for Circular 2 for Square ')
n1=input('Please enter starting node ');
n2=input('Please enter ending node ');
nen=[(3*(n1))-2 (3*(n1))-1 (3*(n1)) (3*(n2))-2 (3*(n2))-1 (3*(n2))];
theta=input('angle ')
[K]=kfunc(A1,A2,n,theta,L1,L2);
Ke(:,:,i)=K(:,:,1);
for j=1:1:6
for k=1:1:6
Kg(nen(j,k),nen(j,k),1)=Ke(j,k,i);
end
end
end
display(Kg)
i get the error
The following error occurred converting from sym to double: Error using mupadmex Error in MuPAD command: DOUBLE cannot convert the input expression into a double array.
If the input expression contains a symbolic variable, use the VPA function instead.
Error in Main (line 15) Ke(:,:,i)=K(:,:,1);
Accepted Answer
More Answers (0)
Categories
Find more on Common Operations in Help Center and File Exchange
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!