-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathvb_plot.m
More file actions
29 lines (23 loc) · 799 Bytes
/
vb_plot.m
File metadata and controls
29 lines (23 loc) · 799 Bytes
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
%% Plot disks with different orientation
function vb_plot(sd,sdOrn,gmp)
figure
for fac=1:gmp.nFa
for qdc=1:4
dCrd=[sd(fac,1)+gmp.dskRd*cos(sdOrn(fac)+pi/2*(qdc-1):...
pi/24:sdOrn(fac)+pi/2*qdc);
sd(fac,2)+gmp.dskRd*sin(sdOrn(fac)+pi/2*(qdc-1):...
pi/24:sdOrn(fac)+pi/2*qdc)];
if mod(qdc,2)==1
plot(dCrd(1,:),dCrd(2,:),'r','LineWidth',2);
hold on;
else
plot(dCrd(1,:),dCrd(2,:),'b','LineWidth',2);
hold on;
end
end
end
plRng=[min(sd(:,1))-1.5*gmp.dskRd,max(sd(:,1))+1.5*gmp.dskRd;...
min(sd(:,2))-1.5*gmp.dskRd,max(sd(:,2))+1.5*gmp.dskRd];
axis([plRng(1,1) plRng(1,2) plRng(2,1) plRng(2,2)]);
pbaspect([plRng(1,2)-plRng(1,1) plRng(2,2)-plRng(2,1) 1]);
end