Meshers¶
Overview¶
The conception of Mesher is used in the finite-difference (FD) method. Each mesher stores the discretization of one dimension. It has a array locations that stores the discretization at points x0,x1,..,xn−1. It also has two other arrays dplus and dminus that store the i-th elements (xi+1−xi) and (xi−xi−1) respectively.
The multi-dimensional mesh for a finite-difference model is represented by multi 1-D meshers, which build the full mesh by composing a 1-D mesh for every dimension.
Implementation¶
Mesher creates an equally-spaced grid between two given boundaries and with the given number of points with a specific processor. 1. locations: The coordinates of location are evolved based a normal random number. 2. dplus: The argument is calculated at point (xi+1−xi). 3. dminus: The argument is calculated at point (xi−xi−1).