e3x.so3.irreps.solid_harmonics
- e3x.so3.irreps.solid_harmonics(r, max_degree, cartesian_order=True)[source]
Real Cartesian (regular) solid harmonics \(R_\ell^m(\vec{r})\).
The solid harmonics are defined as
\[R_{\ell}^{m}(\vec{r}) = \lVert\vec{r}\rVert^\ell Y_{\ell}^{m}(\vec{r})\,,\]where \(Y_{\ell}^{m}(\vec{r})\) are spherical harmonics using Racah’s normalization. See also
spherical_harmonicsfor more details.- Parameters:
r (
<class 'Float[Array, '... 3']'>) – Array of shape(..., 3)containing Cartesian vectors \(\vec{r}\).max_degree (
int) – Maximum degree \(L\) of the solid harmonics.cartesian_order (
bool, default:True) – IfTrue, solid harmonics are returned in Cartesian order.
- Return type:
- Returns:
The values \(R_\ell^m(\vec{r})\) of all solid harmonics up to \(\ell\) =
max_degree. Values are returned in an Array of shape(..., (max_degree+1)**2)ordered \([R_{0}^{0}\ R_{1}^{1}\ R_{1}^{-1}\ R_{1}^{0}\ R_{2}^{2}\ \cdots]\). Ifcartesian_order = False, values are ordered \([R_{0}^{0}\ R_{1}^{-1}\ R_{1}^{0}\ R_{1}^{1}\ R_{2}^{-2}\ \cdots]\) instead.- Raises:
ValueError – If
rhas an invalid shape (not a 3-vector), ormax_degree` is not positive or zero –