grad_2d Subroutine

public subroutine grad_2d(x, y, u, dudx, dudy, undef)

Calculate gradient of "u" in two dimensions based on the 2nd order central differential approximation:

Arguments

Type IntentOptional Attributes Name
double precision, intent(in) :: x(:)

Axis point 1

double precision, intent(in) :: y(:)

Axis point 2

double precision, intent(in) :: u(size(x),size(y))
double precision, intent(out) :: dudx(size(x),size(y))
double precision, intent(out) :: dudy(size(x),size(y))
double precision, intent(in), optional :: undef