On this page we will show how the convolution of ODFs, SO3Fun's, Spherical functions (S2Fun's)
, SO3Kernel's
and S2Kernel's
is defined.
The convolution is an integral operator which is often used to smooth functions or compute their cross correlation.
We have to distinguish which objects are convoluted.
Convolution of two rotational functions
Here we distinguish two definitions. They are named the left \(*_L\) and right \(*_R\) sided convolution.
- The left sided convolution (default)*
Let two SO3Fun's
\(f \colon {}_{S_L } \backslash SO(3) /_{S_x} \to \mathbb{C}\) where \(S_L\) is the left symmetry and \(S_x\) is the right symmetry and \(g: {}_{S_x} \backslash SO(3) /_{S_R} \to \mathbb C\) where \(S_x\) is the left symmetry and \(S_R\) is the right symmetry be given.
Then the convolution \(f {*}_L g \colon {}_{S_L} \backslash SO(3) /_{S_R} \to \mathbb C\) is defined by
\[ (f {*}_L g)(R) = \frac{1}{8\pi^2} \int_{SO(3)} f(q) \cdot g(q^{-1}\,R) \, dq \]
where the right symmetry of \(f\) have to coincide with the left symmetry of \(g\). The normalization factor of the integral reads as \(vol(SO(3)) = \int_{SO(3)} 1 \, dR = 8\pi^2\).
Note that the left sided convolution \(*_L\) is used as default in MTEX.
The right sided convolution
As contrast we have the second definition:
Let two SO3Fun's
\(f \colon {}_{S_x } \backslash SO(3) /_{S_R} \to \mathbb{C}\) where \(S_x\) is the left symmetry and \(S_R\) is the right symmetry and \(g: {}_{S_L} \backslash SO(3) /_{S_x} \to \mathbb C\) where \(S_L\) is the left symmetry and \(S_x\) is the right symmetry be given.
The convolution \(f {*}_R g \colon {}_{S_L}\backslash SO(3) /_{S_R} \to \mathbb{C}\) is defined by
\[ (f {*}_R g)(R) = \frac1{8\pi^2} \int_{SO(3)} f(q) \cdot g(R\,q^{-1}) \, dq \]
where the left symmetry of \(f\) have to coincide with the right symmetry of \(g\).
The convolution of matrices of SO3FunHarmonic's with matrices of SO3 Functions works elementwise, see at multivariate SO3Fun's for there definition.
Convolution of two spherical functions
Consider there are two S2Fun's
\(f: \mathbb S^2 /_{S_R} \to \mathbb{C}\) \(g: \mathbb S^2 /_{S_L} \to \mathbb{C}\) given, where \(S_R\) and \(S_L\) denotes the symmetries.
Then the spherical convolution yields a orientation dependent function \(f*g: {}_{S_L} \backslash SO(3) /_{S_R} \to \mathbb{C}\) with right symmetry \(S_R\) and left symmetry \(S_L\). The convolution is defined by
\[ (f * g)(R) = \frac1{4\pi} \int_{S^2} f(R^{-1}\xi) \cdot g(\xi) \, d\xi. \]
The normalization factor of the integral reads as \(vol(S^2) = \int_{S^2} 1 \, d\xi = 4\pi\).
Convolution of a rotational function with a spherical function
We consider a SO3Fun
\(f: {}_{S_h} \backslash SO(3) /_{S_R} \to \mathbb{C}\) with left symmetry \(S_h\) and right symmetry \(S_R\) and a S2Fun
\(h \colon \mathbb S^2 /_{S_h} \to \mathbb C\) with symmetry group \(S_h\).
The convolution yields a S2Fun
\(f*h \colon \mathbb S^2/_{S_R} \to \mathbb C\). In MTEX it is defined by
\[ (f * h)(\xi) = \frac1{8\pi^2} \int_{SO(3)} f(q) \cdot h(q\,\xi) \, dq. \]
If you want to compute the convolution of \(f: {}_{'1'} \backslash SO(3) /_{S_R} \to \mathbb{C}\) and \(h \colon \mathbb S^2 /_{S_R} \to \mathbb C\) which yields \(f*h \colon \mathbb S^2/_{S_R} \to \mathbb C\) and is defined as
\[ (f * h)(\xi) = \frac1{8\pi^2} \int_{SO(3)} f(q) \cdot h(q^{-1}\,\xi) \, dq. \]
Convolution with kernel function
- rotational kernel functions *
Since SO3Kernel's
are special orientation dependent functions we can easily describe them as SO3Fun's
. Hence the convolution with SO3Kernel's
is exactly the same as above.
Note that SO3Kernel's
are radial basis functions which only depends on the rotation angle \(\omega\). Since the rotation angle of two matrices satisfies \(\omega(q^{-1}\,R)=\omega(R\,q^{-1})\), the left and right sided convolution are equivalent by convolution with SO3Kernels
. Moreover the convolution is commutative in this case.
- spherical kernel functions *
Let a spherical kernel function \(\psi(\vec v \cdot \vec e_3)\) be defined as in S2Kernel's
. Then the convolution with a S2Fun reads as
\[ (f * \psi) (\vec v) = \frac1{4\pi} \int_{S^2} f(\xi) \, \psi(\xi \cdot \vec v) \, d\xi. \]
Note that S2Kernel's
are special spherical functions. Hence we can easily describe them as S2Fun's
and convoluted them as described above for convolution of two spherical functions
\[ (f * \psi) (R) = \frac1{4\pi} \int_{S^2} f(R^{-1}\,\xi) \, \psi(\xi \cdot \vec e_3) \, d\xi. \]
The first formula yields a S2Fun while the second formula yields a SO3Fun. They are equal for \(\vec v = R^{-1} \vec e_3\).