last.m
来自「一个matlab的将军模型」· M 代码 · 共 22 行
M
22 行
hold on;
test3=[];
for i=1:length(nextloc)
if (ismember(GLOBAL_TRANSITION{nextloc(i)},test2)& ~ismember(nextloc(i),test2))
test3= [test3 nextloc(i)];
test3 = unique(test3);
end
end
fprintf('Drawing polytopes, please wait... ');
for i=1:length(test3)
var_location = GLOBAL_XSYS2AUTO_MAP{test3(i)}(1);
if ~(strcmp(var_location,'terminal'))& ~(strcmp(var_location,'out_of_bound'))
var_face = GLOBAL_XSYS2AUTO_MAP{test3(i)}(2);
var_state = GLOBAL_XSYS2AUTO_MAP{test3(i)}(3);
plot(GLOBAL_AUTOMATON{var_location}.face{var_face}.state{var_state}.polytope)
disp(test3(i));
end
end
fprintf('done! \n');
⌨️ 快捷键说明
复制代码Ctrl + C
搜索代码Ctrl + F
全屏模式F11
增大字号Ctrl + =
减小字号Ctrl + -
显示快捷键?