@hebcal/noaa 0.8.8 → 0.8.10

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/README.md CHANGED
@@ -16,9 +16,7 @@ $ npm install @hebcal/noaa
16
16
  <dl>
17
17
  <dt><a href="#GeoLocation">GeoLocation</a></dt>
18
18
  <dd><p>A class that contains location information such as latitude and longitude required for astronomical calculations. The
19
- elevation field may not be used by some calculation engines and would be ignored if set. Check the documentation for
20
- specific implementations of the <a href="AstronomicalCalculator">AstronomicalCalculator</a> to see if elevation is calculated as part of the
21
- algorithm.</p>
19
+ elevation field may not be used by some calculation engines and would be ignored if set.</p>
22
20
  </dd>
23
21
  <dt><a href="#NOAACalculator">NOAACalculator</a></dt>
24
22
  <dd><p>Implementation of sunrise and sunset methods to calculate astronomical times based on the <a
@@ -37,9 +35,7 @@ href="http://en.wikipedia.org/wiki/Sunrise_equation">Wikipedia Sunrise Equation<
37
35
 
38
36
  ## GeoLocation
39
37
  A class that contains location information such as latitude and longitude required for astronomical calculations. The
40
- elevation field may not be used by some calculation engines and would be ignored if set. Check the documentation for
41
- specific implementations of the [AstronomicalCalculator](AstronomicalCalculator) to see if elevation is calculated as part of the
42
- algorithm.
38
+ elevation field may not be used by some calculation engines and would be ignored if set.
43
39
 
44
40
  **Kind**: global class
45
41
  **Version**: 1.1
