The meaning of 3-j symbol is same as Clebsch-Gordan coefficient. So, we skip in here.

I am not going to construct the 6-j symbol from 3-j symbol. In here, I just state the meaning and usage in Mathematica.

The 6-j symbol is the coupling between 3 angular momenta, $j_1, j_2, j_3$.

There are 2 ways to couple these 3 angular momenta. First,

$j_1 + j_2 + j_3 \rightarrow j_{12} + j_3 \rightarrow J$

the other way is

$j_ 1 + j_2 + j_3 \rightarrow j_1 + j_{23} \rightarrow J$

The 6-j symbol is

$\begin{pmatrix} j_1 & j_2 & j_{12} \\ j_3 & J & j_{23} \end{pmatrix}$

We can see that there are 4 vector-sum must satisfy.

$\Delta(j_1, j_2, j_{12})$

$\Delta(j_2, j_3, j_{23})$

$\Delta(j_1, j_{23}, J)$

$\Delta(j_{12}, j_3, J)$

If we draw a line to connect these 4 vector-sum, we have:

In Mathematica, there is a build in function

$\textrm{SixJSymbol}[ \left\{j_1, j_2, j_{23} \right\}, \left\{j_3, J , j_{23} \right\}]$

The 9-j symbol is the coupling between 4 angular momenta, $j_1, j_2, j_3, j_4$.

The 9-j symbol can be used in coupling 2 nucleons, $l_1, s_1, l_2, s_2$.

The 9-j symbol is

$\begin{pmatrix} l_1 & s_1 & j_1 \\ l_2 & s_2 & j_2 \\ L & S & J \end{pmatrix}$

We can see, each row and column must satisfy the vector-sum.

Unfortunately, there is no build in function in Mathematica. The formula for 9-j symbol is

$\displaystyle \begin{pmatrix} l_1 & s_1 & j_1 \\ l_2 & s_2 & j_2 \\ L & S & J \end{pmatrix} \\ = \sum_{g} (-1)^{2g} (2g+1) \begin{pmatrix} l_1 & s_1 & j_1 \\ j_2 & J & g \end{pmatrix} \begin{pmatrix} j_2 & s_2 & j_2 \\ s_1 & g & S \end{pmatrix} \begin{pmatrix} L & S & J \\ g & l_1 & l_2 \end{pmatrix}$

Where $g$ sum all possible value, which can be calculate using the 6 couplings inside the 3 6-j symbols.To check your result, the coupling between $d_{5/2}$ and $f_{7/2}$ to from a $L = 5, S = 0, J = 0$ state is

$\begin{pmatrix} 2 & 1/2 & 5/2 \\ 3 & 1/2 & 7/2 \\ 5 & 0 & 5 \end{pmatrix} = \frac{1}{2\sqrt{770}}$