Bempp uses a global options structure in bempp.api.global_parameters to control various aspects of the library. In addition, several functions and classes have a parameters attribute that can take a custom parameters object. This is useful if one wants to override the global parameters for a certain function. A custom parameters object can be created using the following command.
In this tutorial, we give a description of all global parameter options.
This parameter controls whether boundary operators are assembled in dense mode or in hmat mode. The default is hmat to use H-matrix assembly for boundary operators.
This parameter controls whether potential operators are assembled in dense mode or in hmat mode (default). For exterior potentials, H-matrix assembly is almost always preferable.
If set to
True(default), singular integrals are pre-calculated and cached before the regular integrals are calculated. This usually gives a small speed advantage and should not need to be modified.
If set to True (default), Helmholtz type kernels (including Maxwell) are evaluated using a piecewise Hermite interpolation. This is significantly faster than evaluating the exponentials directly.
This parameter sets the number of interpolation points per wavelength to be used (default 5000).
This modifies the quadrature options.
This parameter sets the type of admissibility condition. The default is weak, which declares a block cluster admissible if the column and range cluster bounding boxes do not intersect. The classical H-matrix admissibility condition is obtained by setting this parameter to strong.
If this parameter is set to True (default), this will enable automatic coarsening of H-matrices.
This parameter controls the accuracy of the coarsening procedure. The default value is 0, meaning that the accuracy set in the eps parameter is used.
This sets the compression algorithm that is used. The default is aca, which uses a modified adaptive cross approximation with heuristic failure detection. By choosing dense, no compression is performed and all blocks are stored as dense matrices.
This sets the relative accuracy of the H-matrix compression.
The H-matrix vector product is a hierarchic operation. For each node of the tree parallel tasks corresponding to the number of children are created. This parameter sets the level at which a serial algorithm should start to be used in order to limit the number of very small tasks, as can be inefficient (default 5).
For load-balancing reasons it is useful to restrict the maximum block size, as each block is compressed using a single task and a very large block would occupy a single task for too long. The default is 2048, but should be increased for very large problems.
This parameter is the maximum allowed rank for the compression of a block. The block compression stops at this rank even if the accuracy requirements are not yet achieved. The default is 30.
This sets the minimum size of a block. The default is 20, meaning that clustering stops if fewer than 20 degrees of freedom are left in a cluster node.