function figure_17_9
% Figure 17.9: A sample of periodic orbits for A approximately 27 on the
% family of symmetric (b) and along the closed family of nonsymmetric (a)
% and (c), two-loop oscillations located in the center of Fig. 17.8. The
% latter two orbits are again symmetry conjugate and lie at period-doubling
% points.

% Note that machine-dependent round-off errors may result in different
% solution labels for the period-doubling points.

% Generate data
if ~(coco_exist('run1', 'run') && coco_exist('run2', 'run') ...
    && coco_exist('run3', 'run') && coco_exist('run4', 'run') ...
    && coco_exist('run5', 'run'))
  run demo_atlas1d_v7
end

coco_use_recipes_toolbox coll_v1 msbvp_v1 hspo_v2

labs  = [115 400 428];

for i=1:3
  figure(i)
  clf
  hold on
  grid on
  box on
  axis([-6 6 -20 20]);
  
  sol = msbvp_read_solution('', 'run2', labs(i));
  plot(sol{1}.x(:,1),sol{1}.x(:,2), 'LineStyle', '-', 'LineWidth', 2, ...
    'Color', 'black', 'Marker', '.', 'MarkerSize', 12);
  plot(sol{2}.x(:,1),sol{2}.x(:,2), 'LineStyle', '-', 'LineWidth', 2, ...
    'Color', [0.6 0.6 0.6], 'Marker', '.', 'MarkerSize', 12);
  
  hold off
end

coco_use_recipes_toolbox

end
