Skyfield: Home • Table of Contents • Changelog • API Reference
skyfield.planetarylib.PlanetaryConstants¶Planetary constants manager.
You can use this class to build working models of Solar System bodies by loading text planetary constant files and binary orientation kernels. For a full description of how to use this, see Planetary Reference Frames.
read_text(file)¶Read frame variables from a KPL/FK file.
Appropriate files will typically have the extension .tf or
.tpc and will define a series of names and values that will
be loaded into this object’s .variables dictionary.
>>> from skyfield.api import load
>>> pc = PlanetaryConstants()
>>> pc.read_text(load('moon_080317.tf'))
>>> pc.variables['FRAME_31006_NAME']
'MOON_PA_DE421'
read_binary(file)¶Read binary segments descriptions from a DAF/PCK file.
Binary segments live in .bpc files and predict how a body
like a planet or moon will be oriented on a given date.
build_latlon_degrees(frame, latitude_degrees, longitude_degrees, elevation_m=0.0)¶Build an object representing a location on a body’s surface.
skyfield.planetarylib.Frame(center, segment, matrix)¶Planetary constants frame, for building rotation matrices.
rotation_at(t)¶Return the rotation matrix for this frame at time t.
rotation_and_rate_at(t)¶Return rotation and rate matrices for this frame at time t.
The rate matrix returned is in units of angular motion per day.