OB.DAAC Logo
NASA Logo
Ocean Color Science Software

ocssw V2022
euler.f
Go to the documentation of this file.
1  subroutine euler(a,xm)
2 c computes coordinate transformation matrix corresponding to euler
3 c sequence. the order of angles in the input array is yaw, roll,
4 c pitch; according to osc, the order of the rotations is the reverse
5 c of this; the roll and pitch angles are about the negative y and z
6 c axes, respectively, while the yaw angle is about the positive x axis.
7 
8 c reference: wertz, appendix e; osc, personal communication
9 
10 c calling arguments
11 
12 c name Type i/o description
13 c
14 c a(3) r*4 i input array of euler angles(degrees)
15 c xm(3,3) r*4 o output transformation matrix
16 c
17 c frederick s. patt, gsc, sometime in 1992.
18 c
19 c modification history:
20 c
21 c
22 c modified to change order of rotations to pitch, roll, yaw(-z, -y, -x)
23 c f. s. patt, gsc, september 29, 1996.
24 
25  real xm1(3,3),xm2(3,3),xm3(3,3),xm(3,3),xmm(3,3),a(3)
26  radeg = 180.d0/3.14159265359d0
27 
28 c initialize all matrix elements to zero.
29  do i=1,3
30  do j=1,3
31  xm1(i,j) = 0.d0
32  xm2(i,j) = 0.d0
33  xm3(i,j) = 0.d0
34  end do
35  end do
36 
37 c compute sines and cosines; use negative of y and z rotations
38  c1=cos(a(1)/radeg)
39  s1=sin(a(1)/radeg)
40  c2=cos(a(2)/radeg)
41  s2=-sin(a(2)/radeg)
42  c3=cos(a(3)/radeg)
43  s3=-sin(a(3)/radeg)
44 
45 c convert individual rotations to matrices
46  xm1(1,1)=1.d0
47  xm1(2,2)=c1
48  xm1(3,3)=c1
49  xm1(2,3)=s1
50  xm1(3,2)=-s1
51  xm2(2,2)=1.d0
52  xm2(1,1)=c2
53  xm2(3,3)=c2
54  xm2(3,1)=s2
55  xm2(1,3)=-s2
56  xm3(3,3)=1.d0
57  xm3(2,2)=c3
58  xm3(1,1)=c3
59  xm3(1,2)=s3
60  xm3(2,1)=-s3
61 
62 c compute total rotation as xm1*xm2*xm3
63  call matmpy(xm2,xm3,xmm)
64  call matmpy(xm1,xmm,xm)
65  return
66  end
void initialize(int pixref_flag, int blkref_flag)
Definition: Usds.c:1371
float ** matrix(long nrl, long nrh, long ncl, long nch)
Definition: nrutil.c:60
===========================================================================V5.0.48(Terra) 03/20/2015 Changes shown below are differences from MOD_PR02 V5.0.46(Terra)============================================================================Changes noted for V6.1.20(Terra) below were also instituted for this version.============================================================================V6.1.20(Terra) 03/12/2015 Changes shown below are differences from MOD_PR02 V6.1.18(Terra)============================================================================Changes from v6.1.18 which may affect scientific output:A situation can occur in which a scan which contains sector rotated data has a telemetry value indicating the completeness of the sector rotation. This issue is caused by the timing of the instrument command to perform the sector rotation and the recording of the telemetry point that reports the status of sector rotation. In this case a scan is considered valid by L1B and pass through the calibration - reporting extremely high radiances. Operationally the TEB calibration uses a 40 scan average coefficient, so the 20 scans(one mirror side) after the sector rotation are contaminated with anomalously high radiance values. A similar timing issue appeared before the sector rotation was fixed in V6.1.2. Our analysis indicates the ‘SET_FR_ENC_DELTA’ telemetry correlates well with the sector rotation encoder position. The use of this telemetry point to determine scans that are sector rotated should fix the anomaly occured before and after the sector rotation(usually due to the lunar roll maneuver). The fix related to the sector rotation in V6.1.2 is removed in this version.============================================================================V6.1.18(Terra) 10/01/2014 Changes shown below are differences from MOD_PR02 V6.1.16(Terra)============================================================================Added doi attributes to NRT(Near-Real-Time) product.============================================================================V6.1.16(Terra) 01/27/2014 Changes shown below are differences from MOD_PR02 V6.1.14(Terra)============================================================================Migrate to SDP Toolkit 5.2.17============================================================================V6.1.14(Terra) 06/26/2012 Changes shown below are differences from MOD_PR02 V6.1.12(Terra)============================================================================Added the doi metadata to L1B product============================================================================V6.1.12(Terra) 04/25/2011 Changes shown below are differences from MOD_PR02 V6.1.8(Terra)============================================================================1. The algorithm to calculate uncertainties for reflective solar bands(RSB) is updated. The current uncertainty in L1B code includes 9 terms from prelaunch analysis. The new algorithm regroups them with the new added contributions into 5 terms:u1:the common term(AOI and time independent) and
Definition: HISTORY.txt:126
void reverse(int iorder[], int ncity, int n[])
subroutine euler(a, xm)
Definition: euler.f:2
#define f
Definition: l1_czcs_hdf.c:702
subroutine matmpy(xm1, xm2, xm3)
Definition: ocorient.f:197
#define degrees(radians)
Definition: niwa_iop.c:30