How can i plot this pic by matlab ??
9 Ansichten (letzte 30 Tage)
Ältere Kommentare anzeigen

0 Kommentare
Antworten (1)
DGM
am 6 Apr. 2025
It looks like an upside-down representation of HSV with some random unknown extra line. I'm going to ignore it, since it looks like a mistake.
% vertex colors
CT0 = [0 0 0; % k
1 1 1; % w
hsv(6)]; % rygcbm
% vertex locations
a = 0.5;
b = sqrt(3)/2;
V = [0 0 1; % k
0 0 0; % w
1 0 0; % r
a b 0; % y
-a b 0; % g
-1 0 0; % c
-a -b 0; % b
a -b 0]; % m
% face list
ps = (3:8).';
F = [2*ones(6,1) circshift(ps,-1) ps;
ones(6,1) ps circshift(ps,-1)];
% plot it all
patch('faces',F,'vertices',V, ...
'facevertexcdata',CT0,'facecolor','interp');
view(-62,-22)
axis equal; grid on
xlabel('X'); ylabel('Y'); zlabel('Z')
ylim([-1 1])
0 Kommentare
Siehe auch
Kategorien
Mehr zu Surface and Mesh Plots finden Sie in Help Center und File Exchange
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!
