### Install Pyorbital using pip Source: https://pyorbital.readthedocs.io/en/latest/_sources/index.rst.txt Install the Pyorbital package from the Python Package Index (PyPI) using pip. ```bash pip install pyorbital ``` -------------------------------- ### Install Pyorbital using conda Source: https://pyorbital.readthedocs.io/en/latest/_sources/index.rst.txt Install the Pyorbital package from the conda-forge channel using conda. ```bash conda install -c conda-forge pyorbital ``` -------------------------------- ### Install Pyorbital from source (development version) Source: https://pyorbital.readthedocs.io/en/latest/_sources/index.rst.txt Install the latest development version of Pyorbital directly from its GitHub repository using pip. ```bash pip install git+https://github.com/pytroll/pyorbital.git ``` -------------------------------- ### Install Pyorbital from source (editable mode) Source: https://pyorbital.readthedocs.io/en/latest/_sources/index.rst.txt Clone the Pyorbital GitHub repository and install it in editable mode to reflect source code changes immediately. ```bash git clone git://github.com/pytroll/pyorbital.git cd pyorbital pip install -e . ``` -------------------------------- ### get_platforms_filepath Source: https://pyorbital.readthedocs.io/en/latest Gets the file path for platforms.txt and checks for its existence. ```APIDOC ## pyorbital.tlefile.get_platforms_filepath() ### Description Get the platforms.txt file path. Check that the file exists or raise an error. ### Usage This function does not take any arguments. ``` -------------------------------- ### Get Satellite Position with Earlier TLE Source: https://pyorbital.readthedocs.io/en/latest Demonstrates how using a TLE from a slightly earlier date can result in a different positional calculation. ```python snpp = Orbital('Suomi NPP', tle_file='/path/to/tle/files/tle-20150131.txt') snpp.get_lonlatalt(dtobj) (104.1539184988462, 79.328272480878141, 838.81555967963391) ``` -------------------------------- ### Read TLE file and get inclination Source: https://pyorbital.readthedocs.io/en/latest/_sources/index.rst.txt Parse a TLE file using the tlefile module and access satellite parameters like inclination. ```python from pyorbital import tlefile tle = tlefile.read('noaa 18', '/path/to/my/tle_file.txt') tle.inclination ``` -------------------------------- ### Get Satellite Position with Specific TLE File Source: https://pyorbital.readthedocs.io/en/latest Calculates the satellite's position using a TLE file specified by its path. This is useful for historical data or when internet access is limited. ```python snpp = Orbital('Suomi NPP', tle_file='/path/to/tle/files/tle-20150207.txt') snpp.get_lonlatalt(dtobj) (105.37373804512762, 79.160752404540133, 838.94605490133154) ``` -------------------------------- ### Get Satellite Position with Earlier TLE Source: https://pyorbital.readthedocs.io/en/latest/_sources/index.rst.txt Calculates the longitude, latitude, and altitude of the Suomi NPP satellite using a TLE file from January 31, 2015. This demonstrates how TLE date affects orbital calculations. ```python >>> snpp = Orbital('Suomi NPP', tle_file='/path/to/tle/files/tle-20150131.txt') >>> snpp.get_lonlatalt(dtobj) (104.1539184988462, 79.328272480878141, 838.81555967963391) ``` -------------------------------- ### Get Satellite Position with Default TLE Source: https://pyorbital.readthedocs.io/en/latest Calculates the longitude, latitude, and altitude of a satellite at a specific datetime using its default TLE data. ```python from pyorbital.orbital import Orbital import datetime as dt orb = Orbital("Suomi NPP") dtobj = dt.datetime(2015,2,7,3,0) orb.get_lonlatalt(dtobj) (152.11564698762811, 20.475251739329622, 829.37355785502211) ``` -------------------------------- ### Get Satellite Position with Specific TLE Source: https://pyorbital.readthedocs.io/en/latest/_sources/index.rst.txt Calculates the longitude, latitude, and altitude of the Suomi NPP satellite using a TLE file from February 7, 2015. This is useful for historical position tracking. ```python >>> snpp = Orbital('Suomi NPP', tle_file='/path/to/tle/files/tle-20150207.txt') >>> snpp.get_lonlatalt(dtobj) (105.37373804512762, 79.160752404540133, 838.94605490133154) ``` -------------------------------- ### main Source: https://pyorbital.readthedocs.io/en/latest Runs a test for TLE reading. ```APIDOC ## pyorbital.tlefile.main() ### Description Run a test TLE reading. ### Usage This function does not take any arguments. ``` -------------------------------- ### TLE Handling Source: https://pyorbital.readthedocs.io/en/latest Utilities for downloading, reading, and managing Two-Line Element (TLE) data. ```APIDOC ## Class ChecksumError ### Description Exception raised for TLE checksum errors. ## Class Downloader ### Description Handles the downloading and reading of TLE data from various sources. ### Methods - `fetch_plain_tle()` - `fetch_spacetrack()` - `read_tle_files()` - `read_xml_admin_messages()` ## Variable SATELLITES ### Description Collection of satellite data. ## Class SQLiteTLE ### Description Manages TLE data stored in an SQLite database. ### Methods - `close()` - `update_db()` - `write_tle_txt()` ## Class Tle ### Description Represents a single Two-Line Element set. ### Attributes - `excentricity` (float) - `line1` (str) - `line2` (str) - `platform` (str) ### Methods - `to_dict()` ## Function check_is_platform_supported() ### Description Checks if a given satellite platform is supported. ## Function collect_filenames() ### Description Collects TLE filenames from a directory. ## Function fetch() ### Description Fetches TLE data. ## Function get_platforms_filepath() ### Description Gets the file path for platform TLE data. ## Function main() ### Description Main entry point for TLE handling operations. ## Function read() ### Description Reads TLE data from a source. ## Function read_platform_numbers() ### Description Reads platform numbers from TLE data. ## Function read_tle_from_mmam_xml_file() ### Description Reads TLE data from a specific MMAM XML file. ## Function read_tles_from_mmam_xml_files() ### Description Reads TLE data from multiple MMAM XML files. ## Function table_exists() ### Description Checks if a TLE table exists in the database. ``` -------------------------------- ### Configure TLE file path using environment variable Source: https://pyorbital.readthedocs.io/en/latest/_sources/index.rst.txt Set the TLES environment variable to a glob pattern for Pyorbital to find local TLE files. ```bash TLES=/path/to/tle_files/*/tle*txt ``` -------------------------------- ### check_is_platform_supported Source: https://pyorbital.readthedocs.io/en/latest Checks if a satellite platform is supported and prints information. ```APIDOC ## pyorbital.tlefile.check_is_platform_supported(_satname_) ### Description Check if satellite is supported and print info. ### Parameters - `_satname_`: The name of the satellite platform to check. ``` -------------------------------- ### fetch Source: https://pyorbital.readthedocs.io/en/latest Fetches TLE data from the internet and saves it to a destination. ```APIDOC ## pyorbital.tlefile.fetch(_destination_) ### Description Fetch TLE from internet and save it to destination. ### Parameters - `_destination_`: The path where the TLE data should be saved. ``` -------------------------------- ### read Source: https://pyorbital.readthedocs.io/en/latest Reads TLE data for a given platform. ```APIDOC ## pyorbital.tlefile.read(_platform_, _tle_file =None_, _line1 =None_, _line2 =None_) ### Description Read TLE for _platform_. The data are read from _tle_file_ , from _line1_ and _line2_ , from the newest file provided in the TLES pattern, or from internet if none is provided. ### Parameters - `_platform_`: The satellite platform name. - `_tle_file` (optional): Path to the TLE file. - `_line1` (optional): The first line of the TLE. - `_line2` (optional): The second line of the TLE. ``` -------------------------------- ### Check Platform Support Source: https://pyorbital.readthedocs.io/en/latest Use the check_platform script to verify if a satellite is supported by Pyorbital and to find its NORAD number. Ensure the PYORBITAL_CONFIG_PATH environment variable is set if using a custom platforms.txt file. ```python python -m pyorbital.check_platform -s NOAA-21 ``` -------------------------------- ### Check if a satellite is supported Source: https://pyorbital.readthedocs.io/en/latest/_sources/index.rst.txt Use the check_platform script to verify if a satellite is already supported by Pyorbital and to find its NORAD number. ```python python -m pyorbital.check_platform -s NOAA-21 ``` -------------------------------- ### to_dict Source: https://pyorbital.readthedocs.io/en/latest Returns the raw, parsed TLE elements as a dictionary. ```APIDOC ## to_dict() ### Description Return the raw, parsed TLE elements as a dictionary. ### Usage This method does not take any arguments. ``` -------------------------------- ### read_platform_numbers Source: https://pyorbital.readthedocs.io/en/latest Reads platform numbers from platforms.txt. ```APIDOC ## pyorbital.tlefile.read_platform_numbers(_filename_, _in_upper =False_, _num_as_int =False_) ### Description Read platform numbers from $PYORBITAL_CONFIG_PATH/platforms.txt. ### Parameters - `_filename_`: The name of the file to read. - `_in_upper` (optional): Whether to read platform names in uppercase. Defaults to False. - `_num_as_int` (optional): Whether to read numbers as integers. Defaults to False. ``` -------------------------------- ### Downloader Class Source: https://pyorbital.readthedocs.io/en/latest The Downloader class is used for fetching TLE data from various sources. ```APIDOC ## _class _pyorbital.tlefile.Downloader(_config_) ### Description Class for downloading TLE data. ### Methods - **fetch_plain_tle()**: Fetch plain text-formated TLE data. - **fetch_spacetrack()**: Fetch TLE data from Space-Track. - **read_tle_files()**: Read TLE data from files. - **read_xml_admin_messages()**: Read Eumetsat admin messages in XML format. ``` -------------------------------- ### read_tles_from_mmam_xml_files Source: https://pyorbital.readthedocs.io/en/latest Reads TLE data from a list of MMAM XML files (EUMETSAT). ```APIDOC ## pyorbital.tlefile.read_tles_from_mmam_xml_files(_paths_) ### Description Read TLE data from a list of MMAM XMl file (EUMETSAT). MMAM = Multi-Mission Administration Message ### Parameters - `_paths_`: A list of paths to MMAM XML files. ``` -------------------------------- ### get_alt_az Source: https://pyorbital.readthedocs.io/en/latest Returns the sun altitude and azimuth for a given UTC time, longitude, and latitude. ```APIDOC ## pyorbital.astronomy.get_alt_az(_utc_time_, _lon_, _lat_) ### Description Return sun altitude and azimuth from _utc_time_ , _lon_ , and _lat_. ### Parameters - `utc_time`: datetime.datetime instance of the UTC time. - `lon`: Longitude in degrees. - `lat`: Latitude in degrees. ### Returns The returned angles are given in radians. ``` -------------------------------- ### SQLiteTLE Class Source: https://pyorbital.readthedocs.io/en/latest The SQLiteTLE class provides functionality to store TLE data in a SQLite database. ```APIDOC ## _class _pyorbital.tlefile.SQLiteTLE(_db_location_, _platforms_, _writer_config_) ### Description Store TLE data in a sqlite3 database. ### Methods - **close()**: Close the database. ``` -------------------------------- ### table_exists Source: https://pyorbital.readthedocs.io/en/latest Checks if a table exists in the database. ```APIDOC ## pyorbital.tlefile.table_exists(_db_, _name_) ### Description Check if the table ‘name’ exists in the database. ### Parameters - `_db_`: The database object. - `_name_`: The name of the table to check. ``` -------------------------------- ### observer_position Source: https://pyorbital.readthedocs.io/en/latest Calculates the observer's ECI position. ```APIDOC ## pyorbital.astronomy.observer_position(_utc_time_, _lon_, _lat_, _alt_) ### Description Calculate observer ECI position. http://celestrak.com/columns/v02n03/ ### Parameters - `utc_time`: datetime.datetime instance of the UTC time. - `lon`: Longitude in degrees. - `lat`: Latitude in degrees. - `alt`: Altitude in meters. ### Returns Observer's ECI position. ``` -------------------------------- ### sun_ra_dec Source: https://pyorbital.readthedocs.io/en/latest Calculates the right ascension and declination of the sun at a given UTC time. ```APIDOC ## pyorbital.astronomy.sun_ra_dec(_utc_time_) ### Description Right ascension and declination of the sun at _utc_time_. ### Parameters - `utc_time`: datetime.datetime instance of the UTC time. ### Returns A tuple containing the right ascension and declination of the sun in radians. ``` -------------------------------- ### Compute satellite position and velocity Source: https://pyorbital.readthedocs.io/en/latest/_sources/index.rst.txt Calculate the normalized position and velocity of a satellite at a specific time using current TLEs from the internet. ```python from pyorbital.orbital import Orbital import datetime as dt # Use current TLEs from the internet: orb = Orbital("Suomi NPP") now = dt.datetime.now(dt.timezone.utc) # Get normalized position and velocity of the satellite: orb.get_position(now) ``` -------------------------------- ### cos_zen Source: https://pyorbital.readthedocs.io/en/latest Derives the cosine of the sun-zenith angle for a given longitude, latitude, and UTC time. ```APIDOC ## pyorbital.astronomy.cos_zen(_utc_time_, _lon_, _lat_) ### Description Derive the cosine of the sun-zenith angle for _lon_ , _lat_ at _utc_time_. ### Parameters - `utc_time`: datetime.datetime instance of the UTC time. - `lon`: Longitude in degrees. - `lat`: Latitude in degrees. ### Returns Cosine of the sun zenith angle. ``` -------------------------------- ### jdays Source: https://pyorbital.readthedocs.io/en/latest Calculates the Julian day of a given UTC time. ```APIDOC ## pyorbital.astronomy.jdays(_utc_time_) ### Description Get the julian day of _utc_time_. ### Parameters - `utc_time`: datetime.datetime instance of the UTC time. ### Returns The Julian day. ``` -------------------------------- ### Read TLE file Source: https://pyorbital.readthedocs.io/en/latest Reads a TLE file for a given satellite name. If no path is provided, it attempts to read from local files defined by the TLES environment variable or downloads them from the internet. ```python >>> from pyorbital import tlefile >>> tle = tlefile.read('noaa 18', '/path/to/my/tle_file.txt') >>> tle.inclination 99.043499999999995 ``` -------------------------------- ### Orbital Computations Source: https://pyorbital.readthedocs.io/en/latest Provides classes and methods for calculating orbital elements and satellite positions. ```APIDOC ## Class OrbitElements ### Description Represents orbital elements and provides methods for related calculations. ### Methods - `apogee` - `excentricity` - `is_circular` - `is_retrograde` - `perigee` - `position_vector_in_orbital_plane()` - `velocity_at_apogee()` - `velocity_at_perigee()` ## Class Orbital ### Description Provides methods for orbital analysis and position determination. ### Methods - `find_aol()` - `find_aos()` - `get_equatorial_crossing_time()` - `get_last_an_time()` - `get_lonlatalt()` - `get_next_passes()` - `get_observer_look()` - `get_orbit_number()` - `get_position()` - `utc2local()` ## Class OrbitalError ### Description Custom exception class for orbital computation errors. ## Function get_observer_look() ### Description Calculates the observer's look angles towards a satellite. ## Function kep2xyz() ### Description Converts Keplerian elements to Cartesian coordinates. ``` -------------------------------- ### Tle Class Source: https://pyorbital.readthedocs.io/en/latest Class holding TLE objects. ```APIDOC ## class pyorbital.tlefile.Tle ### Description Class holding TLE objects. ### Parameters - `_platform_`: The satellite platform name. - `_tle_file` (optional): Path to the TLE file. - `_line1` (optional): The first line of the TLE. - `_line2` (optional): The second line of the TLE. ``` -------------------------------- ### collect_filenames Source: https://pyorbital.readthedocs.io/en/latest Collects all filenames from the given paths. ```APIDOC ## pyorbital.tlefile.collect_filenames(_paths_) ### Description Collect all filenames from _paths_. ### Parameters - `_paths_`: A list of paths to search for filenames. ``` -------------------------------- ### Compute satellite longitude, latitude, and altitude Source: https://pyorbital.readthedocs.io/en/latest/_sources/index.rst.txt Determine the geographic longitude, latitude, and altitude of a satellite at a given time using current TLEs. ```python from pyorbital.orbital import Orbital import datetime as dt # Use current TLEs from the internet: orb = Orbital("Suomi NPP") now = dt.datetime.now(dt.timezone.utc) # Get longitude, latitude and altitude of the satellite: orb.get_lonlatalt(now) ``` -------------------------------- ### read_tle_from_mmam_xml_file Source: https://pyorbital.readthedocs.io/en/latest Reads TLE data from a MMAM XML file (EUMETSAT). ```APIDOC ## pyorbital.tlefile.read_tle_from_mmam_xml_file(_fname_) ### Description Read TLE data from MMAM XMl file (EUMETSAT). MMAM = Multi-Mission Administration Message ### Parameters - `_fname_`: The path to the MMAM XML file. ``` -------------------------------- ### write_tle_txt Source: https://pyorbital.readthedocs.io/en/latest Writes TLE data to a text file. ```APIDOC ## write_tle_txt ### Description Write TLE data to a text file. ### Usage This function does not take any arguments. ``` -------------------------------- ### Astronomical Computations Source: https://pyorbital.readthedocs.io/en/latest Functions for calculating various astronomical parameters and positions. ```APIDOC ## Note on argument types ### Description Provides guidance on the expected types for function arguments. ## Function cos_zen() ### Description Calculates the cosine of the zenith angle. ## Function get_alt_az() ### Description Computes the altitude and azimuth of a celestial object. ## Function gmst() ### Description Calculates the Greenwich Mean Sidereal Time. ## Function jdays() ### Description Converts calendar dates to Julian days. ## Function jdays2000() ### Description Converts calendar dates to Julian days relative to J2000. ## Function observer_position() ### Description Determines the observer's position. ## Function sun_earth_distance_correction() ### Description Applies a correction for the Sun-Earth distance. ## Function sun_ecliptic_longitude() ### Description Calculates the ecliptic longitude of the Sun. ## Function sun_ra_dec() ### Description Computes the Sun's right ascension and declination. ## Function sun_zenith_angle() ### Description Calculates the zenith angle of the Sun. ``` -------------------------------- ### Orbital Class Source: https://pyorbital.readthedocs.io/en/latest The Orbital class is the main interface for orbital computations. It allows users to initialize with satellite data (TLE), and provides methods to find satellite passes, calculate positions, and estimate crossing times. ```APIDOC ## Class Orbital ### Description Class for orbital computations. The _satellite_ parameter is the name of the satellite to work on and is used to retrieve the right TLE data for internet or from _tle_file_ in case it is provided. ### Methods - **find_aol(_utc_time_, _lon_, _lat_)**: Find Angle of Arrival (AOL). - **find_aos(_utc_time_, _lon_, _lat_)**: Find Angle of السقوط (AOS). - **get_equatorial_crossing_time(_tstart_, _tend_, _node ='ascending'_, _local_time =False_, _rtol =1e-09_)**: Estimate the equatorial crossing time of an orbit. The crossing time is determined via the orbit number, which increases by one if the spacecraft passes the ascending node at the equator. A bisection algorithm is used to find the time of that passage. Parameters: * **tstart** (datetime): Start time of the orbit. * **tend** (datetime): End time of the orbit. Orbit number at the end must be at least one greater than at the start. If there are multiple revolutions in the given time interval, the crossing time of the last revolution in that interval will be computed. * **node** (str): Specifies whether to compute the crossing time at the ascending or descending node. Choices: (‘ascending’, ‘descending’). * **local_time** (bool): By default the UTC crossing time is returned. Use this flag to convert UTC to local time. * **rtol** (float): Tolerance of the bisection algorithm. The smaller the tolerance, the more accurate the result. - **get_last_an_time(_utc_time_)**: Calculate time of last ascending node relative to the specified time. - **get_lonlatalt(_utc_time_)**: Calculate sub-longitude, sub-latitude, and altitude of the satellite. - **get_next_passes(_utc_time_, _length_, _lon_, _lat_, _alt_, _tol =0.001_, _horizon =0_)**: Calculate passes for the next hours for a given start time and a given observer. Parameters: * **utc_time** (datetime): Observation time. * **length** (int): Number of hours to find passes. * **lon** (float): Longitude of observer position on ground. * **lat** (float): Latitude of observer position on ground. * **alt** (float): Altitude above sea-level (geoid) in km of observer position on ground. * **tol** (float): Precision of the result in seconds. * **horizon** (float): The elevation of the horizon to compute rise time and fall time. Returns: [(rise-time, fall-time, max-elevation-time), …] - **get_observer_look(_utc_time_, _lon_, _lat_, _alt_)**: Calculate observer's look angle to a satellite. Parameters: * **utc_time** (datetime): Observation time. * **lon** (float): Longitude of observer position on ground in degrees east. * **lat** (float): Latitude of observer position on ground in degrees north. * **alt** (float): Altitude above sea-level (geoid) of observer position on ground in km. Returns: (Azimuth, Elevation) - **get_orbit_number(_utc_time_, _tbus_style =False_, _as_float =False_)**: Calculate orbit number at specified time. Parameters: * **utc_time** (datetime): UTC time as a datetime.datetime object. * **tbus_style** (bool): If True, use TBUS-style orbit numbering (TLE orbit number + 1). * **as_float** (bool): Return a continuous orbit number as float. - **get_position(_utc_time_, _normalize =True_)**: Get the cartesian position and velocity from the satellite. - **utc2local(_utc_time_)**: Convert UTC to local time. ``` -------------------------------- ### Tle Properties Source: https://pyorbital.readthedocs.io/en/latest Properties for accessing TLE data. ```APIDOC ## Tle Properties ### `excentricity` Get ‘eccentricity’ using legacy ‘excentricity’ name. ### `line1` Return first TLE line. ### `line2` Return second TLE line. ### `platform` Return satellite platform name. ``` -------------------------------- ### Orbital Error Exception Source: https://pyorbital.readthedocs.io/en/latest Custom exception class used within the Orbital module to handle specific orbital computation errors. ```APIDOC ## Exception OrbitalError ### Description Custom exception for the Orbital class. ``` -------------------------------- ### ChecksumError Exception Source: https://pyorbital.readthedocs.io/en/latest Custom exception raised when a TLE checksum is invalid. ```APIDOC ## _exception _pyorbital.tlefile.ChecksumError ### Description ChecksumError. ``` -------------------------------- ### gmst Source: https://pyorbital.readthedocs.io/en/latest Calculates the Greenwich mean sidereal time in radians. ```APIDOC ## pyorbital.astronomy.gmst(_utc_time_) ### Description Greenwich mean sidereal utc_time, in radians. As defined in the AIAA 2006 implementation: http://www.celestrak.com/publications/AIAA/2006-6753/ ### Parameters - `utc_time`: datetime.datetime instance of the UTC time. ### Returns Greenwich mean sidereal time in radians. ``` -------------------------------- ### sun_zenith_angle Source: https://pyorbital.readthedocs.io/en/latest Calculates the sun-zenith angle for a given longitude, latitude, and UTC time. ```APIDOC ## pyorbital.astronomy.sun_zenith_angle(_utc_time_, _lon_, _lat_) ### Description Sun-zenith angle for _lon_ , _lat_ at _utc_time_. ### Parameters - `utc_time`: datetime.datetime instance of the UTC time. - `lon`: Longitude in degrees. - `lat`: Latitude in degrees. ### Returns The sun zenith angle returned is in degrees. ``` -------------------------------- ### pyorbital.orbital.get_observer_look Source: https://pyorbital.readthedocs.io/en/latest Calculates the observer's look angle (azimuth and elevation) towards a satellite at a given time and location. ```APIDOC ## Function get_observer_look ### Description Calculate observers look angle to a satellite. ### Parameters - **sat_lon** (float): Satellite longitude. - **sat_lat** (float): Satellite latitude. - **sat_alt** (float): Satellite altitude. - **utc_time** (datetime): Observation time (datetime object). - **lon** (float): Longitude of observer position on ground in degrees east. - **lat** (float): Latitude of observer position on ground in degrees north. - **alt** (float): Altitude above sea-level (geoid) of observer position on ground in km. ### Returns (Azimuth, Elevation) ``` -------------------------------- ### jdays2000 Source: https://pyorbital.readthedocs.io/en/latest Calculates the number of days since the year 2000. ```APIDOC ## pyorbital.astronomy.jdays2000(_utc_time_) ### Description Get the days since year 2000. ### Parameters - `utc_time`: datetime.datetime instance of the UTC time. ### Returns Number of days since year 2000. ``` -------------------------------- ### Calculate Sun-Zenith Angle Source: https://pyorbital.readthedocs.io/en/latest/_sources/index.rst.txt Computes the Sun-zenith angle for a given time, longitude, and latitude using the pyorbital.astronomy module. This is useful for remote sensing applications. ```python >>> from pyorbital import astronomy >>> import datetime as dt >>> utc_time = dt.datetime(2012, 5, 15, 15, 45) >>> lon, lat = 12, 56 >>> astronomy.sun_zenith_angle(utc_time, lon, lat) 62.685986438071602 ``` -------------------------------- ### update_db Source: https://pyorbital.readthedocs.io/en/latest Updates the collected TLE data. Only data with a newer epoch than the existing one is used. ```APIDOC ## update_db ### Description Updates the collected TLE data. Only data with a newer epoch than the existing one is used. ### Parameters - `_tle_`: TLE data to update. - `_source_`: The source of the TLE data. ``` -------------------------------- ### OrbitElements Class Source: https://pyorbital.readthedocs.io/en/latest The OrbitElements class holds orbital elements and provides properties to compute derived values like apogee, perigee, and eccentricity. It also includes methods to check orbit characteristics such as circularity and retrogradeness. ```APIDOC ## Class OrbitElements ### Description Class holding the orbital elements. ### Properties - **apogee** (float): Compute apogee altitude in kilometers. - **excentricity** (float): Get ‘eccentricity’ using legacy ‘excentricity’ name. - **is_circular** (bool): Check if orbit is nearly circular. - **is_retrograde** (bool): Check if orbit is retrograde (inclination > 90°). - **perigee** (float): Compute perigee altitude in kilometers. ### Methods - **position_vector_in_orbital_plane()**: Compute position vector in the orbital plane at epoch. The x-axis points toward the perigee. - **velocity_at_apogee()**: Compute orbital velocity at apogee in km/s. - **velocity_at_perigee()**: Compute orbital velocity at perigee in km/s. ``` -------------------------------- ### Compute satellite position with specific TLE date Source: https://pyorbital.readthedocs.io/en/latest/_sources/index.rst.txt Calculate the longitude, latitude, and altitude of a satellite at a specific historical date using its TLE data. ```python from pyorbital.orbital import Orbital import datetime as dt orb = Orbital("Suomi NPP") dtobj = dt.datetime(2015,2,7,3,0) orb.get_lonlatalt(dtobj) ``` -------------------------------- ### pyorbital.orbital.kep2xyz Source: https://pyorbital.readthedocs.io/en/latest Converts Keplerian orbital elements to Cartesian coordinates (x, y, z). Note: The exact meaning of 'kep' is currently unclear and marked for future clarification. ```APIDOC ## Function kep2xyz ### Description Keplerian to Cartesian coordinates conversion. (Not sure what ‘kep’ actually refers to, just guessing! FIXME!) ### Parameters - **kep** (any): Keplerian orbital elements. ``` -------------------------------- ### sun_ecliptic_longitude Source: https://pyorbital.readthedocs.io/en/latest Calculates the ecliptic longitude of the sun at a given UTC time. ```APIDOC ## pyorbital.astronomy.sun_ecliptic_longitude(_utc_time_) ### Description Ecliptic longitude of the sun at _utc_time_. ### Parameters - `utc_time`: datetime.datetime instance of the UTC time. ### Returns The ecliptic longitude of the sun in radians. ``` -------------------------------- ### sun_earth_distance_correction Source: https://pyorbital.readthedocs.io/en/latest Calculates the sun-earth distance correction, relative to 1 AU. ```APIDOC ## pyorbital.astronomy.sun_earth_distance_correction(_utc_time_) ### Description Calculate the sun earth distance correction, relative to 1 AU. ### Parameters - `utc_time`: datetime.datetime instance of the UTC time. ### Returns The sun-earth distance correction. ``` === COMPLETE CONTENT === This response contains all available snippets from this library. No additional content exists. Do not make further requests.