mxvrot Subroutine

public pure subroutine mxvrot(xk, xl, ck, cl, ier)

plane rotation is applied to two values.

Arguments

Type IntentOptional Attributes Name
real(kind=wp), intent(inout) :: xk

first value for plane rotation.

real(kind=wp), intent(inout) :: xl

second value for plane rotation.

real(kind=wp), intent(in) :: ck

diagonal element of the elementary orthogonal matrix.

real(kind=wp), intent(in) :: cl

off-diagonal element of the elementary orthogonal matrix.

integer, intent(in) :: ier

information on the transformation:

  • ier=0-general plane rotation.
  • ier=1-permutation.
  • ier=2-transformation suppressed.

Called by

proc~~mxvrot~~CalledByGraph proc~mxvrot mxvrot proc~update_tri_decomp_orthogonal update_tri_decomp_orthogonal proc~update_tri_decomp_orthogonal->proc~mxvrot proc~ops_after_constr_deletion psqp_class%ops_after_constr_deletion proc~ops_after_constr_deletion->proc~update_tri_decomp_orthogonal proc~dual_range_space_quad_prog psqp_class%dual_range_space_quad_prog proc~dual_range_space_quad_prog->proc~ops_after_constr_deletion 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 mxvrot(xk,xl,ck,cl,ier)

      real(wp),intent(in) :: ck  !! diagonal element of the elementary orthogonal matrix.
      real(wp),intent(in) :: cl  !! off-diagonal element of the elementary orthogonal matrix.
      real(wp),intent(inout) :: xk  !! first value for plane rotation.
      real(wp),intent(inout) :: xl  !! second value for plane rotation.
      integer,intent(in) :: ier  !! information on the transformation:
                                 !!
                                 !! * ier=0-general plane rotation.
                                 !! * ier=1-permutation.
                                 !! * ier=2-transformation suppressed.

      real(wp) :: yk , yl

      if ( ier==0 ) then
         yk = xk
         yl = xl
         xk = ck*yk + cl*yl
         xl = cl*yk - ck*yl
      elseif ( ier==1 ) then
         yk = xk
         xk = xl
         xl = yk
      endif

      end subroutine mxvrot