import { DateTime } from 'luxon';
import { GeoLocation } from './GeoLocation';
import { AstronomicalCalculator } from './AstronomicalCalculator';
/**
* 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 extends AstronomicalCalculator {
/**
* The Julian day of January 1, 2000, known as
* J2000.0.
*/
private static readonly JULIAN_DAY_JAN_1_2000;
/**
* Julian days per century
*/
private static readonly JULIAN_DAYS_PER_CENTURY;
/**
* An enum to indicate what type of solar event ({@link #SUNRISE SUNRISE}, {@link #SUNSET SUNSET},
* {@link #NOON NOON} or {@link #MIDNIGHT MIDNIGHT}) is being calculated.
*/
protected static readonly SolarEvent: {
/** SUNRISE A solar event related to sunrise */
readonly SUNRISE: 0;
/** SUNSET A solar event related to sunset */
readonly SUNSET: 1;
/** NOON A solar event related to noon */
readonly NOON: 2;
/** MIDNIGHT A solar event related to midnight */
readonly MIDNIGHT: 3;
};
/**
* Default constructor of the NOAACalculator.
*/
constructor();
/**
* @see AstronomicalCalculator#getCalculatorName()
*/
getCalculatorName(): string;
/**
* @see AstronomicalCalculator#getUTCSunrise(Calendar, GeoLocation, double, boolean)
*/
getUTCSunrise(date: DateTime, geoLocation: GeoLocation, zenith: number, adjustForElevation: boolean): number;
/**
* @see AstronomicalCalculator#getUTCSunset(Calendar, GeoLocation, double, boolean)
*/
getUTCSunset(date: DateTime, geoLocation: GeoLocation, zenith: number, adjustForElevation: boolean): number;
/**
* Return the Julian day from a Java Calendar.
*
* @param calendar
* 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.
*
* @param julianDay
* the Julian Day to convert
* @return the centuries since 2000 Julian corresponding to the Julian Day
*/
private static getJulianCenturiesFromJulianDay;
/**
* Returns the Geometric Mean Longitude of the Sun.
*
* @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.
*
* @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 unitless eccentricity of earth's orbit.
*
* @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 in degrees.
*
* @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.
*
* @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.
*
* @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).
*
* @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).
*
* @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.
*
* @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
*
* @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 in
* radians at sunrise for the latitude.
*
* @param latitude
* the latitude of observer in degrees
* @param solarDeclination
* the declination angle of sun in degrees
* @param zenith
* the zenith
* @param solarEvent
* If the hour angle is for {@link SolarEvent#SUNRISE SUNRISE} or {@link SolarEvent#SUNSET SUNSET}
* @return hour angle of sunrise in radians
*/
private static getSunHourAngle;
/**
* 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 calendar
* time of calculation
* @param latitude
* latitude of location for calculation
* @param longitude
* longitude of location for calculation
* @return solar elevation in degrees - horizon is 0 degrees, civil twilight is -6 degrees
*/
static getSolarElevation(date: DateTime, latitude: number, longitude: 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 cal
* time of calculation
* @param latitude
* latitude of location for calculation
* @param longitude
* longitude of location for calculation
* @return FIXME
*/
static getSolarAzimuth(date: DateTime, latitude: number, longitude: number): number;
/**
* Return the Universal Coordinated Time (UTC)
* of solar noon for the given day at the given location
* on earth. This implementation returns true solar noon as opposed to the time halfway between sunrise and sunset.
* Other calculators may return a more simplified calculation of halfway between sunrise and sunset. See The Definition of Chatzos for details on
* solar noon calculations.
* @see com.kosherjava.zmanim.util.AstronomicalCalculator#getUTCNoon(Calendar, GeoLocation)
* @see #getSolarNoonMidnightUTC(double, double, SolarEvent)
*
* @param date
* The Calendar representing the date to calculate solar noon for
* @param geoLocation
* The location information used for astronomical calculating sun times. This class uses only requires
* the longitude for calculating noon since it is the same time anywhere along the longitude line.
* @return the time in minutes from zero UTC
*/
getUTCNoon(date: DateTime, geoLocation: GeoLocation): number;
/**
* Return the Universal Coordinated Time
* (UTC) of the solar midnight for the end of the given civil
* day at the given location on earth (about 12 hours after solar noon). This implementation returns true solar
* midnight as opposed to the time halfway between sunrise and sunset. Other calculators may return a more
* simplified calculation of halfway between sunrise and sunset. See The Definition of Chatzos for details on
* solar noon / midnight calculations.
* @see com.kosherjava.zmanim.util.AstronomicalCalculator#getUTCNoon(Calendar, GeoLocation)
* @see #getSolarNoonMidnightUTC(double, double, SolarEvent)
*
* @param calendar
* The Calendar representing the date to calculate solar noon for
* @param geoLocation
* The location information used for astronomical calculating sun times. This class uses only requires
* the longitude for calculating noon since it is the same time anywhere along the longitude line.
* @return the time in minutes from zero UTC
*/
getUTCMidnight(date: DateTime, geoLocation: GeoLocation): number;
/**
* Return the Universal Coordinated Time (UTC)
* midnight (about 12 hours after solar noon) of the given day at the given location on earth.
*
* @param julianDay
* The Julian day since J2000.0.
* @param longitude
* the longitude of observer in degrees
* @param solarEvent
* If the calculation is for {@link SolarEvent#NOON NOON} or {@link SolarEvent#MIDNIGHT MIDNIGHT}
*
* @return the time in minutes from zero UTC
*
* @see com.kosherjava.zmanim.util.AstronomicalCalculator#getUTCNoon(Calendar, GeoLocation)
* @see #getUTCNoon(Calendar, GeoLocation)
*/
private static getSolarNoonMidnightUTC;
/**
* Return the Universal Coordinated Time (UTC)
* of sunrise or sunset for the given day at the given location on earth.
* @todo Possibly increase the number of passes for improved accuracy, especially in the Arctic areas.
*
* @param calendar
* The calendar
* @param latitude
* The latitude of observer in degrees
* @param longitude
* Longitude of observer in degrees
* @param zenith
* Zenith
* @param solarEvent
* If the calculation is for {@link SolarEvent#SUNRISE SUNRISE} or {@link SolarEvent#SUNSET SUNSET}
* @return the time in minutes from zero Universal Coordinated Time (UTC)
*/
private static getSunRiseSetUTC;
}