load morse_digits.dat

tic;

best_vaf = 0.0;
store_vaf = zeros(1000,1);

for i = 1:1000
    
    [find,vaf,targone,targtwo,outpermone,outpermtwo,addconone,addcontwo] = ...
        ms_bicirac(morse_digits,randperm(10),3);
    
    store_vaf(i) = vaf;
    
    if (vaf > best_vaf)
        
        best_vaf = vaf;
        best_outpermone = outpermone;
        best_outpermtwo = outpermtwo;
        best_find = find;
        best_targone = targone;
        best_targtwo = targtwo;
        best_addconone = addconone;
        best_addcontwo = addcontwo;
        
    end
    
end

sorted_vafs = sort(store_vaf');

sorted_vafs;

        best_vaf
        best_outpermone 
        best_outpermtwo
        best_targone
        best_targtwo
        best_find
    
        best_addconone
        best_addcontwo 
        

toc;

figure(1)

[circum_one,radius_one,coord_one,degrees_one,cumdegrees_one] ...
    = circularplot(best_targone,best_outpermone)

figure(2)

[circum_two,radius_two,coord_two,degrees_two,cumdegrees_two] ...
    = circularplot(best_targtwo,best_outpermtwo)
