Sunday, October 21, 2018

HP 11C (and Emulators): Sun's Approximate Declination, Altitude, and Azimuth

HP 11C (and Emulators):  Sun's Approximate Declination, Altitude, and Azimuth

Introduction

The following program calculates three positions for our Sun in our Solar System:

1.  Declination of the Sun (δ = 0° at the Equinoxes)
2.  Altitude of the Sun (height of the sun)
3.  Azimuth of the Sun (degree from latitude ground-wise north)
 
Formulas Used:

Inputs:
D = days after the vernal equinox (usually March 20 or March 21)
L = latitude given in D.MMSS format (avoid ±90°)
T = time before solar noon (12 PM).  Example: 9 AM, T= 3.  3 PM, T = -3.

Declination:
δ = 23.45 * sin(D * 0.9856)

Altitude:
H = asin(cos L * cos D * cos(15 * T)) + sin L * sin D)

Azimuth:
A = acos((sin H * sin L - sin D) / (cos L * cos H))

Before running the program, store D in R1, L in R2, and T in R3.

HP 11C Program: Sun Declination, Altitude, Azimuth

001 42, 21, 13 LBL C
002 43, 7 DEG
003 45, 1 RCL 1
004 48 .
005 9 9
006 8 8
007 5 5
008 6 6
009 20 ×
010 23 SIN
011 2 2
012 3 3
013 48 .
014 4 4
015 5 5
016 20 ×
017 44, 4 STO 4
018 31 R/S
019 24 COS
020 45, 2 RCL 2
021 43, 2 →H
022 24 COS
023 20 ×
024 45, 3 RCL 3
025 1 1
026 5 5
027 20 ×
028 24 COS
029 20 ×
030 45, 2 RCL 2
031 43, 2 →H
032 23 SIN
033 45, 4 RCL 4
034 23 SIN
035 20 ×
036 40 +
037 43, 23 ASIN
038 44, 5 STO 5
039 31 R/S
040 23 SIN
041 45, 2 RCL 2
042 43, 2 →H
043 23 SIN
044 20 ×
045 45, 4 RCL 4
046 23 SIN
047 30 -
048 45, 2 RCL 2
049 43, 2 →H
050 24 COS
051 45, 5 RCL 5
052 24 COS
053 20 ×
054 10 ÷
055 43, 24 ACOS
056 44, 6 STO 6
057 43,32 RTN


Example 1:
Stored Data: 
R0 = 184 (approximately September 21),
R1 = -14° 50' 12" (entered as -14.5012)
R2 = 0 (noon)

Output:
δ ≈ 13.1576°
H ≈ 62.0058°
A = 180.0000°

Example 2:
Stored Data: 
R0 = 68 
R1 = 46°
R2 = 4 (8 AM)

Output:
δ ≈ 21.5892°
H ≈ 35.9899°
A ≈ 84.4083°

Sources:

Hewlett Packard.  "Sun Altitude, Azimuth, Solar Pond Absorption", HP 67/97 Energy Conservation December 1978.
Shore, Edward.  "HP 35S: Sun Altitude, Azimuth, Solar Pond Absorption"  Eddie's Math and Calculator Blog:  http://edspi31415.blogspot.com/2013/06/hp-35s-sun-altitude-azimuth-solar-pond.html  June 7, 2013

Eddie

All original content copyright, © 2011-2018.  Edward Shore.   Unauthorized use and/or unauthorized distribution for commercial purposes without express and written permission from the author is strictly prohibited.  This blog entry may be distributed for noncommercial purposes, provided that full credit is given to the author.  Please contact the author if you have questions.

Spotlight: Sharp EL-5200

  Spotlight: Sharp EL-5200 As we come on the 13 th (April 16) anniversary of this blog, I want to thank you. Blogging about mathematic...