H2Lib  3.0
Macros | Functions
laplacebem3d

This module contains functions to setup and solve boundary integral equations for the Laplace operator in 3D. More...

Macros

#define KERNEL_CONST_LAPLACEBEM3D   0.0795774715459476679
 Constant that originates from the fundamental solution of the Laplace equation. The value is $ 1 / 4 \pi $.
 

Functions

pbem3d new_slp_laplace_bem3d (pcsurface3d gr, uint q_regular, uint q_singular, basisfunctionbem3d row_basis, basisfunctionbem3d col_basis)
 Creates a new bem3d-object for computation of single layer potential matrix of the Laplace equation. More...
 
pbem3d new_dlp_laplace_bem3d (pcsurface3d gr, uint q_regular, uint q_singular, basisfunctionbem3d row_basis, basisfunctionbem3d col_basis, field alpha)
 Creates a new bem3d-object for computation of double layer potential matrix plus a scalar times the mass matrix of the Laplace equation. More...
 
pbem3d new_adlp_laplace_bem3d (pcsurface3d gr, uint q_regular, uint q_singular, basisfunctionbem3d row_basis, basisfunctionbem3d col_basis, field alpha)
 Creates a new bem3d-object for computation of adjoint double layer potential matrix plus a scalar times the mass matrix of the Helmholtz equation. More...
 
void del_laplace_bem3d (pbem3d bem)
 Delete a bem3d object for the Laplace equation. More...
 
field eval_dirichlet_linear_laplacebem3d (const real *x, const real *n, void *data)
 A simple linear harmonic function that will serve as dirichlet values. More...
 
field eval_neumann_linear_laplacebem3d (const real *x, const real *n, void *data)
 A simple linear harmonic function that will serve as neumann values. More...
 
field eval_dirichlet_quadratic_laplacebem3d (const real *x, const real *n, void *data)
 A simple quadratic harmonic function that will serve as dirichlet values. More...
 
field eval_neumann_quadratic_laplacebem3d (const real *x, const real *n, void *data)
 A simple quadratic harmonic function that will serve as neumann values. More...
 
field eval_dirichlet_fundamental_laplacebem3d (const real *x, const real *n, void *data)
 A harmonic function based upon the fundamental solution, that will serve as dirichlet values. More...
 
field eval_neumann_fundamental_laplacebem3d (const real *x, const real *n, void *data)
 A harmonic function based upon the fundamental solution, that will serve as neumann values. More...
 
field eval_dirichlet_fundamental2_laplacebem3d (const real *x, const real *n, void *data)
 A harmonic function based upon the fundamental solution, that will serve as dirichlet values. More...
 
field eval_neumann_fundamental2_laplacebem3d (const real *x, const real *n, void *data)
 A harmonic function based upon the fundamental solution, that will serve as neumann values. More...
 
pbem3d new_slp_laplace_ocl_bem3d (pcsurface3d gr, uint q_regular, uint q_singular, basisfunctionbem3d row_basis, basisfunctionbem3d col_basis)
 Creates a new bem3d-object for computation of single layer potential matrix supported by OpenCL. More...
 
pbem3d new_dlp_laplace_ocl_bem3d (pcsurface3d gr, uint q_regular, uint q_singular, basisfunctionbem3d row_basis, basisfunctionbem3d col_basis, field alpha)
 Creates a new bem3d-object for computation of double layer potential matrix supported by OpenCL. More...
 
void del_laplace_ocl_bem3d (pbem3d bem)
 Delete a bem3d object for the Laplace equation with OpenCL support. More...
 

Detailed Description

This module contains functions to setup and solve boundary integral equations for the Laplace operator in 3D.

Function Documentation

void del_laplace_bem3d ( pbem3d  bem)

Delete a bem3d object for the Laplace equation.

Parameters
bemObject to be deleted.
void del_laplace_ocl_bem3d ( pbem3d  bem)

Delete a bem3d object for the Laplace equation with OpenCL support.

Parameters
bemObject to be deleted.
field eval_dirichlet_fundamental2_laplacebem3d ( const real x,
const real n,
void *  data 
)

A harmonic function based upon the fundamental solution, that will serve as dirichlet values.

When computing the neumann data out of the dirichlet data one can use this function as test data which will generate dirichlet values of with the following values:

\[ f(\vec x, \, \vec n) = \frac{1}{\lVert \vec x - \vec z \rVert} \]

