Appendix G. Number Sequences in Sets and Maps

Table of Contents
G.1. The Set Class Library
G.2. The Map Class Library

G.1. The Set Class Library

Number of TnI Set Classes (Number of TnI Vector Registers). Encyclopedia of Integer Sequences Number: A052307, "Triangle T(n,k)"

Example G-1. Number of TnI Set Classes

n class vector (TnI)
card    2cv 3cv 4cv 5cv 6cv 7cv 8cv 9cv 10cv 11cv 12cv  

   1    0                                                                                
   2    6                                                                                 
   3    6   12                                               
   4    6   12  29                                                                
   5    6   12  29  38                                                        
   6    6   12  29  38  50                                             
   7    6   12  29  38  50  38                            
   8    6   12  29  38  50  38  29                       
   9    6   12  29  38  50  38  29  12                   
  10    6   12  29  38  50  38  29  12  6                   
  11    6   12  29  38  50  38  29  12  6    1             
  12    6   12  29  38  50  38  29  12  6    1    1      

Number of Tn Set Classes (Number of Tn Vector Registers). Encyclopedia of Integer Sequences Number: A035495, "Musical scales consisting of n notes"

Example G-2. Number of Tn Set Classes

        n class vector (Tn)
card    2xv 3xv 4xv 5xv 6xv 7xv 8xv 9xv 10xv 11xv 12xv  

   1    0                                                                                
   2    6                                                                                 
   3    6   19                                               
   4    6   19  43                                                                
   5    6   19  43  66                                                        
   6    6   19  43  66  80                                             
   7    6   19  43  66  80  66                            
   8    6   19  43  66  80  66  43                       
   9    6   19  43  66  80  66  43  19                   
  10    6   19  43  66  80  66  43  19  6                   
  11    6   19  43  66  80  66  43  19  6    1             
  12    6   19  43  66  80  66  43  19  6    1    1  

Number of Subsets (Sum of Vector Registers). Encyclopedia of Integer Sequences Number: A007318, "Pascal triangle", (Forte 1973, p. 27)

Example G-3. Number of Subsets

        subset cardinality
card    2   3   4   5   6   7   8   9   10  11  12 

   3    3   1                                           
   4    6   4   1                                      
   5    10  10  5   1                                         
   6    15  20  15  6   1                                       
   7    21  35  35  21  7   1                                
   8    28  56  70  56  28  8   1                          
   9    36  84  126 126 84  36  9   1                      
  10    45  120 210 252 210 120 45  10  1                
  11    55  165 330 462 462 330 165 55  11  1     
  12    66  220 495 792 924 792 495 220 66  12  1