ViewVC Help
View File | Revision Log | Show Annotations | Download File | Root Listing
root/radiance/ray/src/cal/cal/klems_int.cal
(Generate patch)

Comparing ray/src/cal/cal/klems_int.cal (file contents):
Revision 1.5 by greg, Wed Jan 26 23:42:03 2011 UTC vs.
Revision 1.6 by greg, Mon Apr 11 03:47:46 2011 UTC

# Line 7 | Line 7
7          6/14/2009       G. Ward
8   }
9   DEGREE : PI/180;
10 < Acos(x) : 1/DEGREE * if(x-1, 0, if(-1-x, 0, acos(x)));
11 < posangle(a) : if(-a, a + 2*PI, a);
12 < Atan2(y,x) : 1/DEGREE * posangle(atan2(y,x));
10 > Acos(x) : if(x-1, 0, if(-1-x, 0, acos(x))) / DEGREE;
11 > posangle(a) : if(-a, a + 2*PI, a) / DEGREE;
12 > Atan2(y,x) : posangle(atan2(y,x));
13  
14   kpola(r) : select(r, 5, 15, 25, 35, 45, 55, 65, 75, 90);
15   knaz(r) : select(r, 1, 8, 16, 20, 24, 24, 24, 16, 12);
# Line 33 | Line 33 | kbin2(pol,azi) = select(kfindrow(1, pol),
33  
34   kbin(Nx,Ny,Nz,Ux,Uy,Uz) = kbin2(Acos(-Dx*Nx-Dy*Ny-Dz*Nz),
35          Atan2(-Dx*Ux-Dy*Uy-Dz*Uz,
36 <                -Dx*(Ny*Uz-Nz*Uy) - Dy*(Nz*Ux-Nx*Uz) - Dz*(Nx*Uy-Ny*Ux)));
36 >                -Dx*(Uy*Nz-Uz*Ny) - Dy*(Uz*Nx-Ux*Nz) - Dz*(Ux*Ny-Uy*Nx)));
37                                  
38   kbinN = kbin(0,-1,0, 0,0,1);    { North bins }
39   kbinE = kbin(-1,0,0, 0,0,1);    { East bins }

Diff Legend

Removed lines
+ Added lines
< Changed lines
> Changed lines