In order to make compositions of n-diagrams and count the number of components we use the complete set of chord diagrams and closures of n-tangles.

For example, the basic chord diagrams 3.1-3.5 have, respectively, 1,3,2,3,6 possible positions. Among all basic chord diagrams for n=3,4, only one diagram, 4.17, has the left and right form and the maximal number of 16 possible positions.

The set of n-diagrams is closed with regard to n-tangle compositions modulo internal closed components. For example, the composition of the chord diagram 3.3 with itself gives the same chord diagram with one additional closed internal component, so can be denoted by 3.31. Hence, we can work in the complete set of n-diagrams and their compositions, and keep the record of the internal closed components by adding subscripts.

The complete set of n-diagrams with the operation of n-tangle composition is the non-commutative monoid - a non-commutative semigroup with the neutral element. The neutral element is the n-diagram with horizontal parallel chords (e.g., 3.4, 4.9). This set has (2n-1)!! elements, where (2n-1)!! is the odd factorial number (2n-1)!!=1·3·¼(2n-1). The number of n-diagrams is given by the sequence A001147 from the Encyclopedia of Integer Sequences by N. Sloane: 1,3,15,105,945,10395,¼ and can be easily computed from this general formula. For n=3 the minimal set of generators of the complete set of 3-diagrams consists from three diagrams without connected adjacent vertices (e.g., the diagram 3.1, and two positions of the diagram 3.2). For n > 3 we start from the basic n-diagrams without connected adjacent vertices (e.g., the diagrams 4.1-4.7 for n=4, etc.) From this set we can choose different minimal sets of generators, each consisting from appropriately chosen positions of three different basic diagrams. For example, we can use the diagrams for n=4, or the diagrams for n=5. Lj. Radovic proved that for every n (n ³ 2) the minimal set of generators consists from three diagrams (Radovic, 2006). For n=2,3,4,5,6,7,8,9¼ the number of basic n-diagrams is 1,2,7,36,300,3218,42335,644808,¼, given by the sequence A007474 from the Encyclopedia of Integer Sequences by N. Sloane (Bar-Natan, 1995). The LinKnot function ListOfOneFactors (webMathematica ListOfOneFactors) written by T. Bertok and corrected by the authors gives, as the result, all basic n-diagrams without connected adjacent vertices. The function fMulTan (webMathematica fMulTan) multiplies n-diagrams, and the function fMulTanTab (webMathematica fMulTanTab) gives their multiplication table. The function fGenSet (webMathematica fGenSet) checks if a given set of diagrams is a generator set of the complete set of n-diagrams.

If the elements of the complete set of 3-diagrams are denoted by 1-15, the following multiplication table is obtained (subscripts denote internal closed components):

 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 1 7 2 10 13 8 9 1 5 6 3 12 11 4 14 15 2 2 21 15 14 14 15 2 14 15 15 2 2 14 141 151 3 13 12 4 7 8 15 3 14 6 1 2 11 10 5 9 4 10 11 7 3 14 9 4 5 15 13 12 2 1 8 6 5 9 12 12 9 51 9 5 5 91 5 12 121 12 5 9 6 8 11 8 11 8 61 6 81 6 11 111 11 6 8 6 7 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 8 6 11 11 6 81 6 8 8 61 8 11 111 11 8 6 9 5 12 5 12 5 91 9 51 9 12 121 12 9 5 9 10 4 11 13 1 5 15 10 14 9 7 2 12 3 8 6 11 11 111 6 8 8 6 11 8 6 6 11 11 8 81 61 12 12 121 9 5 5 9 12 5 9 9 12 12 5 51 91 13 3 12 1 10 14 6 13 8 15 4 11 2 7 5 9 14 15 2 2 15 141 15 14 14 151 14 2 21 2 14 15 15 14 2 14 2 14 151 15 141 15 2 21 2 15 14 15