Borrar filtros
Borrar filtros

how can i delete a quiver3 object

8 visualizaciones (últimos 30 días)
Andrea Gusmara
Andrea Gusmara el 3 de Jun. de 2020
Comentada: Andrea Gusmara el 4 de Jun. de 2020
hi
to everyone I would like to ask you how do I remove these three quiver3 objects from my patch
surf=gca;
xlim(surf,[-30 +30]);
xlabel('x');
zlim(surf,[-30 +30]);
zlabel('z');
ylim(surf,[-30 +30]);
ylabel('y');
%regola in una modalità fissa la lunghezza dela singola unita degli assi
daspect([1 1 1]);
S.Vertices=[];
S.Faces=[];
p=patch(S);
frame0=eye(4);
hold('on');
frame0V=ReferenceSystem(frame0);
function [q1,q2,q3]=ReferenceSystem(frame)
q1 =quiver3(frame(1,4),frame(2,4),frame(3,4),frame(1,1),frame(2,1),frame(3,1), 'Color', 'r');
q1.LineWidth=3;
q1.AutoScaleFactor=8;
q2 = quiver3(frame(1,4),frame(2,4),frame(3,4),frame(1,2),frame(2,2), frame(3,2), 'Color', 'g');
q2.LineWidth=3;
q2.AutoScaleFactor=8;
q3 = quiver3(frame(1,4),frame(2,4),frame(3,4),frame(1,3),frame(2,3), frame(3,3), 'Color', 'b');
q3.LineWidth=3;
q3.AutoScaleFactor=10;
  2 comentarios
Walter Roberson
Walter Roberson el 3 de Jun. de 2020
delete([q1, q2, q3])
?
Andrea Gusmara
Andrea Gusmara el 4 de Jun. de 2020
unluckily Doesn't work.
Unrecognized function or variable 'q1'.

Iniciar sesión para comentar.

Respuesta aceptada

Ameer Hamza
Ameer Hamza el 4 de Jun. de 2020
Call the function with 3 output arguments to get the handle of the quiver objects.
[frame0Vq1,frame0Vq2,frame0Vq3]=ReferenceSystem(frame0);
and then delete it like this
delete([frame0Vq1,frame0Vq2,frame0Vq3])
  1 comentario
Andrea Gusmara
Andrea Gusmara el 4 de Jun. de 2020
thank you so much , now works correctly.

Iniciar sesión para comentar.

Más respuestas (0)

Etiquetas

Community Treasure Hunt

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

Start Hunting!

Translated by