| Type | Intent | Optional | Attributes | Name | ||
|---|---|---|---|---|---|---|
| class(array_type), | intent(in) | :: | this | |||
| real(kind=real32), | intent(in), | dimension(:,:) | :: | upstream_grad | ||
| real(kind=real32), | intent(out), | dimension(:,:) | :: | output |
pure subroutine get_partial_tan_val(this, upstream_grad, output) implicit none class(array_type), intent(in) :: this real(real32), dimension(:,:), intent(in) :: upstream_grad real(real32), dimension(:,:), intent(out) :: output real(real32) :: cos_val integer :: i, s do concurrent(s = 1:size(upstream_grad,2), i = 1:size(upstream_grad,1)) cos_val = cos(this%left_operand%val(i,s)) output(i,s) = upstream_grad(i,s) / (cos_val * cos_val) end do end subroutine get_partial_tan_val