I have this problem whit plot3

This is my code
%Robot RRP Planar
clear all;
close all;
clc
%Definir Variables Simbolicas
syms q1 q2 L1 L2 d3 deg
%------------------------------------------
%para hacerlo sin Offset Quitar los 90gradis de q1
A01 = matrizDH(q1,L1,0,90,deg) %Relaciona al Sistema 1 con respecto al sistema 0
A12 = matrizDH(q2,0,0,-90,deg) %Relaciona al Sistema 2 con respecto al sistema 1
A23 = matrizDH(0,L2+d3,0,0,deg) %Relaciona al Sistema 3 con respecto al sistema 2
%Matriz DH Final
A02 = A01*A12;
A03= A02*A23;
%------------------------------------------
%Evaluacion Numerica
f = 50;
q1v=deg2rad(linspace(0,20,f));
q1v=deg2rad(linspace(0,45,f));
L1 =2;
L2 =1;
d3 = 0.7;
A00 = eye(4,4);
A01e= eval(A01);
A02e= eval(A02);
A03e= eval(A03);
%------------------------------------------
%Posicion de Los Eslabones
X = [0,A01e(1,4),A02e(1,4),A03e(1,4)];
Y = [0,A01e(2,4),A02e(2,4),A03e(2,4)];
Z = [0,A01e(3,4),A02e(3,4),A03e(3,4)];
hold on
%------------------------------------------
%Grafica
plot3(X,Y,Z,'-k','linewidth',2)
hold on
plot3(X,Y,Z,'or','linewidth',2)
xlabel('X');xlabel('Y');xlabel('Z')
axis([-2 5 -2 5 -0 5])
view(3);grid on
trplot(A00,'frame','0','color','r')
trplot(A01e,'frame','1','color','b')
trplot(A02e,'frame','2','color','g')
trplot(A03e,'frame','3','color','c')
title('RRP')
Show de next Error
Error using plot3
Data must be numeric, datetime, duration or an array convertible to double.
Error in RobotRRP (line 37)
plot3(X,Y,Z,'-k','linewidth',2)

回答(0 个)

类别

帮助中心File Exchange 中查找有关 Startup and Shutdown 的更多信息

产品

版本

R2021a

标签

提问:

EO
2022-3-21

评论:

2022-3-22

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!

Translated by