?_init_Helmholtz_2D/?_init_Helmholtz_3D
?_init_Helmholtz_2D/?_init_Helmholtz_3D
Initializes basic data structures of the Fast 2D/3D Helmholtz Solver.
Syntax
void
d_init_Helmholtz_2D
(
const
double
*
ax
,
const
double
*
bx
,
const
double
*
ay
,
const
double
*
by
,
const
MKL_INT
*
nx
,
const
MKL_INT
*
ny
,
const
char
*
BCtype
,
const
double
*
q
,
MKL_INT
*
ipar
,
double
*
dpar
,
MKL_INT
*
stat
);
void
s_init_Helmholtz_2D
(
const
float
*
ax
,
const
float
*
bx
,
const
float
*
ay
,
const
float
*
by
,
const
MKL_INT
*
nx
,
const
MKL_INT
*
ny
,
const
char
*
BCtype
,
const
float
*
q
,
MKL_INT
*
ipar
,
float
*
spar
,
MKL_INT
*
stat
);
void
d_init_Helmholtz_3D
(
const
double
*
ax
,
const
double
*
bx
,
const
double
*
ay
,
const
double
*
by
,
const
double
*
az
,
const
double
*
bz
,
const
MKL_INT
*
nx
,
const
MKL_INT
*
ny
,
const
MKL_INT
*
nz
,
const
char
*
BCtype
,
const
double
*
q
,
MKL_INT
*ipar
,
double
*
dpar
,
MKL_INT
*
stat
);
void
s_init_Helmholtz_3D
(
const
float
*
ax
,
const
float
*
bx
,
const
float
*
ay
,
const
float
*
by
,
const
float
*
az
,
const
float
*
bz
,
const
MKL_INT
*
nx
,
const
MKL_INT
*
ny
,
const
MKL_INT
*
nz
,
const
char
*
BCtype
,
const
float
*
q
,
MKL_INT
*
ipar
,
float
*
spar
,
MKL_INT
*
stat
);
Include Files
- mkl.h
Input Parameters
- ax
- double*ford_init_Helmholtz_2D/d_init_Helmholtz_3D,float*fors_init_Helmholtz_2D/s_init_Helmholtz_3D.The coordinate of the leftmost boundary of the domain along the x-axis.
- bx
- double*ford_init_Helmholtz_2D/d_init_Helmholtz_3D,float*fors_init_Helmholtz_2D/s_init_Helmholtz_3D.The coordinate of the rightmost boundary of the domain along the x-axis.
- ay
- double*ford_init_Helmholtz_2D/d_init_Helmholtz_3D,float*fors_init_Helmholtz_2D/s_init_Helmholtz_3D.The coordinate of the leftmost boundary of the domain along the y-axis.
- by
- double*ford_init_Helmholtz_2D/d_init_Helmholtz_3D,float*fors_init_Helmholtz_2D/s_init_Helmholtz_3D.The coordinate of the rightmost boundary of the domain along the y-axis.
- az
- double*ford_init_Helmholtz_3D,float*fors_init_Helmholtz_3D.The coordinate of the leftmost boundary of the domain along the z-axis. This parameter is needed only for the?_init_Helmholtz_3Droutine.
- bz
- double*ford_init_Helmholtz_3D,float*fors_init_Helmholtz_3D.The coordinate of the rightmost boundary of the domain along the z-axis. This parameter is needed only for the?_init_Helmholtz_3Droutine.
- nx
- MKL_INT*. The number of mesh intervals along the x-axis.
- ny
- MKL_INT*. The number of mesh intervals along the y-axis.
- nz
- MKL_INT*. The number of mesh intervals along the z-axis. This parameter is needed only for the?_init_Helmholtz_3Droutine.
- BCtype
- char*. Contains the type of boundary conditions on each boundary. Must contain four characters for?_init_Helmholtz_2Dand six characters for?_init_Helmholtz_3D. Each of the characters can be 'N' (Neumann boundary condition), 'D' (Dirichlet boundary condition), or 'P' (periodic boundary conditions). Specify the types of boundary conditions for the boundaries in the following order:bd_a,xbd_b,xbd_a,ybd_b,ybd_a, andzbd_b. Specify periodic boundary conditions on the respective boundaries in pairs (for example, 'PPDD' or 'NNPP' in the 2D case). The types of boundary conditions for the last two boundaries are needed only in the 3D case.z
- q
- double*ford_init_Helmholtz_2D/d_init_Helmholtz_3D,float*fors_init_Helmholtz_2D/s_init_Helmholtz_3D.The constant Helmholtz coefficient. Note that to solve Poisson or Laplace problem, you should set the value ofqto 0.
Output Parameters
- ipar
- MKL_INTarray of size 128. Contains integer data to be used by Fast Helmholtz Solver (for details, refer toipar).
- dpar
- doublearray of size 5*nx/2+7 in the 2D case or 5*(nx+ny)/2+9 in the 3D case. Contains double-precision data to be used by Fast Helmholtz Solver (for details, refer todparandspar).
- spar
- floatarray of size 5*nx/2+7 in the 2D case or 5*(nx+ny)/2+9 in the 3D case. Contains single-precision data to be used by Fast Helmholtz Solver (for details, refer todparandspar).
- stat
- MKL_INT*. Routine completion status, which is also written toipar[0]. Continue to call other Poisson Solver routines only if the status is 0.
Description
The
?_init_Helmholtz_2D/?_init_Helmholtz_3D
routines initialize basic data structures for Poisson Solver computations of the appropriate precision. All routines invoked after a call to a ?_init_Helmholtz_2D/?_init_Helmholtz_3D
routine use values of the ipar
, dpar
and spar
array parameters returned by the routine. Detailed description of the array parameters can be found in Common Parameters. Data structures initialized and created by 2D flavors of the routine cannot be used by 3D flavors of any Poisson Solver routines, and vice versa.
You can skip calls to these routines in your code. However, see Caveat on Parameter Modifications for information on initializing the data structures.
Return Values
- stat= 0
- The routine successfully completed the task. In general, to proceed with computations, the routine should complete with thisstatvalue.
- stat= -99999
- The routine failed to complete the task because of a fatal error.