Function to calculate the double derivatives of a 2D array
Type | Intent | Optional | Attributes | Name | ||
---|---|---|---|---|---|---|
real(kind=R8), | intent(in), | dimension(1:nx, 1:ny) | :: | gradx |
derivative along x 2D array |
|
real(kind=R8), | intent(in), | dimension(1:nx, 1:ny) | :: | grady |
derivative along y 2D array |
|
integer(kind=I4), | intent(in) | :: | nx |
number of pixels along x |
||
integer(kind=I4), | intent(in) | :: | ny |
number of pixels along x |
||
real(kind=R8), | intent(in) | :: | dx |
x lag |
||
real(kind=R8), | intent(in) | :: | dy |
y lag |
||
real(kind=R8), | intent(out), | dimension(1:nx, 1:ny) | :: | gradxx |
double derivative along x, x 2D array |
|
real(kind=R8), | intent(out), | dimension(1:nx, 1:ny) | :: | gradyy |
double derivative along y, y 2D array |
|
real(kind=R8), | intent(out), | dimension(1:nx, 1:ny) | :: | gradxy |
double derivative along x, y 2D array |
subroutine gauss_curv(gradx, grady, nx, ny, dx, dy, gradxx, gradyy, gradxy) !================================================================================================ !! Function to calculate the double derivatives of a 2D array implicit none integer(kind=I4), intent(in ) :: nx !! *number of pixels along x* integer(kind=I4), intent(in ) :: ny !! *number of pixels along x* real (kind=R8), intent(in ) :: dx !! *x lag* real (kind=R8), intent(in ) :: dy !! *y lag* real (kind=R8), intent(in ), dimension(1:nx, 1:ny) :: gradx !! *derivative along x 2D array* real (kind=R8), intent(in ), dimension(1:nx, 1:ny) :: grady !! *derivative along y 2D array* real (kind=R8), intent(out), dimension(1:nx, 1:ny) :: gradxx !! *double derivative along x, x 2D array* real (kind=R8), intent(out), dimension(1:nx, 1:ny) :: gradyy !! *double derivative along y, y 2D array* real (kind=R8), intent(out), dimension(1:nx, 1:ny) :: gradxy !! *double derivative along x, y 2D array* call gradient(tab = gradx (1:nx, 1:ny), & ! IN gradx = gradxx(1:nx, 1:ny), & ! OUT grady = gradxy(1:nx, 1:ny), & ! OUT nx = nx, & ! IN ny = ny, & ! IN dx = dx, & ! IN dy = dy) ! IN call gradient(tab = grady (1:nx, 1:ny), & !IN gradx = gradxy(1:nx, 1:ny), & !OUT grady = gradyy(1:nx, 1:ny), & !OUT nx = nx, & !IN ny = ny, & !IN dx = dx, & !IN dy = dy) !IN return endsubroutine gauss_curv