with $ \vec z = \left( 0.25, 0.25, 0.25 \right)^* $. Corresponding neumann data can be generated by using eval_neumann_fundamental2_laplacebem3d.
To build up an appropriate dirichlet data coefficient vector one needs the $ L_2$-projection. This can be done by passing this function to projectL2_bem3d_c_avector for piecewise constant basis functions or to projectL2_bem3d_l_avector for piecewise linear basis functions.

Parameters
xEvaluation point.
nNormal vector to current evaluation point.
dataAdditional data for evaluating the functional
Returns
returns the function value of $ f(\vec x, \, \vec n) $.
field eval_dirichlet_fundamental_laplacebem3d ( const real x,
const real n,
void *  data 
)

A harmonic function based upon the fundamental solution, that will serve as dirichlet values.

When computing the neumann data out of the dirichlet data one can use this function as test data which will generate dirichlet values of with the following values:

\[ f(\vec x, \, \vec n) = \frac{1}{\lVert \vec x - \vec z \rVert} \]

with $ \vec z = \left( 1.2, 1.2, 1.2 \right)^* $. Corresponding neumann data can be generated by using eval_neumann_fundamental_laplacebem3d.
To build up an appropriate dirichlet data coefficient vector one needs the $ L_2$-projection. This can be done by passing this function to projectL2_bem3d_c_avector for piecewise constant basis functions or to projectL2_bem3d_l_avector for piecewise linear basis functions.

Parameters
xEvaluation point.
nNormal vector to current evaluation point.
dataAdditional data for evaluating the functional
Returns
returns the function value of $ f(\vec x, \, \vec n) $.
field eval_dirichlet_linear_laplacebem3d ( const real x,
const real n,
void *  data 
)

A simple linear harmonic function that will serve as dirichlet values.

When computing the neumann data out of the dirichlet data one can use this function as test data which will generate dirichlet values of with the following values:

\[ f(\vec x, \, \vec n) = x_1 + x_2 + x_3 \]

Corresponding neumann data can be generated by using eval_neumann_linear_laplacebem3d.
To build up an appropriate dirichlet data coefficient vector one needs the $ L_2$-projection. This can be done by passing this function to projectL2_bem3d_c_avector for piecewise constant basis functions or to projectL2_bem3d_l_avector for piecewise linear basis functions.

Parameters
xEvaluation point.
nNormal vector to current evaluation point.
dataAdditional data for evaluating the functional
Returns
returns the function value of $ f(\vec x, \, \vec n) $.
field eval_dirichlet_quadratic_laplacebem3d ( const real x,
const real n,
void *  data 
)

A simple quadratic harmonic function that will serve as dirichlet values.

When computing the neumann data out of the dirichlet data one can use this function as test data which will generate dirichlet values of with the following values:

\[ f(\vec x, \, \vec n) = x_1^2 - 0.5 \, x_2^2 - 0.5 \, x_3^2 \]

Corresponding neumann data can be generated by using eval_neumann_quadratic_laplacebem3d.
To build up an appropriate dirichlet data coefficient vector one needs the $ L_2$-projection. This can be done by passing this function to projectL2_bem3d_c_avector for piecewise constant basis functions or to projectL2_bem3d_l_avector for piecewise linear basis functions.

Parameters
xEvaluation point.
nNormal vector to current evaluation point.
dataAdditional data for evaluating the functional
Returns
returns the function value of $ f(\vec x, \, \vec n) $.
field eval_neumann_fundamental2_laplacebem3d ( const real x,
const real n,
void *  data 
)

A harmonic function based upon the fundamental solution, that will serve as neumann values.

When computing the neumann data out of the dirichlet data one can use this function as test data which will generate neumann values of with the following values:

\[ f(\vec x, \, \vec n) = -\frac{<\vec n, \vec x - \vec z>}{\lVert \vec x - \vec z \rVert^3} \]

with $ \vec z = \left( 0.25, 0.25, 0.25 \right)^* $. Corresponding dirichlet data can be generated by using eval_dirichlet_fundamental_laplacebem3d.
To build up an appropriate neumann data coefficient vector one needs the $ L_2$-projection. This can be done by passing this function to projectL2_bem3d_c_avector for piecewise constant basis functions or to projectL2_bem3d_l_avector for piecewise linear basis functions.

Parameters
xEvaluation point.
nNormal vector to current evaluation point.
dataAdditional data for evaluating the functional
Returns
returns the function value of $ f(\vec x, \, \vec n) $.
field eval_neumann_fundamental_laplacebem3d ( const real x,
const real n,
void *  data 
)

