필터 지우기
필터 지우기

how can we decreases the length of the quiver? so that the tail get smaller but head shouldn't move.

조회 수: 1 (최근 30일)
X1 = [0.00246236309072327 0.00222132983511081 0.00176285733832268 0.00113182408271022 0.000390000000000000 -0.000389999999999999 -0.00113182408271022 -0.00176285733832268 -0.00222132983511081 -0.00246236309072327 -0.00246236309072327 -0.00222132983511081 -0.00176285733832268 -0.00113182408271022 -0.000390000000000000 0.000389999999999999 0.00113182408271022 0.00176285733832268 0.00222132983511081 0.00246236309072327];
Y1 = [0.000390000000000000 0.00113182408271022 0.00176285733832268 0.00222132983511081 0.00246236309072327 0.00246236309072327 0.00222132983511081 0.00176285733832268 0.00113182408271022 0.000390000000000000 -0.000389999999999999 -0.00113182408271022 -0.00176285733832268 -0.00222132983511081 -0.00246236309072327 -0.00246236309072327 -0.00222132983511081 -0.00176285733832268 -0.00113182408271022 -0.000390000000000000];
quiver(X1(1,1),Y1(1,1))
axis equal
for j = 2:20
hold on
quiver(X1(1,j),Y1(1,j))
hold off
end

답변 (1개)

Askic V
Askic V 2023년 1월 27일
I would do with a different approcah to have more fexibility and control over how vectors would look like.
Here is a sample code:
clear
clc
close all
xc = 1; % x center coordinate
yc = 1; % y center coordinate
r = 0.2; % radius
angles = linspace(0, 360, 10);
x = r*cosd(angles)+xc;
y = r*sind(angles)+yc;
figure
hold on;
for i = 1: numel(x)
quiver(xc,yc, x(i)-xc,y(i)-yc,'off');
end

카테고리

Help CenterFile Exchange에서 Vector Fields에 대해 자세히 알아보기

태그

Community Treasure Hunt

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

Start Hunting!

Translated by