Options
All
  • Public
  • Public/Protected
  • All
Menu

Class EphemerisTable

This class encapsulates the data and necessary methods for operating with look up ephemeris data. Users of the class pass in their ephemeris data as a data structure with the data and the settings for the ephemeris. The settings include things like the units, and the ephemeris representation. The ephemeris data itself is an array of arrays where each line constitute the necessary components of the line.

For 'cartesianposvel' style ephemeris each line of data looks like: [Julian Date, X, Y, Z, Vx, Vy, Vz]

Hierarchy

  • EphemerisTable

Index

Constructors

constructor

  • new EphemerisTable(ephemerisData: EphemerisTableData): EphemerisTable
  • Parameters

    • ephemerisData: EphemerisTableData

      Look up ephemeris data to initialize the table with and the properties of it

    Returns EphemerisTable

Properties

Private data

data: number[][]

Private ephemType

ephemType: "cartesianposvel"

Private interpolationOrder

interpolationOrder: number

Private interpolationType

interpolationType: "lagrange"

Private units

units: EphemerisTableUnits

Methods

Private calcBoundingIndices

  • calcBoundingIndices(jd: number): { startIndex: number; stopIndex: number }
  • Parameters

    • jd: number

    Returns { startIndex: number; stopIndex: number }

    • startIndex: number
    • stopIndex: number

Private calcDistanceMultiplier

  • calcDistanceMultiplier(unitType: DistanceUnits): number

Private calcTimeMultiplier

  • calcTimeMultiplier(unitType: TimeUnits): number

getPositionAtTime

  • Calculates the interpolated position for the given requested date. If the requested date is before the first point it returns the first point. If the requested date is after the last point it returns the last point.

    Parameters

    • jd: number

      of the requested time

    Returns Coordinate3d

    x, y, z position in the ephemeris table's reference frame

getPositions

  • getPositions(startJd: number, stopJd: number, stepDays: number): Coordinate3d[]
  • Given the start and stop time returns a uniform ephemeris history.

    Parameters

    • startJd: number

      the requested start date

    • stopJd: number

      the requested stop date

    • stepDays: number

      the step size of the data requested in days (can be fractional days)

    Returns Coordinate3d[]

Generated using TypeDoc