uniform_gradient_gradient Function

private function uniform_gradient_gradient(this) result(res)

Arguments

Type IntentOptional AttributesName
class(uniform_gradient_field), intent(in) :: this

Return Value class(vector_field), pointer

The result of this operation


Calls

proc~~uniform_gradient_gradient~~CallsGraph proc~uniform_gradient_gradient uniform_gradient_gradient uniform_vector_field uniform_vector_field proc~uniform_gradient_gradient->uniform_vector_field

Contents


Source Code

  function uniform_gradient_gradient(this) result(res)
    !* Author: Chris MacMackin
    !  Date: July 2017
    !
    ! \(\nabla{\rm field}\)
    !
    class(uniform_gradient_field), intent(in) :: this
    class(vector_field), pointer :: res !! The result of this operation
    call this%guard_temp()
    call this%allocate_vector_field(res)
    select type(res)
    class is(uniform_vector_field)
      res = uniform_vector_field(this%grad)
    class default
      error stop ('Non-uniform_vector_field type allocated by '//&
                  '`allocate_vector_field` routine.')
    end select
    call this%clean_temp()
  end function uniform_gradient_gradient