%% Plot Graph with Specified Layout
% Create a directed graph, and then plot the graph using the 'force' layout.

G = digraph(1,2:5);
G = addedge(G,2,6:15);
G = addedge(G,15,16:20)

%

plot(G,'Layout','force')

% Copyright 2015 The MathWorks, Inc.