A harmonic function based upon the fundamental solution, that will serve as neumann values.

When computing the neumann data out of the dirichlet data one can use this function as test data which will generate neumann values of with the following values:

\[ f(\vec x, \, \vec n) = -\frac{<\vec n, \vec x - \vec z>}{\lVert \vec x - \vec z \rVert^3} \]

with $ \vec z = \left( 1.2, 1.2, 1.2 \right)^* $. Corresponding dirichlet data can be generated by using eval_dirichlet_fundamental_laplacebem3d.
To build up an appropriate neumann data coefficient vector one needs the $ L_2$-projection. This can be done by passing this function to projectL2_bem3d_c_avector for piecewise constant basis functions or to projectL2_bem3d_l_avector for piecewise linear basis functions.

Parameters
xEvaluation point.
nNormal vector to current evaluation point.
dataAdditional data for evaluating the functional
Returns
returns the function value of $ f(\vec x, \, \vec n) $.
field eval_neumann_linear_laplacebem3d ( const real x,
const real n,
void *  data 
)

A simple linear harmonic function that will serve as neumann values.

When computing the neumann data out of the dirichlet data one can use this function as test data which will generate neumann values of with the following values:

\[ f(\vec x, \, \vec n) = n_1 + n_2 + n_3 \]

Corresponding dirichlet data can be generated by using eval_dirichlet_linear_laplacebem3d.
To build up an appropriate neumann data coefficient vector one needs the $ L_2$-projection. This can be done by passing this function to projectL2_bem3d_c_avector for piecewise constant basis functions or to projectL2_bem3d_l_avector for piecewise linear basis functions.

Parameters
xEvaluation point.
nNormal vector to current evaluation point.
dataAdditional data for evaluating the functional
Returns
returns the function value of $ f(\vec x, \, \vec n) $.
field eval_neumann_quadratic_laplacebem3d ( const real x,
const real n,
void *  data 
)

A simple quadratic harmonic function that will serve as neumann values.

When computing the neumann data out of the dirichlet data one can use this function as test data which will generate neumann values of with the following values:

\[ f(\vec x, \, \vec n) = 2 \, \left( n_1 \, x_1 - 0.5 \, n_2 \, x_2 - 0.5 \, n_3 \, x_3 \right) \]

Corresponding dirichlet data can be generated by using eval_dirichlet_quadratic_laplacebem3d.
To build up an appropriate neumann data coefficient vector one needs the $ L_2$-projection. This can be done by passing this function to projectL2_bem3d_c_avector for piecewise constant basis functions or to projectL2_bem3d_l_avector for piecewise linear basis functions.

Parameters
xEvaluation point.
nNormal vector to current evaluation point.
dataAdditional data for evaluating the functional
Returns
returns the function value of $ f(\vec x, \, \vec n) $.
pbem3d new_adlp_laplace_bem3d ( pcsurface3d  gr,
uint  q_regular,
uint  q_singular,
basisfunctionbem3d  row_basis,
basisfunctionbem3d  col_basis,
field  alpha 
)

Creates a new bem3d-object for computation of adjoint double layer potential matrix plus a scalar times the mass matrix of the Helmholtz equation.

After calling this function the resulting bem-object will provide all functionality that is necessary to build up fully populated adjoint double layer potential matrix $ K' + \alpha M \in \mathbb R^{\mathcal I \times \mathcal J}$ and also hmatrix or h2matrix approximation of this matrix.

Parameters
grSurface mesh.
q_regularOrder of gaussian quadrature used within computation of matrix entries for single integrals and regular double integrals.
q_singularOrder of gaussian quadrature used within computation of matrix entries singular double integrals.
row_basisType of basis functions that are used for the test space. Can be one of the values defined in basisfunctionbem3d.
col_basisType of basis functions that are used for the trial space. Can be one of the values defined in basisfunctionbem3d.
alphaAdjoint double layer operator + $\alpha$ mass matrix.
Returns
Returns a bem-object that can compute fully populated adlp matrices $ K' + \alpha M $ for the Laplace equation.
pbem3d new_dlp_laplace_bem3d ( pcsurface3d  gr,
uint  q_regular,
uint  q_singular,
basisfunctionbem3d  row_basis,
basisfunctionbem3d  col_basis,
field  alpha 
)

Creates a new bem3d-object for computation of double layer potential matrix plus a scalar times the mass matrix of the Laplace equation.

