Por que ocorre esse erro: Error using vertcat Dimensions of matrices being concatenated are not consistent. Preciso gerar uma imagem de um animal.
32 views (last 30 days)
Show older comments
% Panda
axis([-30 30 -30 30]) % determina o intervalo dos eixos hold on % congela as imagens
% pata traseira A=[5.41 5.82 6.22 6.67 6.73 6.39 4.63 3.57 2.55 2.16 2.21 2.47 3.12 3.7 4.3 5.05 5.87 5.98 5.75 5.41;1.84 1.94 1.96 1.43 0.89 0.64 0.72 0.93 1.18 1.82 2.77 3.83 4.86 5.19 5.17 4.69 3.52 2.77 2.23 1.84]; fill(A(1,:),A(2,:),'k')
% pata dianteira da frente B=[7.16 6.86 6.61 6.38 6.1 5.83 5.54 5.33 5.41 5.72 6.37 7.36 7.81 8.11 7.96 7.89 7.96 8.14 8.36 8.32 8.41 8.43 8.58 8.8 9.33 9.62 9.85 9.88 9.67 9.17 8.41 7.85 7.44 7.16;2.24 2.6 3.08 3.75 4.6 5.16 5.75 6.57 7.15 7.72 8.26 8.57 8.29 7.82 7.48 7.07 6.75 6.36 6.1 4.99 4.25 3.62 2.79 2.11 2.16 1.91 1.52 1.31 1.02 0.86 0.94 1.14 1.71 2.24]; fill(B(1,:),B(2,:),'k')
% corpo C=[7.16 6.86 6.61 6.38 6.1 5.83 5.54 5.33 5.41 5.72 6.37 5.4 4.11 3.52 3.02 2.68 2.22 1.93 1.74 1.69 1.77 2.16 2.21 2.47 3.12 3.7 4.3 5.05 5.87 5.98 5.75 5.41 5.82 6.22 6.39 7.16;2.24 2.6 3.08 3.75 4.6 5.16 5.75 6.57 7.15 7.72 8.26 7.99 7.48 7.18 6.79 6.38 5.73 5.01 4.13 3.44 2.73 1.82 2.77 3.83 4.86 5.19 5.17 4.69 3.52 2.77 2.23 1.84 1.94 1.96 1.82 2.24]; fill(C(1,:),C(2,:),'w')
% nuca E=[7.36 7.6 7.91 8.35 8.27 8.21 8.2 8.37 8.24 8.11 7.81 7.36;8.57 8.7 8.85 9.01 8.85 8.69 8.44 8.26 8.03 8.57]; fill(E(1,:),E(2,:),'w')
0 Comments
Answers (1)
Orion
on 6 Nov 2014
you seriously should consider to write in english.
also use the {}code button to format your code.
your error is in the use of vertcat when defining E.
you misplaced the ";" character.
you wrote
E=[7.36 7.6 7.91 8.35 8.27 8.21 8.2 8.37 8.24 8.11 7.81 7.36; ...
8.57 8.7 8.85 9.01 8.85 8.69 8.44 8.26 8.03 8.57];
probably instead of
E=[7.36 7.6 7.91 8.35 8.27 8.21 8.2 8.37 8.24 8.11 7.81 7.36; ...
8.57 8.7 8.85 9.01 8.85 8.69 8.44 8.26 8.03 8.57];
so you asked to concatenate two vectors with different sizes, and matlab told you it's not possible.
0 Comments
See Also
Categories
Find more on Creating and Concatenating Matrices 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!