Initialize the 3D integration class. Must be called before integration is performed.
Type | Intent | Optional | Attributes | Name | ||
---|---|---|---|---|---|---|
class(integration_class_3d), | intent(inout) | :: | me | |||
procedure(func_3d) | :: | fxyz | 3d function: f(x,y,z) |
|||
real(kind=wp), | intent(in) | :: | xl | x integration lower bound |
||
real(kind=wp), | intent(in) | :: | xu | x integration upper bound |
||
real(kind=wp), | intent(in) | :: | yl | y integration lower bound |
||
real(kind=wp), | intent(in) | :: | yu | y integration upper bound |
||
real(kind=wp), | intent(in) | :: | zl | z integration lower bound |
||
real(kind=wp), | intent(in) | :: | zu | z integration upper bound |
||
real(kind=wp), | intent(in) | :: | tolx | error tolerance for dx integration |
||
real(kind=wp), | intent(in) | :: | toly | error tolerance for dy integration |
||
real(kind=wp), | intent(in) | :: | tolz | error tolerance for dz integration |
||
integer, | intent(in) | :: | methodx | quadrature method to use for x |
||
integer, | intent(in) | :: | methody | quadrature method to use for y |
||
integer, | intent(in) | :: | methodz | quadrature method to use for z |
subroutine initialize_integration_class_3d(me,fxyz,&
xl,xu,yl,yu,zl,zu,&
tolx,toly,tolz,&
methodx,methody,methodz)
implicit none
class(integration_class_3d),intent(inout) :: me
procedure(func_3d) :: fxyz !! 3d function: f(x,y,z)
real(wp),intent(in) :: xl !! x integration lower bound
real(wp),intent(in) :: xu !! x integration upper bound
real(wp),intent(in) :: yl !! y integration lower bound
real(wp),intent(in) :: yu !! y integration upper bound
real(wp),intent(in) :: zl !! z integration lower bound
real(wp),intent(in) :: zu !! z integration upper bound
real(wp),intent(in) :: tolx !! error tolerance for dx integration
real(wp),intent(in) :: toly !! error tolerance for dy integration
real(wp),intent(in) :: tolz !! error tolerance for dz integration
integer,intent(in) :: methodx !! quadrature method to use for x
integer,intent(in) :: methody !! quadrature method to use for y
integer,intent(in) :: methodz !! quadrature method to use for z
procedure(func_1d),pointer :: dummy => null() !! these will be set in [[integrate_3d]]
me%fxyz => fxyz !the user-defined f(x,y,z) function to integrate
! individual integrators:
call me%ix%initialize(dummy,xl,xu,tolx,methodx)
call me%iy%initialize(dummy,yl,yu,toly,methody)
call me%iz%initialize(dummy,zl,zu,tolz,methodz)
end subroutine initialize_integration_class_3d