import 'temporal-polyfill/global';
/**
* A class that contains location information such as latitude and longitude required for astronomical calculations. The
* elevation field may not be used by some calculation engines and would be ignored if set.
*
* @author © Eliyahu Hershfeld 2004 - 2016
* @version 1.1
*/
export declare class GeoLocation {
/**
* GeoLocation constructor with parameters for all required fields.
*
* @param {string} name
* The location name for display use such as "Lakewood, NJ"
* @param {number} latitude
* the latitude in a double format such as 40.095965 for Lakewood, NJ.
* Note: For latitudes south of the equator, a negative value should be used.
* @param {number} longitude
* double the longitude in a double format such as -74.222130 for Lakewood, NJ.
* Note: For longitudes west of the Prime
* Meridian (Greenwich), a negative value should be used.
* @param {number} elevation
* the elevation above sea level in Meters. Elevation is not used in most algorithms used for calculating
* sunrise and set.
* @param {string} timeZoneId
* the TimeZone for the location.
*/
constructor(name: string | null, latitude: number, longitude: number, elevation: number, timeZoneId: string);
protected latitude: number;
protected longitude: number;
protected locationName: string | null;
protected timeZoneId: string;
protected elevation: number;
/**
* Method to get the elevation in Meters.
*
* @return {number} Returns the elevation in Meters.
*/
getElevation(): number;
/**
* Method to set the elevation in Meters above sea level.
*
* @param {number} elevation
* The elevation to set in Meters. An Error will be thrown if the value is a negative.
*/
setElevation(elevation: number): void;
setLatitude(latitude: number): void;
/**
* @return {number} Returns the latitude.
*/
getLatitude(): number;
setLongitude(longitude: number): void;
/**
* @return {number} Returns the longitude.
*/
getLongitude(): number;
/**
* @return {string|null} Returns the location name.
*/
getLocationName(): string | null;
/**
* @param {string|null} name
* The setter method for the display name.
*/
setLocationName(name: string | null): void;
/**
* @return {string} Returns the timeZone.
*/
getTimeZone(): string;
/**
* Method to set the TimeZone.
* @param {string} timeZoneId
* The timeZone to set.
*/
setTimeZone(timeZoneId: string): void;
/**
* A method that will return the location's local mean time offset in milliseconds from local
* [standard time](https://en.wikipedia.org/wiki/Standard_time). The globe is split into 360°, with
* 15° per hour of the day. For a local that is at a longitude that is evenly divisible by 15
* (longitude % 15 == 0), at solar noon (with adjustment for the
* [equation of time](https://en.wikipedia.org/wiki/Equation_of_time)) the sun should be directly overhead,
* so a user who is 1° west of this will have noon at 4 minutes after standard time noon, and conversely,
* a user who is 1° east of the 15° longitude will have noon at 11:56 AM.
* @param instant the instant at which to read the time zone offset (DST is taken into account)
* @return the offset in milliseconds not accounting for Daylight saving time. A positive value will be returned
* East of the 15° timezone line, and a negative value West of it.
*/
getLocalMeanTimeOffset(instant: Temporal.Instant): number;
/**
* Adjust the date for [antimeridian](https://en.wikipedia.org/wiki/180th_meridian) crossover. This is
* needed to deal with edge cases such as Samoa that use a different calendar date than expected based on their
* geographic location.
*
* The actual Time Zone offset may deviate from the expected offset based on the longitude. Since the 'absolute time'
* calculations are always based on longitudinal offset from UTC for a given date, the date is presumed to only
* increase East of the Prime Meridian, and to only decrease West of it. For Time Zones that cross the antimeridian,
* the date will be artificially adjusted before calculation to conform with this presumption.
*
* For example, Apia, Samoa with a longitude of -171.75 uses a local offset of +14:00. When calculating sunrise for
* 2018-02-03, the calculator should operate using 2018-02-02 since the expected zone is -11. After determining the
* UTC time, the local DST offset of [UTC+14:00](https://en.wikipedia.org/wiki/UTC%2B14:00) should be applied
* to bring the date back to 2018-02-03.
* @param date the date, at the start of which (in this location's time zone) the offset is read
* @return the number of days to adjust the date This will typically be 0 unless the date crosses the antimeridian
*/
getAntimeridianAdjustment(date: Temporal.PlainDate): number;
}
/**
* Implementation of sunrise and sunset methods to calculate astronomical times based on the NOAA algorithm. This calculator uses the Java algorithm based on the implementation by NOAA - National Oceanic and Atmospheric Administration's Surface Radiation Research Branch. NOAA's implementation is based on equations from Astronomical Algorithms by Jean Meeus. Added to the algorithm is an adjustment of the zenith
* to account for elevation. The algorithm can be found in the Wikipedia Sunrise Equation article.
*
* @author © Eliyahu Hershfeld 2011 - 2019
*/
export declare class NOAACalculator {
/**
* A constructor that takes in geolocation information as a
* parameter.
*
* @param {GeoLocation} geoLocation
* The location information used for calculating astronomical sun times.
* @param {Temporal.PlainDate} date
*/
constructor(geoLocation: GeoLocation, date: Temporal.PlainDate);
/**
* The zenith of astronomical sunrise and sunset. The sun is 90° from the vertical 0°
* @private
*/
protected static readonly GEOMETRIC_ZENITH: number;
/**
* Default value for Sun's zenith and true rise/set Zenith (used in this class and subclasses) is the angle that the
* center of the Sun makes to a line perpendicular to the Earth's surface. If the Sun were a point and the Earth
* were without an atmosphere, true sunset and sunrise would correspond to a 90° zenith. Because the Sun is not
* a point, and because the atmosphere refracts light, this 90° zenith does not, in fact, correspond to true
* sunset or sunrise, instead the center of the Sun's disk must lie just below the horizon for the upper edge to be
* obscured. This means that a zenith of just above 90° must be used. The Sun subtends an angle of 16 minutes of
* arc, and atmospheric refraction accounts for
* 34 minutes or so, giving a total of 50
* arcminutes. The total value for ZENITH is 90+(5/6) or 90.8333333° for true sunrise/sunset.
*/
/** Sun's zenith at civil twilight (96°). */
static readonly CIVIL_ZENITH: number;
/** Sun's zenith at nautical twilight (102°). */
static readonly NAUTICAL_ZENITH: number;
/** Sun's zenith at astronomical twilight (108°). */
static readonly ASTRONOMICAL_ZENITH: number;
/**
* The Java Calendar encapsulated by this class to track the current date used by the class
* @private
*/
private readonly date;
/**
* the {@link GeoLocation} used for calculations.
* @private
*/
private readonly geoLocation;
/**
* The getSunrise method Returns a `Date` representing the
* {@link getElevationAdjustment elevation adjusted} sunrise time. The zenith used
* for the calculation uses {@link GEOMETRIC_ZENITH geometric zenith} of 90° plus
* {@link getElevationAdjustment}. This is adjusted
* to add approximately 50/60 of a degree to account for 34 archminutes of refraction
* and 16 archminutes for the sun's radius for a total of {@link adjustZenith 90.83333°}.
*
* @return {Temporal.ZonedDateTime | null} the `Date` representing the exact sunrise time. If the calculation can't be computed such as
* in the Arctic Circle where there is at least one day a year where the sun does not rise, and one where it
* does not set, a null will be returned. See detailed explanation on top of the page.
* @see adjustZenith
* @see getSeaLevelSunrise()
* @see getUTCSunrise
*/
getSunrise(): Temporal.ZonedDateTime | null;
/**
* A method that returns the sunrise without {@link getElevationAdjustment elevation
* adjustment}. Non-sunrise and sunset calculations such as dawn and dusk, depend on the amount of visible light,
* something that is not affected by elevation. This method returns sunrise calculated at sea level. This forms the
* base for dawn calculations that are calculated as a dip below the horizon before sunrise.
*
* @return {Temporal.ZonedDateTime | null} the `Date` representing the exact sea-level sunrise time. If the calculation can't be computed
* such as in the Arctic Circle where there is at least one day a year where the sun does not rise, and one
* where it does not set, a null will be returned. See detailed explanation on top of the page.
* @see getSunrise
* @see getUTCSeaLevelSunrise
* @see getSeaLevelSunset()
*/
getSeaLevelSunrise(): Temporal.ZonedDateTime | null;
/**
* A method that returns the beginning of civil twilight (dawn) using a zenith of {@link CIVIL_ZENITH 96°}.
*
* @return {Temporal.ZonedDateTime | null} The `Date` of the beginning of civil twilight using a zenith of 96°. If the calculation
* can't be computed, null will be returned. See detailed explanation on top of the page.
* @see CIVIL_ZENITH
*/
getBeginCivilTwilight(): Temporal.ZonedDateTime | null;
/**
* A method that returns the beginning of nautical twilight using a zenith of {@link NAUTICAL_ZENITH 102°}.
*
* @return {Temporal.ZonedDateTime | null} The `Date` of the beginning of nautical twilight using a zenith of 102°. If the
* calculation can't be computed null will be returned. See detailed explanation on top of the page.
* @see NAUTICAL_ZENITH
*/
getBeginNauticalTwilight(): Temporal.ZonedDateTime | null;
/**
* A method that returns the beginning of astronomical twilight using a zenith of {@link ASTRONOMICAL_ZENITH
* 108°}.
*
* @return {Temporal.ZonedDateTime | null} The `Date` of the beginning of astronomical twilight using a zenith of 108°. If the
* calculation can't be computed, null will be returned. See detailed explanation on top of the page.
* @see ASTRONOMICAL_ZENITH
*/
getBeginAstronomicalTwilight(): Temporal.ZonedDateTime | null;
/**
* The getSunset method Returns a `Date` representing the
* {@link getElevationAdjustment elevation adjusted} sunset time. The zenith used for
* the calculation uses {@link GEOMETRIC_ZENITH geometric zenith} of 90° plus
* {@link getElevationAdjustment}. This is adjusted
* to add approximately 50/60 of a degree to account for 34 archminutes of refraction
* and 16 archminutes for the sun's radius for a total of {@link adjustZenith 90.83333°}.
* Note:
* In certain cases the calculates sunset will occur before sunrise. This will typically happen when a timezone
* other than the local timezone is used (calculating Los Angeles sunset using a GMT timezone for example). In this
* case the sunset date will be incremented to the following date.
*
* @return {Temporal.ZonedDateTime | null} The `Date` representing the exact sunset time. If the calculation can't be computed such as in
* the Arctic Circle where there is at least one day a year where the sun does not rise, and one where it
* does not set, a null will be returned. See detailed explanation on top of the page.
* @see adjustZenith
* @see getSeaLevelSunset()
* @see getUTCSunset
*/
getSunset(): Temporal.ZonedDateTime | null;
/**
* A method that returns the sunset without {@link getElevationAdjustment elevation
* adjustment}. Non-sunrise and sunset calculations such as dawn and dusk, depend on the amount of visible light,
* something that is not affected by elevation. This method returns sunset calculated at sea level. This forms the
* base for dusk calculations that are calculated as a dip below the horizon after sunset.
*
* @return {Temporal.ZonedDateTime | null} The `Date` representing the exact sea-level sunset time. If the calculation can't be computed
* such as in the Arctic Circle where there is at least one day a year where the sun does not rise, and one
* where it does not set, a null will be returned. See detailed explanation on top of the page.
* @see getSunset
* @see getUTCSeaLevelSunset
*/
getSeaLevelSunset(): Temporal.ZonedDateTime | null;
/**
* A method that returns the end of civil twilight using a zenith of {@link CIVIL_ZENITH 96°}.
*
* @return {Temporal.ZonedDateTime | null} The `Date` of the end of civil twilight using a zenith of {@link CIVIL_ZENITH 96°}. If
* the calculation can't be computed, null will be returned. See detailed explanation on top of the page.
* @see CIVIL_ZENITH
*/
getEndCivilTwilight(): Temporal.ZonedDateTime | null;
/**
* A method that returns the end of nautical twilight using a zenith of {@link NAUTICAL_ZENITH 102°}.
*
* @return {Temporal.ZonedDateTime | null} The `Date` of the end of nautical twilight using a zenith of {@link NAUTICAL_ZENITH 102°}
* . If the calculation can't be computed, null will be returned. See detailed explanation on top of the
* page.
* @see NAUTICAL_ZENITH
*/
getEndNauticalTwilight(): Temporal.ZonedDateTime | null;
/**
* A method that returns the end of astronomical twilight using a zenith of {@link ASTRONOMICAL_ZENITH 108°}.
*
* @return {Temporal.ZonedDateTime | null} The `Date` of the end of astronomical twilight using a zenith of {@link ASTRONOMICAL_ZENITH
* 108°}. If the calculation can't be computed, null will be returned. See detailed explanation on top
* of the page.
* @see ASTRONOMICAL_ZENITH
*/
getEndAstronomicalTwilight(): Temporal.ZonedDateTime | null;
/**
* A utility method that returns a date offset by the offset time passed in. Please note that the level of light
* during twilight is not affected by elevation, so if this is being used to calculate an offset before sunrise or
* after sunset with the intent of getting a rough "level of light" calculation, the sunrise or sunset time passed
* to this method should be sea level sunrise and sunset.
*
* @param {Temporal.ZonedDateTime | null} time
* the start time
* @param {number} offset
* the offset in milliseconds to add to the time.
* @return {Temporal.ZonedDateTime | null} the `Date` with the offset in milliseconds added to it
*/
static getTimeOffset(time: Temporal.ZonedDateTime | null, offset: number): Temporal.ZonedDateTime | null;
/**
* A utility method that returns the time of an offset by degrees below or above the horizon of
* {@link getSunrise() sunrise}. Note that the degree offset is from the vertical, so for a calculation of 14°
* before sunrise, an offset of 14 + {@link GEOMETRIC_ZENITH} = 104 would have to be passed as a parameter.
*
* @param {number} offsetZenith
* the degrees before {@link 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°
* before sunrise, an offset of 14 + {@link GEOMETRIC_ZENITH} = 104 would have to be passed as a
* parameter.
* @return {Temporal.ZonedDateTime | null} The `Date` of the offset after (or before) {@link getSunrise}. If the calculation
* can't be computed such as in the Arctic Circle where there is at least one day a year where the sun does
* not rise, and one where it does not set, a null will be returned. See detailed explanation on top of the
* page.
*/
getSunriseOffsetByDegrees(offsetZenith: number): Temporal.ZonedDateTime | null;
/**
* A utility method that returns the time of an offset by degrees below or above the horizon of {@link getSunset()
* sunset}. Note that the degree offset is from the vertical, so for a calculation of 14° after sunset, an
* offset of 14 + {@link GEOMETRIC_ZENITH} = 104 would have to be passed as a parameter.
*
* @param {number} offsetZenith
* the degrees after {@link 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° after
* sunset, an offset of 14 + {@link GEOMETRIC_ZENITH} = 104 would have to be passed as a parameter.
* @return {Temporal.ZonedDateTime | null} The `Date`of the offset after (or before) {@link getSunset}. If the calculation can't
* be computed such as in the Arctic Circle where there is at least one day a year where the sun does not
* rise, and one where it does not set, a null will be returned. See detailed explanation on top of the
* page.
*/
getSunsetOffsetByDegrees(offsetZenith: number): Temporal.ZonedDateTime | null;
/**
* A method that returns the sunrise in UTC time without correction for time zone offset from GMT and without using
* daylight savings time.
*
* @param {number} zenith
* the degrees below the horizon. For time after sunrise use negative numbers.
* @return {number} The time in the format: 18.75 for 18:45:00 UTC/GMT. If the calculation can't be computed such as in the
* Arctic Circle where there is at least one day a year where the sun does not rise, and one where it does
* not set, `NaN` will be returned. See detailed explanation on top of the page.
*/
getUTCSunrise0(zenith: number): number;
/**
* A method that returns the sunrise in UTC time without correction for time zone offset from GMT and without using
* daylight savings time. Non-sunrise and sunset calculations such as dawn and dusk, depend on the amount of visible
* light, something that is not affected by elevation. This method returns UTC sunrise calculated at sea level. This
* forms the base for dawn calculations that are calculated as a dip below the horizon before sunrise.
*
* @param {number} zenith
* the degrees below the horizon. For time after sunrise use negative numbers.
* @return {number} The time in the format: 18.75 for 18:45:00 UTC/GMT. If the calculation can't be computed such as in the
* Arctic Circle where there is at least one day a year where the sun does not rise, and one where it does
* not set, `NaN` will be returned. See detailed explanation on top of the page.
* @see getUTCSunrise
* @see getUTCSeaLevelSunset
*/
getUTCSeaLevelSunrise(zenith: number): number;
/**
* A method that returns the sunset in UTC time without correction for time zone offset from GMT and without using
* daylight savings time.
*
* @param {number} zenith
* the degrees below the horizon. For time after sunset use negative numbers.
* @return {number} The time in the format: 18.75 for 18:45:00 UTC/GMT. If the calculation can't be computed such as in the
* Arctic Circle where there is at least one day a year where the sun does not rise, and one where it does
* not set, `NaN` will be returned. See detailed explanation on top of the page.
* @see getUTCSeaLevelSunset
*/
getUTCSunset0(zenith: number): number;
/**
* A method that returns the sunset in UTC time without correction for elevation, time zone offset from GMT and
* without using daylight savings time. Non-sunrise and sunset calculations such as dawn and dusk, depend on the
* amount of visible light, something that is not affected by elevation. This method returns UTC sunset calculated
* at sea level. This forms the base for dusk calculations that are calculated as a dip below the horizon after
* sunset.
*
* @param {number} zenith
* the degrees below the horizon. For time before sunset use negative numbers.
* @return {number} The time in the format: 18.75 for 18:45:00 UTC/GMT. If the calculation can't be computed such as in the
* Arctic Circle where there is at least one day a year where the sun does not rise, and one where it does
* not set, `NaN` will be returned. See detailed explanation on top of the page.
* @see getUTCSunset
* @see getUTCSeaLevelSunrise
*/
getUTCSeaLevelSunset(zenith: number): number;
/**
* Adjusts the Calendar to deal with edge cases where the location crosses the antimeridian.
* @private
* @see GeoLocation#getAntimeridianAdjustment()
* @return the adjusted Calendar
*/
private getAdjustedDate;
/** Memoized result of {@link getAdjustedDate} */
private adjustedDate;
/**
* Method to return the adjustment to the zenith required to account for the elevation. Since a person at a higher
* elevation can see farther below the horizon, the calculation for sunrise / sunset is calculated below the horizon
* used at sea level. This is only used for sunrise and sunset and not times before or after it such as
* {@link getBeginNauticalTwilight() nautical twilight} since those
* calculations are based on the level of available light at the given dip below the horizon, something that is not
* affected by elevation, the adjustment should only made if the zenith == 90° {@link adjustZenith adjusted}
* for refraction and solar radius. The algorithm used is
*
*
* elevationAdjustment = Math.toDegrees(Math.acos(earthRadiusInMeters / (earthRadiusInMeters + elevationMeters)));
*
*
* The source of this algorithm is Calendrical Calculations by Edward M.
* Reingold and Nachum Dershowitz. An alternate algorithm that produces an almost identical (but not accurate)
* result found in Ma'aglay Tzedek by Moishe Kosower and other sources is:
*
*
* elevationAdjustment = 0.0347 * Math.sqrt(elevationMeters);
*
*
* @param {number} elevation
* elevation in Meters.
* @return {number} the adjusted zenith
*/
getElevationAdjustment(elevation: number): number;
/**
* Adjusts the zenith of astronomical sunrise and sunset to account for solar refraction, solar radius and
* elevation. The value for Sun's zenith and true rise/set Zenith (used in this class and subclasses) is the angle
* that the center of the Sun makes to a line perpendicular to the Earth's surface. If the Sun were a point and the
* Earth were without an atmosphere, true sunset and sunrise would correspond to a 90° zenith. Because the Sun
* is not a point, and because the atmosphere refracts light, this 90° zenith does not, in fact, correspond to
* true sunset or sunrise, instead the centre of the Sun's disk must lie just below the horizon for the upper edge
* to be obscured. This means that a zenith of just above 90° must be used. The Sun subtends an angle of 16
* minutes of arc, and atmospheric refraction
* accounts for 34 minutes or so, giving a total
* of 50 arcminutes. The total value for ZENITH is 90+(5/6) or 90.8333333° for true sunrise/sunset. Since a
* person at an elevation can see blow the horizon of a person at sea level, this will also adjust the zenith to
* account for elevation if available. Note that this will only adjust the value if the zenith is exactly 90 degrees.
* For values below and above this no correction is done. As an example, astronomical twilight is when the sun is
* 18° below the horizon or {@link ASTRONOMICAL_ZENITH 108°
* below the zenith}. This is traditionally calculated with none of the above mentioned adjustments. The same goes
* for various tzais and alos times such as the
* {@link ZmanimCalendar#ZENITH_16_POINT_1 16.1°} dip used in
* {@link ComplexZmanimCalendar#getAlos16Point1Degrees}.
*
* @param {number} zenith
* the azimuth below the vertical zenith of 90°. For sunset typically the {@link adjustZenith
* zenith} used for the calculation uses geometric zenith of 90° and {@link adjustZenith adjusts}
* this slightly to account for solar refraction and the sun's radius. Another example would be
* {@link getEndNauticalTwilight} that passes
* {@link NAUTICAL_ZENITH} to this method.
* @param {number} elevation
* elevation in Meters.
* @return {number} The zenith adjusted to include the sun's radius, refracton
* and {@link getElevationAdjustment elevation} adjustment. This will only be adjusted for
* sunrise and sunset (if the zenith == 90°)
* @see getElevationAdjustment
*/
adjustZenith(zenith: number, elevation: number): number;
/**
* The Julian day of January 1, 2000
* @private
*/
private static readonly JULIAN_DAY_JAN_1_2000;
/**
* Julian days per century
* @private
*/
private static readonly JULIAN_DAYS_PER_CENTURY;
/**
* A method that calculates UTC sunrise as well as any time based on an angle above or below sunrise.
* @param date
* Used to calculate day of year.
* @param geoLocation
* The location information used for astronomical calculating sun times.
* @param zenith
* the azimuth below the vertical zenith of 90 degrees. for sunrise typically the {@link adjustZenith
* zenith} used for the calculation uses geometric zenith of 90° and {@link adjustZenith adjusts}
* this slightly to account for solar refraction and the sun's radius. Another example would be
* {@link getBeginNauticalTwilight} that passes
* {@link NAUTICAL_ZENITH} to this method.
* @param adjustForElevation
* Should the time be adjusted for elevation
* @return The UTC time of sunrise in 24 hour format. 5:45:00 AM will return 5.75.0. If an error was encountered in
* the calculation (expected behavior for some locations such as near the poles,
* `NaN` will be returned.
*/
getUTCSunrise(date: Temporal.PlainDate, geoLocation: GeoLocation, zenith: number, adjustForElevation: boolean): number;
/**
* A method that calculates UTC sunset as well as any time based on an angle above or below sunset.
* @param date
* Used to calculate day of year.
* @param geoLocation
* The location information used for astronomical calculating sun times.
* @param zenith
* the azimuth below the vertical zenith of 90°. For sunset typically the {@link adjustZenith
* zenith} used for the calculation uses geometric zenith of 90° and {@link adjustZenith adjusts}
* this slightly to account for solar refraction and the sun's radius. Another example would be
* {@link getEndNauticalTwilight} that passes
* {@link NAUTICAL_ZENITH} to this method.
* @param adjustForElevation
* Should the time be adjusted for elevation
* @return The UTC time of sunset in 24 hour format. 5:45:00 AM will return 5.75.0. If an error was encountered in
* the calculation (expected behavior for some locations such as near the poles,
* `NaN` will be returned.
*/
getUTCSunset(date: Temporal.PlainDate, geoLocation: GeoLocation, zenith: number, adjustForElevation: boolean): number;
/**
* A utility method that will allow the calculation of a temporal (solar) hour based on the sunrise and sunset
* passed as parameters to this method. An example of the use of this method would be the calculation of a
* non-elevation adjusted temporal hour by passing in {@link getSeaLevelSunrise() sea level sunrise} and
* {@link getSeaLevelSunset() sea level sunset} as parameters.
*
* @param {Temporal.ZonedDateTime | null} startOfDay
* The start of the day.
* @param {Temporal.ZonedDateTime | null} endOfDay
* The end of the day.
*
* @return {number} the long millisecond length of the temporal hour. If the calculation can't be computed a
* `NaN` will be returned. See detailed explanation on top of the page.
*
* @see getTemporalHour()
*/
getTemporalHour(startOfDay?: Temporal.ZonedDateTime | null, endOfDay?: Temporal.ZonedDateTime | null): number;
/**
* A method that returns sundial or solar noon. It occurs when the Sun is transiting the celestial meridian. In this class it is
* calculated as halfway between the sunrise and sunset passed to this method. This time can be slightly off the
* real transit time due to changes in declination (the lengthening or shortening day).
*
* @param {Temporal.ZonedDateTime | null} startOfDay
* the start of day for calculating the sun's transit. This can be sea level sunrise, visual sunrise (or
* any arbitrary start of day) passed to this method.
* @param {Temporal.ZonedDateTime | null} endOfDay
* the end of day for calculating the sun's transit. This can be sea level sunset, visual sunset (or any
* arbitrary end of day) passed to this method.
*
* @return {Temporal.ZonedDateTime | null} The `Date` representing Sun's transit. If the calculation can't be computed such as in the
* Arctic Circle where there is at least one day a year where the sun does not rise, and one where it does
* not set, null will be returned. See detailed explanation on top of the page.
*/
getSunTransit(startOfDay?: Temporal.ZonedDateTime | null, endOfDay?: Temporal.ZonedDateTime | null): Temporal.ZonedDateTime | null;
/**
* A method that returns a `Date` from the time passed in as a parameter.
* @protected
* @param {number} time
* The time to be set as the time for the `Date`. The time expected is in the format: 18.75
* for 6:45:00 PM.
* @param {boolean} isSunrise true if the time is sunrise, and false if it is sunset
* @return {Temporal.ZonedDateTime | null} The Date.
*/
protected getDateFromTime(time: number, isSunrise: boolean): Temporal.ZonedDateTime | null;
/**
* The instant that {@link getDateFromTime} describes, as milliseconds since
* the epoch, without building a `Temporal.ZonedDateTime`.
*
* Constructing a `ZonedDateTime` costs roughly 750ns because the IANA zone
* has to be resolved, and that dominates this calculation. Callers that only
* want an instant — a `Date`, or the difference between two times — can skip
* it. Deriving the instant arithmetically also avoids a `PlainTime`
* allocation and turns the day rollover into a subtraction rather than a
* ~610ns `PlainDate.add({days})`.
*
* @param {number} time
* The time in the format 18.75 for 6:45:00 PM, as returned by
* {@link getUTCSunrise} / {@link getUTCSunset}, i.e. already
* normalized to `[0, 24)`.
* @param {boolean} isSunrise true if the time is sunrise, and false if it is sunset
* @return {number} milliseconds since the epoch, or `NaN` if `time` is `NaN`
*/
getEpochMillisFromTime(time: number, isSunrise: boolean): number;
/**
* Return the Julian day from a Java Calendar
* @private
* @param {Temporal.ZonedDateTime} date
* The Java Calendar
* @return the Julian day corresponding to the date Note: Number is returned for start of day. Fractional days
* should be added later.
*/
private static getJulianDay;
/**
* Convert Julian day to centuries since J2000.0.
* @private
* @param julianDay
* the Julian Day to convert
* @return the centuries since 2000 Julian corresponding to the Julian Day
*/
private static getJulianCenturiesFromJulianDay;
/**
* Convert centuries since J2000.0 to Julian day.
* @private
* @param julianCenturies
* the number of Julian centuries since J2000.0
* @return the Julian Day corresponding to the Julian centuries passed in
*/
private static getJulianDayFromJulianCenturies;
/**
* Returns the Geometric Mean Longitude of the Sun.
* @private
* @param julianCenturies
* the number of Julian centuries since J2000.0
* @return the Geometric Mean Longitude of the Sun in degrees
*/
private static getSunGeometricMeanLongitude;
/**
* Returns the Geometric Mean Anomaly of the Sun.
* @private
* @param julianCenturies
* the number of Julian centuries since J2000.0
* @return the Geometric Mean Anomaly of the Sun in degrees
*/
private static getSunGeometricMeanAnomaly;
/**
* Return the eccentricity of earth's orbit.
* @private
* @param julianCenturies
* the number of Julian centuries since J2000.0
* @return the unitless eccentricity
*/
private static getEarthOrbitEccentricity;
/**
* Returns the equation of center for the sun.
* @private
* @param julianCenturies
* the number of Julian centuries since J2000.0
* @return the equation of center for the sun in degrees
*/
private static getSunEquationOfCenter;
/**
* Return the true longitude of the sun
* @private
* @param julianCenturies
* the number of Julian centuries since J2000.0
* @return the sun's true longitude in degrees
*/
private static getSunTrueLongitude;
/**
* Return the apparent longitude of the sun
* @private
* @param julianCenturies
* the number of Julian centuries since J2000.0
* @return sun's apparent longitude in degrees
*/
private static getSunApparentLongitude;
/**
* Returns the mean obliquity of the ecliptic (Axial tilt).
* @private
* @param julianCenturies
* the number of Julian centuries since J2000.0
* @return the mean obliquity in degrees
*/
private static getMeanObliquityOfEcliptic;
/**
* Returns the corrected obliquity of the ecliptic (Axial
* tilt).
* @private
* @param julianCenturies
* the number of Julian centuries since J2000.0
* @return the corrected obliquity in degrees
*/
private static getObliquityCorrection;
/**
* Return the declination of the sun.
* @private
* @param julianCenturies
* the number of Julian centuries since J2000.0
* @return
* the sun's declination in degrees
*/
private static getSunDeclination;
/**
* Return the Equation of Time - the difference between
* true solar time and mean solar time
* @private
* @param julianCenturies
* the number of Julian centuries since J2000.0
* @return equation of time in minutes of time
*/
private static getEquationOfTime;
/**
* Return the hour angle of the sun at sunrise for the
* latitude.
* @private
* @param {number} lat
* , the latitude of observer in degrees
* @param solarDec
* the declination angle of sun in degrees
* @param {number} zenith
* the zenith
* @return hour angle of sunrise in radians
*/
private static getSunHourAngleAtSunrise;
/**
* Returns the hour angle of the sun at sunset for the
* latitude.
* @private
* @param {number} lat
* the latitude of observer in degrees
* @param solarDec
* the declination angle of sun in degrees
* @param {number} zenith
* the zenith
* @return the hour angle of sunset in radians
*/
private static getSunHourAngleAtSunset;
/**
* Return the Solar Elevation for the
* horizontal coordinate system at the given location at the given time. Can be negative if the sun is below the
* horizon. Not corrected for altitude.
*
* @param {Temporal.ZonedDateTime} date
* time of calculation
* @param {number} lat
* latitude of location for calculation
* @param {number} lon
* longitude of location for calculation
* @return {number} solar elevation in degrees - horizon is 0 degrees, civil twilight is -6 degrees
*/
static getSolarElevation(date: Temporal.ZonedDateTime, lat: number, lon: number): number;
/**
* Return the Solar Azimuth for the
* horizontal coordinate system at the given location at the given time. Not corrected for altitude. True south is 0
* degrees.
*
* @param {Temporal.ZonedDateTime} date
* time of calculation
* @param {number} latitude
* latitude of location for calculation
* @param {number} lon
* longitude of location for calculation
* @return {number}
*/
static getSolarAzimuth(date: Temporal.ZonedDateTime, latitude: number, lon: number): number;
/**
* Return the Universal Coordinated Time (UTC)
* of sunrise for the given day at the given location on earth
* @private
* @param julianDay
* the Julian day
* @param {number} latitude
* the latitude of observer in degrees
* @param {number} longitude
* the longitude of observer in degrees
* @param {number} zenith
* the zenith
* @return the time in minutes from zero UTC
*/
private static getSunriseUTC;
/**
* Return the Universal Coordinated Time (UTC)
* of solar noon for the given day at the given location
* on earth.
* @private
* @param julianCenturies
* the number of Julian centuries since J2000.0
* @param {number} longitude
* the longitude of observer in degrees
* @return the time in minutes from zero UTC
*/
private static getSolarNoonUTC;
/**
* Return the Universal Coordinated Time (UTC)
* of sunset for the given day at the given location on earth
* @private
* @param julianDay
* the Julian day
* @param {number} latitude
* the latitude of observer in degrees
* @param {number} longitude
* : longitude of observer in degrees
* @param {number} zenith
* the zenith
* @return the time in minutes from zero Universal Coordinated Time (UTC)
*/
private static getSunsetUTC;
}