Collection: Integral¶
Predefined class for volume and boundary integral equations in 2-dimensional or 3-dimensional space, discretized by one of three typical methods: Galerkin, collocation or Nystrom.
-
class
h2tools.collections.integral.
DiscretizedArea
(ndim, count, vertex=None, element=None, normal=None, area=None, collocation=None)¶ Stores area as discrete elements, normals and collocation points.
Helpful in discretizations of integral equations by one of 3 typical methods: Galerkin, collocation or Nystrom. Every parameter, except ndim and count is optional. Non-optional parameters depend on discretization type.
Uses inertial bisection of collocation points for cluster tree generation. If collocation points are not set up, they are computed as geometrical centers of discrete elements.
Parameters: ndim : int
Dimensionality of space.
count : int
Number of discrete elements.
vertex : 2-dimensional array
Coordinates of vertices. Shape is (ndim, count).
element: 1-dimensional array
Information on discrete elements is one after another. Each discrete element is presented as number of corresponding vertices, followed by their indexes.
normal : 2-dimensional array
Normals for each discrete element. Shape is (ndim, count).
area : 1-dimensional array
Area of each discrete element.
collocation : 2-dimensional array
Coordinates of collocation points. Shape is (ndim, count).
Attributes
element_size (array of int) Contains number of vertices, corresponding to discrete element element_start (array of int) Where indexes of corresponding vertices are located in elements -
check_far
(self_aux, other_aux)¶ Checks if two bounding boxes are far or close.
If maximum diagonal of bounding boxes is larger, than distance between centers of bounding boxes, then bounding boxes are assumed to be far and function returns True.
Parameters: self_aux, other_aux : numpy.ndarray of shape (2, ndim)
Each bounding box contains minimum values of corresponding coordinates in [0,:] and maximum values of corresponding coordinates in [1,:].
Returns: boolean
True if bounding boxes are far, False otherwise.
-
compute_aux
(index)¶ Computes bounding box of cluster, corresponding to index.
-
divide
(index)¶ Divides cluster, corresponding to indexes index.
Clusters is divided by inertial bisection procedure, applied to collocation points of discrete elements.
-