-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathilat.m
39 lines (29 loc) · 965 Bytes
/
ilat.m
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
30
31
32
33
34
35
36
37
38
39
%ILAT
%flaw of design: reordering while creating clones would break it
%what would reordering be used for?
function new_graph = ilat(G, num_reps)
%display original graph
num_displays = num_reps + 1; %starting + each repitition
if mod(num_displays, 10) == 0
t = tiledlayout(ceil(num_displays/5),5);
elseif mod(num_displays, 8) == 0
t = tiledlayout(ceil(num_displays/4),4);
elseif mod(num_displays, 6) == 0
t = tiledlayout(ceil(num_displays/3),3);
else
t = tiledlayout(ceil(num_displays/2),2);
end
title(t,"ILAT Model")
nexttile
plot(G);
title("Starting graph")
%repeat the cloning specified amount of times
for rep = 1:num_reps
G = anticlone_graph(G); %cloning step
%display next model of graph
nexttile
plot(G);
title("Graph " + string(rep));
end
new_graph = G;
end