RY Subroutine

public subroutine RY(theta, r)

Rotate an r-matrix about the y-axis.

Status: vector/matrix support routine.

Notes

  1. Calling this routine with positive THETA incorporates in the supplied r-matrix R an additional rotation, about the y-axis, anticlockwise as seen looking towards the origin from positive y.

  2. The additional rotation can be represented by this matrix:

         (  + cos(THETA)     0      - sin(THETA)  )
         (                                        )
         (       0           1           0        )
         (                                        )
         (  + sin(THETA)     0      + cos(THETA)  )

History

  • IAU SOFA revision: 2012 April 3

Arguments

TypeIntentOptionalAttributesName
real(kind=wp), intent(in) :: theta

angle (radians)

real(kind=wp), intent(out), dimension(3,3):: r

r-matrix, rotated


Called by

proc~~ry~~CalledByGraph proc~ry RY proc~bp00 BP00 proc~bp00->proc~ry proc~pom00 POM00 proc~pom00->proc~ry proc~c2ixys C2IXYS proc~c2ixys->proc~ry proc~pmat76 PMAT76 proc~pmat76->proc~ry proc~pn00 PN00 proc~pn00->proc~bp00 proc~pvtob PVTOB proc~pvtob->proc~pom00 proc~c2t00a C2T00A proc~c2t00a->proc~pom00 proc~c2i00a C2I00A proc~c2t00a->proc~c2i00a proc~c2txy C2TXY proc~c2txy->proc~pom00 proc~c2ixy C2IXY proc~c2txy->proc~c2ixy proc~c2i06a C2I06A proc~c2i06a->proc~c2ixys proc~pnm80 PNM80 proc~pnm80->proc~pmat76 proc~pmat00 PMAT00 proc~pmat00->proc~bp00 proc~c2tpe C2TPE proc~c2tpe->proc~pom00 proc~c2tpe->proc~pn00 proc~c2t06a C2T06A proc~c2t06a->proc~pom00 proc~c2t06a->proc~c2i06a proc~c2t00b C2T00B proc~c2t00b->proc~pom00 proc~c2i00b C2I00B proc~c2t00b->proc~c2i00b proc~apci APCI proc~apci->proc~c2ixys proc~apco APCO proc~apco->proc~c2ixys proc~apco->proc~pvtob proc~c2ixy->proc~c2ixys proc~pn00a PN00A proc~pn00a->proc~pn00 proc~apco13 APCO13 proc~apco13->proc~apco proc~apio APIO proc~apio->proc~pvtob proc~c2ibpn C2IBPN proc~c2ibpn->proc~c2ixy proc~apci13 APCI13 proc~apci13->proc~apci proc~pn00b PN00B proc~pn00b->proc~pn00 proc~atco13 ATCO13 proc~atco13->proc~apco13 proc~num00a NUM00A proc~num00a->proc~pn00a proc~atci13 ATCI13 proc~atci13->proc~apci13 proc~atic13 ATIC13 proc~atic13->proc~apci13 proc~pnm00a PNM00A proc~pnm00a->proc~pn00a proc~apio13 APIO13 proc~apio13->proc~apio proc~atoc13 ATOC13 proc~atoc13->proc~apco13 proc~c2i00a->proc~c2ibpn proc~c2i00a->proc~pnm00a proc~c2i00b->proc~c2ibpn proc~pnm00b PNM00B proc~c2i00b->proc~pnm00b proc~pnm00b->proc~pn00b proc~num00b NUM00B proc~num00b->proc~pn00b proc~atoi13 ATOI13 proc~atoi13->proc~apio13 proc~xys00a XYS00A proc~xys00a->proc~pnm00a proc~atio13 ATIO13 proc~atio13->proc~apio13 proc~s00a S00A proc~s00a->proc~pnm00a proc~s00b S00B proc~s00b->proc~pnm00b proc~xys00b XYS00B proc~xys00b->proc~pnm00b

Contents

Source Code

RY

Source Code

    subroutine RY ( theta, r )

    implicit none

    real(wp),intent(in) :: theta !! angle (radians)
    real(wp),dimension(3,3),intent(out) :: r !! r-matrix, rotated

    real(wp) :: s, c, a11, a12, a13, a31, a32, a33

    s = sin(theta)
    c = cos(theta)

    a11 = c*r(1,1) - s*r(3,1)
    a12 = c*r(1,2) - s*r(3,2)
    a13 = c*r(1,3) - s*r(3,3)
    a31 = s*r(1,1) + c*r(3,1)
    a32 = s*r(1,2) + c*r(3,2)
    a33 = s*r(1,3) + c*r(3,3)

    r(1,1) = a11
    r(1,2) = a12
    r(1,3) = a13
    r(3,1) = a31
    r(3,2) = a32
    r(3,3) = a33

    end subroutine RY