| 1 |
greg |
1.1 |
{ RCSid $Id$ } |
| 2 |
|
|
|
| 3 |
|
|
{ |
| 4 |
|
|
All-weather Angular Sky Luminance Distribution . |
| 5 |
|
|
|
| 6 |
|
|
Additional arguments required for calculation of skybright: |
| 7 |
|
|
|
| 8 |
|
|
A1 - diffus normalization |
| 9 |
|
|
A2 - ground brightness |
| 10 |
|
|
A3,A4,A5,A6,A7 - coefficients for the Perez model |
| 11 |
|
|
A8,A9,A10 - sun direction |
| 12 |
|
|
} |
| 13 |
|
|
|
| 14 |
|
|
|
| 15 |
|
|
|
| 16 |
|
|
|
| 17 |
|
|
skybright = wmean((Dz+1.01)^10, intersky, (Dz+1.01)^-10, A2 ); |
| 18 |
|
|
|
| 19 |
|
|
wmean(a, x, b, y) = (a*x+b*y)/(a+b); |
| 20 |
|
|
|
| 21 |
|
|
intersky = if( (Dz-0.01), |
| 22 |
|
|
A1 * (1 + A3*Exp(A4/Dz) ) * ( 1 + A5*Exp(A6*gamma) + A7*cos(gamma)*cos(gamma) ), |
| 23 |
|
|
A1 * (1 + A3*Exp(A4/0.01) ) * ( 1 + A5*Exp(A6*gamma) + A7*cos(gamma)*cos(gamma) ) ); |
| 24 |
|
|
|
| 25 |
|
|
|
| 26 |
|
|
|
| 27 |
|
|
|
| 28 |
|
|
cosgamma = Dx*A8 + Dy*A9 + Dz*A10; |
| 29 |
|
|
|
| 30 |
|
|
gamma = Acos(cosgamma); { angle from sun to this point in sky } |
| 31 |
|
|
|
| 32 |
|
|
zt = Acos(A10); { angle from zenith to sun } |
| 33 |
|
|
|
| 34 |
|
|
eta = Acos(Dz); { angle from zenith to this point in sky } |