@@ -54,7 +50,7 @@ algorithm.
54
50
  * [.getLocationName()](#GeoLocation+getLocationName) ⇒ <code>string</code> \| <code>null</code>
55
51
  * [.setLocationName(name)](#GeoLocation+setLocationName)
56
52
  * [.getTimeZone()](#GeoLocation+getTimeZone) ⇒ <code>string</code>
57
- * [.setTimeZone(timeZone)](#GeoLocation+setTimeZone)
53
+ * [.setTimeZone(timeZoneId)](#GeoLocation+setTimeZone)
58
54
 
59
55
  <a name="new_GeoLocation_new"></a>
60
56
 
@@ -86,7 +82,7 @@ Method to set the elevation in Meters <b>above </b> sea level.
86
82
 
87
83
  | Param | Type | Description |
88
84
  | --- | --- | --- |
89
- | elevation | <code>number</code> | The elevation to set in Meters. An IllegalArgumentException will be thrown if the value is a negative. |
85
+ | elevation | <code>number</code> | The elevation to set in Meters. An Error will be thrown if the value is a negative. |
90
86
 
91
87
  <a name="GeoLocation+getLatitude"></a>
92
88
 
@@ -119,19 +115,14 @@ Method to set the elevation in Meters <b>above </b> sea level.
119
115
  **Returns**: <code>string</code> - Returns the timeZone.
120
116
  <a name="GeoLocation+setTimeZone"></a>
121
117
 
122
- ### geoLocation.setTimeZone(timeZone)
123
- Method to set the TimeZone. If this is ever set after the GeoLocation is set in the
124
- [AstronomicalCalendar](AstronomicalCalendar), it is critical that
125
- [AstronomicalCalendar#getCalendar()](AstronomicalCalendar#getCalendar()).
126
- [setTimeZone(TimeZone)](java.util.Calendar#setTimeZone(TimeZone)) be called in order for the
127
- AstronomicalCalendar to output times in the expected offset. This situation will arise if the
128
- AstronomicalCalendar is ever [cloned](AstronomicalCalendar#clone()).
118
+ ### geoLocation.setTimeZone(timeZoneId)
119
+ Method to set the TimeZone.
129
120
 
130
121
  **Kind**: instance method of [<code>GeoLocation</code>](#GeoLocation)
131
122
 
132
123
  | Param | Type | Description |
133
124
  | --- | --- | --- |
134
- | timeZone | <code>string</code> | The timeZone to set. |
125
+ | timeZoneId | <code>string</code> | The timeZone to set. |
135
126
 
136
127
  <a name="NOAACalculator"></a>
137
128
 
@@ -147,7 +138,6 @@ to account for elevation. The algorithm can be found in the <a
147
138
  href="http://en.wikipedia.org/wiki/Sunrise_equation">Wikipedia Sunrise Equation</a> article.
148
139
 
149
140
  **Kind**: global class
150
- **See**: #setAstronomicalCalculator(AstronomicalCalculator) for changing the calculator class.
151
141
  **Author**: &copy; Eliyahu Hershfeld 2011 - 2019
152
142
 
153
143
  * [NOAACalculator](#NOAACalculator)
@@ -171,8 +161,8 @@ href="http://en.wikipedia.org/wiki/Sunrise_equation">Wikipedia Sunrise Equation<
171
161
  * [.getUTCSeaLevelSunset(zenith)](#NOAACalculator+getUTCSeaLevelSunset) ⇒ <code>number</code>
172
162
  * [.getElevationAdjustment(elevation)](#NOAACalculator+getElevationAdjustment) ⇒ <code>number</code>
173
163
  * [.adjustZenith(zenith, elevation)](#NOAACalculator+adjustZenith) ⇒ <code>number</code>
174
- * [.getUTCSunrise()](#NOAACalculator+getUTCSunrise)
175
- * [.getUTCSunset()](#NOAACalculator+getUTCSunset)
164
+ * [.getUTCSunrise(date, geoLocation, zenith, adjustForElevation)](#NOAACalculator+getUTCSunrise)
165
+ * [.getUTCSunset(date, geoLocation, zenith, adjustForElevation)](#NOAACalculator+getUTCSunset)
176
166
  * [.getTemporalHour(startOfDay, endOfDay)](#NOAACalculator+getTemporalHour) ⇒ <code>number</code>
177
167
  * [.getSunTransit(startOfDay, endOfDay)](#NOAACalculator+getSunTransit) ⇒ <code>Temporal.ZonedDateTime</code> \| <code>null</code>
178
168
  * [.getDateFromTime(time, isSunrise)](#NOAACalculator+getDateFromTime) ⇒ <code>Temporal.ZonedDateTime</code> \| <code>null</code>
@@ -188,8 +178,7 @@ href="http://en.wikipedia.org/wiki/Sunrise_equation">Wikipedia Sunrise Equation<
188
178
 
189
179
  ### new NOAACalculator(geoLocation, date)
190
180
  A constructor that takes in <a href="http://en.wikipedia.org/wiki/Geolocation">geolocation</a> information as a
191
- parameter. The default [AstronomicalCalculator](AstronomicalCalculator#getDefault()) used for solar
192
- calculations is the the [NOAACalculator](#NOAACalculator).
181
+ parameter.
193
182
 
194
183
 
195
184
  | Param | Type | Description |
@@ -201,12 +190,11 @@ calculations is the the [NOAACalculator](#NOAACalculator).
201
190
 
202
191
  ### noaaCalculator.getSunrise() ⇒ <code>Temporal.ZonedDateTime</code> \| <code>null</code>
203
192
  The getSunrise method Returns a `Date` representing the
204
- [elevation adjusted](AstronomicalCalculator#getElevationAdjustment(double)) sunrise time. The zenith used
205
- for the calculation uses [geometric zenith](#GEOMETRIC_ZENITH) of 90&deg; plus
206
- [AstronomicalCalculator#getElevationAdjustment(double)](AstronomicalCalculator#getElevationAdjustment(double)). This is adjusted by the
207
- [AstronomicalCalculator](AstronomicalCalculator) to add approximately 50/60 of a degree to account for 34 archminutes of refraction
208
- and 16 archminutes for the sun's radius for a total of [90.83333&deg;](AstronomicalCalculator#adjustZenith).
209
- See documentation for the specific implementation of the [AstronomicalCalculator](AstronomicalCalculator) that you are using.
193
+ [elevation adjusted](getElevationAdjustment) sunrise time. The zenith used
194
+ for the calculation uses [geometric zenith](GEOMETRIC_ZENITH) of 90&deg; plus
195
+ [getElevationAdjustment](getElevationAdjustment). This is adjusted
196
+ to add approximately 50/60 of a degree to account for 34 archminutes of refraction
197
+ and 16 archminutes for the sun's radius for a total of [90.83333&deg;](adjustZenith).
210
198
 
211
199
  **Kind**: instance method of [<code>NOAACalculator</code>](#NOAACalculator)
212
200
  **Returns**: <code>Temporal.ZonedDateTime</code> \| <code>null</code> - the `Date` representing the exact sunrise time. If the calculation can't be computed such as
@@ -214,15 +202,15 @@ See documentation for the specific implementation of the [AstronomicalCalculator
214
202
  does not set, a null will be returned. See detailed explanation on top of the page.
215
203
  **See**
216
204
 
217
- - AstronomicalCalculator#adjustZenith
218
- - #getSeaLevelSunrise()
219
- - AstronomicalCalendar#getUTCSunrise
205
+ - adjustZenith
206
+ - getSeaLevelSunrise()
207
+ - getUTCSunrise
220
208
 
221
209
  <a name="NOAACalculator+getSeaLevelSunrise"></a>
222
210
 
223
211
  ### noaaCalculator.getSeaLevelSunrise() ⇒ <code>Temporal.ZonedDateTime</code> \| <code>null</code>
224
212
  A method that returns the sunrise without [elevation
225
- adjustment](AstronomicalCalculator#getElevationAdjustment(double)). Non-sunrise and sunset calculations such as dawn and dusk, depend on the amount of visible light,
213
+ adjustment](getElevationAdjustment). Non-sunrise and sunset calculations such as dawn and dusk, depend on the amount of visible light,
226
214
  something that is not affected by elevation. This method returns sunrise calculated at sea level. This forms the
227
215
  base for dawn calculations that are calculated as a dip below the horizon before sunrise.
228
216
 
@@ -232,47 +220,47 @@ base for dawn calculations that are calculated as a dip below the horizon before
232
220
  where it does not set, a null will be returned. See detailed explanation on top of the page.
233
221
  **See**
234
222
 
235
- - AstronomicalCalendar#getSunrise
236
- - AstronomicalCalendar#getUTCSeaLevelSunrise
237
- - #getSeaLevelSunset()
223
+ - getSunrise
224
+ - getUTCSeaLevelSunrise
225
+ - getSeaLevelSunset()
238
226
 
239
227
  <a name="NOAACalculator+getBeginCivilTwilight"></a>
240
228
 
241
229
  ### noaaCalculator.getBeginCivilTwilight() ⇒ <code>Temporal.ZonedDateTime</code> \| <code>null</code>
242
- A method that returns the beginning of civil twilight (dawn) using a zenith of [96&deg;](#CIVIL_ZENITH).
230
+ A method that returns the beginning of civil twilight (dawn) using a zenith of [96&deg;](CIVIL_ZENITH).
243
231
 
244
232
  **Kind**: instance method of [<code>NOAACalculator</code>](#NOAACalculator)
245
233
  **Returns**: <code>Temporal.ZonedDateTime</code> \| <code>null</code> - The `Date` of the beginning of civil twilight using a zenith of 96&deg;. If the calculation
246
234
  can't be computed, null will be returned. See detailed explanation on top of the page.
247
- **See**: #CIVIL_ZENITH
235
+ **See**: CIVIL_ZENITH
248
236
  <a name="NOAACalculator+getBeginNauticalTwilight"></a>
249
237
 
250
238
  ### noaaCalculator.getBeginNauticalTwilight() ⇒ <code>Temporal.ZonedDateTime</code> \| <code>null</code>
251
- A method that returns the beginning of nautical twilight using a zenith of [102&deg;](#NAUTICAL_ZENITH).
239
+ A method that returns the beginning of nautical twilight using a zenith of [102&deg;](NAUTICAL_ZENITH).
252
240
 
253
241
  **Kind**: instance method of [<code>NOAACalculator</code>](#NOAACalculator)
254
242
  **Returns**: <code>Temporal.ZonedDateTime</code> \| <code>null</code> - The `Date` of the beginning of nautical twilight using a zenith of 102&deg;. If the
255
243
  calculation can't be computed null will be returned. See detailed explanation on top of the page.
256
- **See**: #NAUTICAL_ZENITH
244
+ **See**: NAUTICAL_ZENITH
257
245
  <a name="NOAACalculator+getBeginAstronomicalTwilight"></a>
258
246
 
259
247
  ### noaaCalculator.getBeginAstronomicalTwilight() ⇒ <code>Temporal.ZonedDateTime</code> \| <code>null</code>
260
- A method that returns the beginning of astronomical twilight using a zenith of [108&deg;](#ASTRONOMICAL_ZENITH).
248
+ A method that returns the beginning of astronomical twilight using a zenith of [108&deg;](ASTRONOMICAL_ZENITH).
261
249
 
262
250
  **Kind**: instance method of [<code>NOAACalculator</code>](#NOAACalculator)
263
251
  **Returns**: <code>Temporal.ZonedDateTime</code> \| <code>null</code> - The `Date` of the beginning of astronomical twilight using a zenith of 108&deg;. If the
264
252
  calculation can't be computed, null will be returned. See detailed explanation on top of the page.
265
- **See**: #ASTRONOMICAL_ZENITH
253
+ **See**: ASTRONOMICAL_ZENITH
266
254
  <a name="NOAACalculator+getSunset"></a>
267
255
 
268
256
  ### noaaCalculator.getSunset() ⇒ <code>Temporal.ZonedDateTime</code> \| <code>null</code>
269
257
  The getSunset method Returns a `Date` representing the
270
- [elevation adjusted](AstronomicalCalculator#getElevationAdjustment(double)) sunset time. The zenith used for
271
- the calculation uses [geometric zenith](#GEOMETRIC_ZENITH) of 90&deg; plus
272
- [AstronomicalCalculator#getElevationAdjustment(double)](AstronomicalCalculator#getElevationAdjustment(double)). This is adjusted by the
273
- [AstronomicalCalculator](AstronomicalCalculator) to add approximately 50/60 of a degree to account for 34 archminutes of refraction
274
- and 16 archminutes for the sun's radius for a total of [90.83333&deg;](AstronomicalCalculator#adjustZenith).
275
- See documentation for the specific implementation of the [AstronomicalCalculator](AstronomicalCalculator) that you are using. Note:
258
+ [elevation adjusted](getElevationAdjustment) sunset time. The zenith used for
259
+ the calculation uses [geometric zenith](GEOMETRIC_ZENITH) of 90&deg; plus
260
+ [getElevationAdjustment](getElevationAdjustment). This is adjusted
261
+ to add approximately 50/60 of a degree to account for 34 archminutes of refraction
262
+ and 16 archminutes for the sun's radius for a total of [90.83333&deg;](adjustZenith).
263
+ Note:
276
264
  In certain cases the calculates sunset will occur before sunrise. This will typically happen when a timezone
277
265
  other than the local timezone is used (calculating Los Angeles sunset using a GMT timezone for example). In this
278
266
  case the sunset date will be incremented to the following date.
@@ -283,15 +271,15 @@ case the sunset date will be incremented to the following date.
283
271
  does not set, a null will be returned. See detailed explanation on top of the page.
284
272
  **See**
285
273
 
286
- - AstronomicalCalculator#adjustZenith
287
- - #getSeaLevelSunset()
288
- - AstronomicalCalendar#getUTCSunset
274
+ - adjustZenith
275
+ - getSeaLevelSunset()
276
+ - getUTCSunset
289
277
 
290
278
  <a name="NOAACalculator+getSeaLevelSunset"></a>
291
279
 
292
280
  ### noaaCalculator.getSeaLevelSunset() ⇒ <code>Temporal.ZonedDateTime</code> \| <code>null</code>
293
281
  A method that returns the sunset without [elevation
294
- adjustment](AstronomicalCalculator#getElevationAdjustment(double)). Non-sunrise and sunset calculations such as dawn and dusk, depend on the amount of visible light,
282
+ adjustment](getElevationAdjustment). Non-sunrise and sunset calculations such as dawn and dusk, depend on the amount of visible light,
295
283
  something that is not affected by elevation. This method returns sunset calculated at sea level. This forms the
296
284
  base for dusk calculations that are calculated as a dip below the horizon after sunset.
297
285
 
@@ -301,69 +289,69 @@ base for dusk calculations that are calculated as a dip below the horizon after
301
289
  where it does not set, a null will be returned. See detailed explanation on top of the page.
302
290
  **See**
303
291
 
304
- - AstronomicalCalendar#getSunset
305
- - AstronomicalCalendar#getUTCSeaLevelSunset 2see [#getSunset()](#getSunset())
292
+ - getSunset
293
+ - getUTCSeaLevelSunset
306
294
 
307
295
  <a name="NOAACalculator+getEndCivilTwilight"></a>
308
296
 
309
297
  ### noaaCalculator.getEndCivilTwilight() ⇒ <code>Temporal.ZonedDateTime</code> \| <code>null</code>
310
- A method that returns the end of civil twilight using a zenith of [96&deg;](#CIVIL_ZENITH).
298
+ A method that returns the end of civil twilight using a zenith of [96&deg;](CIVIL_ZENITH).
311
299
 
312
300
  **Kind**: instance method of [<code>NOAACalculator</code>](#NOAACalculator)
313
- **Returns**: <code>Temporal.ZonedDateTime</code> \| <code>null</code> - The `Date` of the end of civil twilight using a zenith of [96&deg;](#CIVIL_ZENITH). If
301
+ **Returns**: <code>Temporal.ZonedDateTime</code> \| <code>null</code> - The `Date` of the end of civil twilight using a zenith of [96&deg;](CIVIL_ZENITH). If
314
302
  the calculation can't be computed, null will be returned. See detailed explanation on top of the page.
315
- **See**: #CIVIL_ZENITH
303
+ **See**: CIVIL_ZENITH
316
304
  <a name="NOAACalculator+getEndNauticalTwilight"></a>
317
305
 
318
306
  ### noaaCalculator.getEndNauticalTwilight() ⇒ <code>Temporal.ZonedDateTime</code> \| <code>null</code>
319
- A method that returns the end of nautical twilight using a zenith of [102&deg;](#NAUTICAL_ZENITH).
307
+ A method that returns the end of nautical twilight using a zenith of [102&deg;](NAUTICAL_ZENITH).
320
308
 
321
309
  **Kind**: instance method of [<code>NOAACalculator</code>](#NOAACalculator)
322
- **Returns**: <code>Temporal.ZonedDateTime</code> \| <code>null</code> - The `Date` of the end of nautical twilight using a zenith of [102&deg;](#NAUTICAL_ZENITH)
310
+ **Returns**: <code>Temporal.ZonedDateTime</code> \| <code>null</code> - The `Date` of the end of nautical twilight using a zenith of [102&deg;](NAUTICAL_ZENITH)
323
311
  . If the calculation can't be computed, null will be returned. See detailed explanation on top of the
324
312
  page.
325
- **See**: #NAUTICAL_ZENITH
313
+ **See**: NAUTICAL_ZENITH
326
314
  <a name="NOAACalculator+getEndAstronomicalTwilight"></a>
327
315
 
328
316
  ### noaaCalculator.getEndAstronomicalTwilight() ⇒ <code>Temporal.ZonedDateTime</code> \| <code>null</code>
329
- A method that returns the end of astronomical twilight using a zenith of [108&deg;](#ASTRONOMICAL_ZENITH).
317
+ A method that returns the end of astronomical twilight using a zenith of [108&deg;](ASTRONOMICAL_ZENITH).
330
318
 
331
319
  **Kind**: instance method of [<code>NOAACalculator</code>](#NOAACalculator)
332
- **Returns**: <code>Temporal.ZonedDateTime</code> \| <code>null</code> - The `Date` of the end of astronomical twilight using a zenith of [108&deg;](#ASTRONOMICAL_ZENITH). If the calculation can't be computed, null will be returned. See detailed explanation on top
320
+ **Returns**: <code>Temporal.ZonedDateTime</code> \| <code>null</code> - The `Date` of the end of astronomical twilight using a zenith of [108&deg;](ASTRONOMICAL_ZENITH). If the calculation can't be computed, null will be returned. See detailed explanation on top
333
321
  of the page.
334
- **See**: #ASTRONOMICAL_ZENITH
322
+ **See**: ASTRONOMICAL_ZENITH
335
323
  <a name="NOAACalculator+getSunriseOffsetByDegrees"></a>
336
324
 
337
325
  ### noaaCalculator.getSunriseOffsetByDegrees(offsetZenith) ⇒ <code>Temporal.ZonedDateTime</code> \| <code>null</code>
338
326
  A utility method that returns the time of an offset by degrees below or above the horizon of
339
- [sunrise](#getSunrise()). Note that the degree offset is from the vertical, so for a calculation of 14&deg;
340
- before sunrise, an offset of 14 + [#GEOMETRIC_ZENITH](#GEOMETRIC_ZENITH) = 104 would have to be passed as a parameter.
327
+ [sunrise](getSunrise()). Note that the degree offset is from the vertical, so for a calculation of 14&deg;
328
+ before sunrise, an offset of 14 + [GEOMETRIC_ZENITH](GEOMETRIC_ZENITH) = 104 would have to be passed as a parameter.
341
329
 
342
330
  **Kind**: instance method of [<code>NOAACalculator</code>](#NOAACalculator)
343
- **Returns**: <code>Temporal.ZonedDateTime</code> \| <code>null</code> - The `Date` of the offset after (or before) [#getSunrise()](#getSunrise()). If the calculation
331
+ **Returns**: <code>Temporal.ZonedDateTime</code> \| <code>null</code> - The `Date` of the offset after (or before) [getSunrise](getSunrise). If the calculation
344
332
  can't be computed such as in the Arctic Circle where there is at least one day a year where the sun does
345
333
  not rise, and one where it does not set, a null will be returned. See detailed explanation on top of the
346
334
  page.
347
335
 
348
336
  | Param | Type | Description |
349
337
  | --- | --- | --- |
350
- | offsetZenith | <code>number</code> | the degrees before [#getSunrise()](#getSunrise()) to use in the calculation. For time after sunrise use negative numbers. Note that the degree offset is from the vertical, so for a calculation of 14&deg; before sunrise, an offset of 14 + [#GEOMETRIC_ZENITH](#GEOMETRIC_ZENITH) = 104 would have to be passed as a parameter. |
338
+ | offsetZenith | <code>number</code> | the degrees before [getSunrise](getSunrise) to use in the calculation. For time after sunrise use negative numbers. Note that the degree offset is from the vertical, so for a calculation of 14&deg; before sunrise, an offset of 14 + [GEOMETRIC_ZENITH](GEOMETRIC_ZENITH) = 104 would have to be passed as a parameter. |
351
339
 
352
340
  <a name="NOAACalculator+getSunsetOffsetByDegrees"></a>
353
341
 
354
342
  ### noaaCalculator.getSunsetOffsetByDegrees(offsetZenith) ⇒ <code>Temporal.ZonedDateTime</code> \| <code>null</code>
355
- A utility method that returns the time of an offset by degrees below or above the horizon of [sunset](#getSunset()). Note that the degree offset is from the vertical, so for a calculation of 14&deg; after sunset, an
356
- offset of 14 + [#GEOMETRIC_ZENITH](#GEOMETRIC_ZENITH) = 104 would have to be passed as a parameter.
343
+ A utility method that returns the time of an offset by degrees below or above the horizon of [sunset](getSunset()). Note that the degree offset is from the vertical, so for a calculation of 14&deg; after sunset, an
344
+ offset of 14 + [GEOMETRIC_ZENITH](GEOMETRIC_ZENITH) = 104 would have to be passed as a parameter.
357
345
 
358
346
  **Kind**: instance method of [<code>NOAACalculator</code>](#NOAACalculator)
359
- **Returns**: <code>Temporal.ZonedDateTime</code> \| <code>null</code> - The `Date`of the offset after (or before) [#getSunset()](#getSunset()). If the calculation can't
347
+ **Returns**: <code>Temporal.ZonedDateTime</code> \| <code>null</code> - The `Date`of the offset after (or before) [getSunset](getSunset). If the calculation can't
360
348
  be computed such as in the Arctic Circle where there is at least one day a year where the sun does not
361
349
  rise, and one where it does not set, a null will be returned. See detailed explanation on top of the
362
350
  page.
363
351
 
364
352
  | Param | Type | Description |
365
353
  | --- | --- | --- |
366
- | offsetZenith | <code>number</code> | the degrees after [#getSunset()](#getSunset()) to use in the calculation. For time before sunset use negative numbers. Note that the degree offset is from the vertical, so for a calculation of 14&deg; after sunset, an offset of 14 + [#GEOMETRIC_ZENITH](#GEOMETRIC_ZENITH) = 104 would have to be passed as a parameter. |
354
+ | offsetZenith | <code>number</code> | the degrees after [getSunset](getSunset) to use in the calculation. For time before sunset use negative numbers. Note that the degree offset is from the vertical, so for a calculation of 14&deg; after sunset, an offset of 14 + [GEOMETRIC_ZENITH](GEOMETRIC_ZENITH) = 104 would have to be passed as a parameter. |
367
355
 
368
356
  <a name="NOAACalculator+getUTCSunrise0"></a>
369
357
 
@@ -374,7 +362,7 @@ daylight savings time.
374
362
  **Kind**: instance method of [<code>NOAACalculator</code>](#NOAACalculator)
375
363
  **Returns**: <code>number</code> - The time in the format: 18.75 for 18:45:00 UTC/GMT. If the calculation can't be computed such as in the
376
364
  Arctic Circle where there is at least one day a year where the sun does not rise, and one where it does
377
- not set, [Double#NaN](Double#NaN) will be returned. See detailed explanation on top of the page.
365
+ not set, `NaN` will be returned. See detailed explanation on top of the page.
378
366
 
379
367
  | Param | Type | Description |
380
368
  | --- | --- | --- |
@@ -391,11 +379,11 @@ forms the base for dawn calculations that are calculated as a dip below the hori
391
379
  **Kind**: instance method of [<code>NOAACalculator</code>](#NOAACalculator)
392
380
  **Returns**: <code>number</code> - The time in the format: 18.75 for 18:45:00 UTC/GMT. If the calculation can't be computed such as in the
393
381
  Arctic Circle where there is at least one day a year where the sun does not rise, and one where it does
394
- not set, [Double#NaN](Double#NaN) will be returned. See detailed explanation on top of the page.
382
+ not set, `NaN` will be returned. See detailed explanation on top of the page.
395
383
  **See**
396
384
 
397
- - AstronomicalCalendar#getUTCSunrise
398
- - AstronomicalCalendar#getUTCSeaLevelSunset
385
+ - getUTCSunrise
386
+ - getUTCSeaLevelSunset
399
387
 
400
388
 
401
389
  | Param | Type | Description |
@@ -411,8 +399,8 @@ daylight savings time.
411
399
  **Kind**: instance method of [<code>NOAACalculator</code>](#NOAACalculator)
412
400
  **Returns**: <code>number</code> - The time in the format: 18.75 for 18:45:00 UTC/GMT. If the calculation can't be computed such as in the
413
401
  Arctic Circle where there is at least one day a year where the sun does not rise, and one where it does
414
- not set, [Double#NaN](Double#NaN) will be returned. See detailed explanation on top of the page.
415
- **See**: AstronomicalCalendar#getUTCSeaLevelSunset
402
+ not set, `NaN` will be returned. See detailed explanation on top of the page.
403
+ **See**: getUTCSeaLevelSunset
416
404
 
417
405
  | Param | Type | Description |
418
406
  | --- | --- | --- |
@@ -430,11 +418,11 @@ sunset.
430
418
  **Kind**: instance method of [<code>NOAACalculator</code>](#NOAACalculator)
431
419
  **Returns**: <code>number</code> - The time in the format: 18.75 for 18:45:00 UTC/GMT. If the calculation can't be computed such as in the
432
420
  Arctic Circle where there is at least one day a year where the sun does not rise, and one where it does
433
- not set, [Double#NaN](Double#NaN) will be returned. See detailed explanation on top of the page.
421
+ not set, `NaN` will be returned. See detailed explanation on top of the page.
434
422
  **See**
435
423
 
436
- - AstronomicalCalendar#getUTCSunset
437
- - AstronomicalCalendar#getUTCSeaLevelSunrise
424
+ - getUTCSunset
425
+ - getUTCSeaLevelSunrise
438
426
 
439
427
 
440
428
  | Param | Type | Description |
@@ -447,9 +435,9 @@ sunset.
447
435
  Method to return the adjustment to the zenith required to account for the elevation. Since a person at a higher
448
436
  elevation can see farther below the horizon, the calculation for sunrise / sunset is calculated below the horizon
449
437
  used at sea level. This is only used for sunrise and sunset and not times before or after it such as
450
- [nautical twilight](AstronomicalCalendar#getBeginNauticalTwilight()) since those
438
+ [nautical twilight](getBeginNauticalTwilight()) since those
451
439
  calculations are based on the level of available light at the given dip below the horizon, something that is not
452
- affected by elevation, the adjustment should only made if the zenith == 90&deg; [adjusted](#adjustZenith)
440
+ affected by elevation, the adjustment should only made if the zenith == 90&deg; [adjusted](adjustZenith)
453
441
  for refraction and solar radius. The algorithm used is
454
442
 
455
443
  <pre>
@@ -481,50 +469,75 @@ Earth were without an atmosphere, true sunset and sunrise would correspond to a
481
469
  is not a point, and because the atmosphere refracts light, this 90&deg; zenith does not, in fact, correspond to
482
470
  true sunset or sunrise, instead the centre of the Sun's disk must lie just below the horizon for the upper edge
483
471
  to be obscured. This means that a zenith of just above 90&deg; must be used. The Sun subtends an angle of 16
484
- minutes of arc (this can be changed via the [#setSolarRadius(double)](#setSolarRadius(double)) method , and atmospheric refraction
485
- accounts for 34 minutes or so (this can be changed via the [#setRefraction(double)](#setRefraction(double)) method), giving a total
472
+ minutes of arc, and atmospheric refraction
473
+ accounts for 34 minutes or so, giving a total
486
474
  of 50 arcminutes. The total value for ZENITH is 90+(5/6) or 90.8333333&deg; for true sunrise/sunset. Since a
487
475
  person at an elevation can see blow the horizon of a person at sea level, this will also adjust the zenith to
488
476
  account for elevation if available. Note that this will only adjust the value if the zenith is exactly 90 degrees.
489
477
  For values below and above this no correction is done. As an example, astronomical twilight is when the sun is
490
478
  18&deg; below the horizon or [108&deg;
491
- below the zenith](AstronomicalCalendar#ASTRONOMICAL_ZENITH). This is traditionally calculated with none of the above mentioned adjustments. The same goes
479
+ below the zenith](ASTRONOMICAL_ZENITH). This is traditionally calculated with none of the above mentioned adjustments. The same goes
492
480
  for various <em>tzais</em> and <em>alos</em> times such as the
493
481
  [16.1&deg;](ZmanimCalendar#ZENITH_16_POINT_1) dip used in
494
- [ComplexZmanimCalendar#getAlos16Point1Degrees()](ComplexZmanimCalendar#getAlos16Point1Degrees()).
482
+ [ComplexZmanimCalendar#getAlos16Point1Degrees](ComplexZmanimCalendar#getAlos16Point1Degrees).
495
483
 
496
484
  **Kind**: instance method of [<code>NOAACalculator</code>](#NOAACalculator)
497
- **Returns**: <code>number</code> - The zenith adjusted to include the [sun's radius](#getSolarRadius), [refraction](#getRefraction) and [elevation](#getElevationAdjustment) adjustment. This will only be adjusted for
485
+ **Returns**: <code>number</code> - The zenith adjusted to include the sun's radius, refracton
486
+ and [elevation](getElevationAdjustment) adjustment. This will only be adjusted for
498
487
  sunrise and sunset (if the zenith == 90&deg;)
499
- **See**: #getElevationAdjustment(double)
488
+ **See**: getElevationAdjustment
500
489
 
501
490
  | Param | Type | Description |
502
491
  | --- | --- | --- |
503
- | zenith | <code>number</code> | the azimuth below the vertical zenith of 90&deg;. For sunset typically the [zenith](#adjustZenith) used for the calculation uses geometric zenith of 90&deg; and [adjusts](#adjustZenith) this slightly to account for solar refraction and the sun's radius. Another example would be [AstronomicalCalendar#getEndNauticalTwilight()](AstronomicalCalendar#getEndNauticalTwilight()) that passes [AstronomicalCalendar#NAUTICAL_ZENITH](AstronomicalCalendar#NAUTICAL_ZENITH) to this method. |
492
+ | zenith | <code>number</code> | the azimuth below the vertical zenith of 90&deg;. For sunset typically the [zenith](adjustZenith) used for the calculation uses geometric zenith of 90&deg; and [adjusts](adjustZenith) this slightly to account for solar refraction and the sun's radius. Another example would be [getEndNauticalTwilight](getEndNauticalTwilight) that passes [NAUTICAL_ZENITH](NAUTICAL_ZENITH) to this method. |
504
493
  | elevation | <code>number</code> | elevation in Meters. |
505
494
 
506
495
  <a name="NOAACalculator+getUTCSunrise"></a>
507
496
 
508
- ### noaaCalculator.getUTCSunrise()
497
+ ### noaaCalculator.getUTCSunrise(date, geoLocation, zenith, adjustForElevation)
498
+ A method that calculates UTC sunrise as well as any time based on an angle above or below sunrise.
499
+
509
500
  **Kind**: instance method of [<code>NOAACalculator</code>](#NOAACalculator)
510
- **See**: AstronomicalCalculator#getUTCSunrise(Calendar, GeoLocation, double, boolean)
501
+ **Returns**: The UTC time of sunrise in 24 hour format. 5:45:00 AM will return 5.75.0. If an error was encountered in
502
+ the calculation (expected behavior for some locations such as near the poles,
503
+ `NaN` will be returned.
504
+
505
+ | Param | Description |
506
+ | --- | --- |
507
+ | date | Used to calculate day of year. |
508
+ | geoLocation | The location information used for astronomical calculating sun times. |
509
+ | zenith | the azimuth below the vertical zenith of 90 degrees. for sunrise typically the [zenith](adjustZenith) used for the calculation uses geometric zenith of 90&deg; and [adjusts](adjustZenith) this slightly to account for solar refraction and the sun's radius. Another example would be [getBeginNauticalTwilight](getBeginNauticalTwilight) that passes [NAUTICAL_ZENITH](NAUTICAL_ZENITH) to this method. |
510
+ | adjustForElevation | Should the time be adjusted for elevation |
511
+
511
512
  <a name="NOAACalculator+getUTCSunset"></a>
512
513
 
513
- ### noaaCalculator.getUTCSunset()
514
+ ### noaaCalculator.getUTCSunset(date, geoLocation, zenith, adjustForElevation)
515
+ A method that calculates UTC sunset as well as any time based on an angle above or below sunset.
516
+
514
517
  **Kind**: instance method of [<code>NOAACalculator</code>](#NOAACalculator)
515
- **See**: AstronomicalCalculator#getUTCSunset(Calendar, GeoLocation, double, boolean)
518
+ **Returns**: The UTC time of sunset in 24 hour format. 5:45:00 AM will return 5.75.0. If an error was encountered in
519
+ the calculation (expected behavior for some locations such as near the poles,
520
+ `NaN` will be returned.
521
+
522
+ | Param | Description |
523
+ | --- | --- |
524
+ | date | Used to calculate day of year. |
525
+ | geoLocation | The location information used for astronomical calculating sun times. |
526
+ | zenith | the azimuth below the vertical zenith of 90&deg;. For sunset typically the [zenith](adjustZenith) used for the calculation uses geometric zenith of 90&deg; and [adjusts](adjustZenith) this slightly to account for solar refraction and the sun's radius. Another example would be [getEndNauticalTwilight](getEndNauticalTwilight) that passes [NAUTICAL_ZENITH](NAUTICAL_ZENITH) to this method. |
527
+ | adjustForElevation | Should the time be adjusted for elevation |
528
+
516
529
  <a name="NOAACalculator+getTemporalHour"></a>
517
530
 
518
531
  ### noaaCalculator.getTemporalHour(startOfDay, endOfDay) ⇒ <code>number</code>
519
532
  A utility method that will allow the calculation of a temporal (solar) hour based on the sunrise and sunset
520
533
  passed as parameters to this method. An example of the use of this method would be the calculation of a
521
- non-elevation adjusted temporal hour by passing in [sea level sunrise](#getSeaLevelSunrise()) and
522
- [sea level sunset](#getSeaLevelSunset()) as parameters.
534
+ non-elevation adjusted temporal hour by passing in [sea level sunrise](getSeaLevelSunrise()) and
535
+ [sea level sunset](getSeaLevelSunset()) as parameters.
523
536
 
524
537
  **Kind**: instance method of [<code>NOAACalculator</code>](#NOAACalculator)
525
538
  **Returns**: <code>number</code> - the <code>long</code> millisecond length of the temporal hour. If the calculation can't be computed a
526
- [Long#MIN_VALUE](Long#MIN_VALUE) will be returned. See detailed explanation on top of the page.
527
- **See**: #getTemporalHour()
539
+ `NaN` will be returned. See detailed explanation on top of the page.
540
+ **See**: getTemporalHour()
528
541
 
529
542
  | Param | Type | Description |
530
543
  | --- | --- | --- |