After calling this function the resulting bem-object will provide all functionality that is necessary to build up fully populated double layer potential matrix $ K + \frac{1}{2} M \in \mathbb R^{\mathcal I \times \mathcal J}$ and also hmatrix or h2matrix approximation of this matrix.

Parameters
grSurface mesh.
q_regularOrder of gaussian quadrature used within computation of matrix entries for single integrals and regular double integrals.
q_singularOrder of gaussian quadrature used within computation of matrix entries singular double integrals.
row_basisType of basis functions that are used for the test space. Can be one of the values defined in basisfunctionbem3d.
col_basisType of basis functions that are used for the trial space. Can be one of the values defined in basisfunctionbem3d.
alphaDouble layer operator + $\alpha$ mass matrix.
Returns
Returns a bem-object that can compute fully populated dlp matrices $ K + \frac{1}{2} M $ for the Laplace equation.
pbem3d new_dlp_laplace_ocl_bem3d ( pcsurface3d  gr,
uint  q_regular,
uint  q_singular,
basisfunctionbem3d  row_basis,
basisfunctionbem3d  col_basis,
field  alpha 
)

Creates a new bem3d-object for computation of double layer potential matrix supported by OpenCL.

After calling this function the resulting bem-object will provide all functionality that is necessary to build up fully populated double layer potential matrix $ K + \alpha M \in \mathbb R^{\mathcal I \times \mathcal J}$ and also hmatrix or h2matrix approximation of this matrix.

The computation intense parts like _bem3d::nearfield are carried out to the GPU, if one uses this constructor and enabled the use of OpenCL.

Parameters
grSurface mesh.
q_regularOrder of gaussian quadrature used within computation of matrix entries for single integrals and regular double integrals.
q_singularOrder of gaussian quadrature used within computation of matrix entries singular double integrals.
row_basisType of basis functions that are used for the test space. Can be one of the values defined in basisfunctionbem3d.
col_basisType of basis functions that are used for the trial space. Can be one of the values defined in basisfunctionbem3d.
alphaDouble layer operator + $\alpha$ mass matrix.
Returns
Returns a bem-object that can compute fully populated dlp matrices $ K + \alpha M $ for the Laplace equation.
pbem3d new_slp_laplace_bem3d ( pcsurface3d  gr,
uint  q_regular,
uint  q_singular,
basisfunctionbem3d  row_basis,
basisfunctionbem3d  col_basis 
)

Creates a new bem3d-object for computation of single layer potential matrix of the Laplace equation.

After calling this function the resulting bem-object will provide all functionality that is necessary to build up fully populated single layer potential matrix $ V \in \mathbb R^{\mathcal I \times \mathcal I}$ and also hmatrix or h2matrix approximation of this matrix.

Parameters
grSurface mesh
q_regularOrder of gaussian quadrature used within computation of matrix entries for single integrals and regular double integrals.
q_singularOrder of gaussian quadrature used within computation of matrix entries singular double integrals.
row_basisType of basis functions that are used for the test space. Can be one of the values defined in basisfunctionbem3d.
col_basisType of basis functions that are used for the trial space. Can be one of the values defined in basisfunctionbem3d.
Returns
Returns a bem-object that can compute fully populated slp matrices $ V $ for the Laplace equation.
pbem3d new_slp_laplace_ocl_bem3d ( pcsurface3d  gr,
uint  q_regular,
uint  q_singular,
basisfunctionbem3d  row_basis,
basisfunctionbem3d  col_basis 
)

Creates a new bem3d-object for computation of single layer potential matrix supported by OpenCL.

After calling this function the resulting bem-object will provide all functionality that is necessary to build up fully populated single layer potential matrix $ V \in \mathbb R^{\mathcal I \times \mathcal I}$ and also hmatrix or h2matrix approximation of this matrix.

The computation intense parts like _bem3d::nearfield are carried out to the GPU, if one uses this constructor and enabled the use of OpenCL.

Parameters
grSurface mesh
q_regularOrder of gaussian quadrature used within computation of matrix entries for single integrals and regular double integrals.
q_singularOrder of gaussian quadrature used within computation of matrix entries singular double integrals.
row_basisType of basis functions that are used for the test space. Can be one of the values defined in basisfunctionbem3d.
col_basisType of basis functions that are used for the trial space. Can be one of the values defined in basisfunctionbem3d.
Returns
Returns a bem-object that can compute fully populated slp matrices $ V $ for the Laplace equation.