Compute the transformation matrices to convert RSW to IJK.
Type | Intent | Optional | Attributes | Name | ||
---|---|---|---|---|---|---|
real(kind=wp), | intent(in), | dimension(3) | :: | r |
position vector of target [km] |
|
real(kind=wp), | intent(in), | dimension(3) | :: | v |
velocity vector of target [km/s] |
|
real(kind=wp), | intent(in), | optional, | dimension(3) | :: | a |
acceleration vector of target [km/s^2] (if not present, then a torque-free force model is assumed) |
real(kind=wp), | intent(out), | dimension(3,3) | :: | c |
C transformation matrix |
|
real(kind=wp), | intent(out), | optional, | dimension(3,3) | :: | cdot |
CDOT transformation matrix |
subroutine from_rsw_to_ijk_mat(r,v,a,c,cdot) use vector_module, only: unit, cross implicit none real(wp),dimension(3),intent(in) :: r !! position vector of target [km] real(wp),dimension(3),intent(in) :: v !! velocity vector of target [km/s] real(wp),dimension(3),intent(in),optional :: a !! acceleration vector of target [km/s^2] !! (if not present, then a torque-free force model is assumed) real(wp),dimension(3,3),intent(out) :: c !! C transformation matrix real(wp),dimension(3,3),intent(out),optional :: cdot !! CDOT transformation matrix call from_ijk_to_rsw(r,v,a,c,cdot) c = transpose(c) if (present(cdot)) cdot = transpose(cdot) end subroutine from_rsw_to_ijk_mat