mxdsmv Subroutine

public pure subroutine mxdsmv(n, a, x, k)

k-th row of a dense symmetric matrix a is copied to the vector x.

Arguments

Type IntentOptional Attributes Name
integer, intent(in) :: n

order of the matrix a.

real(kind=wp), intent(in) :: a(*)

a(n*(n+1)/2) dense symmetric matrix stored in the packed form.

real(kind=wp), intent(out) :: x(*)

x(n) output vector.

integer, intent(in) :: k

index of copied row.


Called by

proc~~mxdsmv~~CalledByGraph proc~mxdsmv mxdsmv proc~update_tri_decomp_general update_tri_decomp_general proc~update_tri_decomp_general->proc~mxdsmv proc~dual_range_space_quad_prog psqp_class%dual_range_space_quad_prog proc~dual_range_space_quad_prog->proc~update_tri_decomp_general proc~psqp psqp_class%psqp proc~psqp->proc~dual_range_space_quad_prog proc~psqpn psqp_class%psqpn proc~psqpn->proc~psqp

Source Code

      pure subroutine mxdsmv(n,a,x,k)

      integer,intent(in) :: k      !! index of copied row.
      integer,intent(in) :: n      !! order of the matrix a.
      real(wp),intent(in) :: a(*)  !! `a(n*(n+1)/2)`  dense symmetric matrix
                                   !! stored in the packed form.
      real(wp),intent(out) :: x(*)  !! x(n)  output vector.

      integer :: i , l

      l = k*(k-1)/2
      do i = 1 , n
         if ( i<=k ) then
            l = l + 1
         else
            l = l + i - 1
         endif
         x(i) = a(l)
      end do

      end subroutine mxdsmv