dbcsr_set_block_pointer_any Subroutine

private subroutine dbcsr_set_block_pointer_any(matrix, pointer_any, rsize, csize, main_tr, base_offset)

Sets a pointer, possibly using the buffers.

Arguments

Type IntentOptional Attributes Name
type(dbcsr_type), intent(in) :: matrix

Matrix to use

type(dbcsr_data_obj), intent(inout) :: pointer_any

The pointer to set

integer, intent(in) :: rsize

Row sizes of block to point to Column sizes of block to point to

integer, intent(in) :: csize

Row sizes of block to point to Column sizes of block to point to

logical, intent(in) :: main_tr

Whether block is transposed in the matrix

integer, intent(in) :: base_offset

The block pointer


Source Code

   SUBROUTINE dbcsr_set_block_pointer_any(matrix, pointer_any, &
                                          rsize, csize, main_tr, base_offset)
      !! Sets a pointer, possibly using the buffers.

      TYPE(dbcsr_type), INTENT(IN)                       :: matrix
         !! Matrix to use
      TYPE(dbcsr_data_obj), INTENT(INOUT)                :: pointer_any
         !! The pointer to set
      INTEGER, INTENT(IN)                                :: rsize, csize
         !! Row sizes of block to point to
         !! Column sizes of block to point to
      LOGICAL, INTENT(IN)                                :: main_tr
         !! Whether block is transposed in the matrix
      INTEGER, INTENT(IN)                                :: base_offset
         !! The block pointer

!   ---------------------------------------------------------------------------

      IF (main_tr) THEN
         CALL dbcsr_data_set_pointer(pointer_any, csize, rsize, &
                                     matrix%data_area, source_lb=base_offset)
      ELSE
         CALL dbcsr_data_set_pointer(pointer_any, rsize, csize, &
                                     matrix%data_area, source_lb=base_offset)
      END IF
   END SUBROUTINE dbcsr_set_block_pointer_any