|
OpenBEM
Open-source framework for electromagnetic simulation with the boundary element method.
|
Class for computing the scalar Green's function for homogeneous, linear, and isotropic materials, with the singular term(s) implicitly subtracted using the Taylor series expansion of the kernel. More...
#include <hgf.hpp>
Inheritance diagram for bem::SingularitySubtractedTaylorHGF:Class for computing the scalar Green's function for homogeneous, linear, and isotropic materials, with the singular term(s) implicitly subtracted using the Taylor series expansion of the kernel.
| Complex bem::SingularitySubtractedTaylorHGF::kernel | ( | ConstEigRef< EigColVecN< Float, 3 > > | r_obs, |
| ConstEigRef< EigColVecN< Float, 3 > > | r_src, | ||
| const Complex | k | ||
| ) | const |
Computes the kernel for given observation and source points.
| [in] | r_obs | - Observer position vector. |
| [in] | r_src | - Source position vector. |
| [in] | k | - Complex wavenumber. |
Computes
\[ \frac{e^{-jk|\vec{r} - \vec{r}\,'|}}{4\pi|\vec{r} - \vec{r}\,'|} - \frac{1}{4\pi|\vec{r} - \vec{r}\,'|} \]
where \( \vec{r} \) is the observer position vector, \( \vec{r}\,' \) is the source position vector, and \( k \) is the complex wavenumber. The singular term is never actually computed; it is implicitly subtracted out using the Taylor series expansion
\[ \frac{e^{-jk|\vec{r} - \vec{r}\,'|}}{4\pi|\vec{r} - \vec{r}\,'|} = \frac{1}{4\pi|\vec{r} - \vec{r}\,'|} + \frac{(-jk)}{4\pi} + \frac{(-jk)^2}{4\pi\cdot 2!}|\vec{r} - \vec{r}\,'| + \ldots \]
truncated when the next term is smaller than the tolerance KERNEL_DEFAULT_TOL relative to the sum so far.
| EigColVecN< Complex, 3 > bem::SingularitySubtractedTaylorHGF::grad_kernel | ( | ConstEigRef< EigColVecN< Float, 3 > > | r_obs, |
| ConstEigRef< EigColVecN< Float, 3 > > | r_src, | ||
| const Complex | k | ||
| ) | const |
Computes the gradient of the kernel for given observation and source points.
| [in] | r_obs | - Observer position vector. |
| [in] | r_src | - Source position vector. |
| [in] | k | - Complex wavenumber. |
Computes
\begin{align*} \nabla\left(\frac{e^{-jk|\vec{r} - \vec{r}\,'|}}{4\pi|\vec{r} - \vec{r}\,'|} - \frac{1}{4\pi|\vec{r} - \vec{r}\,'|}\right) &=\\ -(\vec{r} - \vec{r}\,')&\left[\left(1 + jk|\vec{r} - \vec{r}\,'|\right) \frac{e^{-jk|\vec{r} - \vec{r}\,'|}}{4\pi|\vec{r} - \vec{r}\,'|^3} - \frac{1}{4\pi|\vec{r} - \vec{r}\,'|^3} - \left(\frac{1}{2}\right) \frac{k^2}{4\pi|\vec{r} - \vec{r}\,'|}\right] \end{align*}
where \( \vec{r} \) is the observer position vector, \( \vec{r}\,' \) is the source position vector, and \( k \) is the complex wavenumber. The singular term is never actually computed; it is implicitly subtracted out using the Taylor series expansion
\[ \nabla\left(\frac{e^{-jk|\vec{r} - \vec{r}\,'|}}{4\pi|\vec{r} - \vec{r}\,'|}\right) = -\frac{\vec{r} - \vec{r}\,'}{4\pi|\vec{r} - \vec{r}\,'|}\left[ \frac{1}{|\vec{r} - \vec{r}\,'|^2} - \frac{(-jk)^2}{2!} - 2\frac{(-jk)^3}{3!}|\vec{r} - \vec{r}\,'| + \ldots\right] \]
truncated when the next term is smaller than the tolerance KERNEL_DEFAULT_TOL relative to the sum so far.
|
pure virtualinherited |
Computes the scalar kernel for given observation and source points.
| [in] | r_obs | - Observer position vector. |
| [in] | r_src | - Source position vector. |
| [in] | k | - Complex wavenumber. |
|
pure virtualinherited |
Computes the gradient of the scalar kernel for given observation and source points.
| [in] | r_obs | - Observer position vector. |
| [in] | r_src | - Source position vector. |
| [in] | k | - Complex wavenumber. |