HP Forums

Full Version: conversion from inertial to flight path coordinates
You're currently viewing a stripped down version of our content. View the full version with proper formatting.
This program demonstrates how to interact with two different HP PPL subroutines that convert an inertial state vector (position and velocity vectors) to flight path coordinates (east longitude, geocentric declination, flight path angle, azimuth, position magnitude and velocity magnitude).

This source code illustrates user-provided information required for a typical example.

// UTC julian day

jdutc := 2458337.833619444165379;

// eci position vector (kilometers)

reci(1) := -0.586479273288e4;
reci(2) := -0.178173078828e4;
reci(3) := -0.215629990858e4;

// eci velocity vector (kilometers/second)

veci(1) := 0.492973713131;
veci(2) := -0.731828662424e1;
veci(3) := 0.819193017342e1;

The software also includes a subroutine that can be used to convert an Earth-centered-fixed (ECF) position and velocity vector to an Earth-centered-inertial (ECI) position and velocity vectors. Here's the syntax along with a definition of the I/O for this subroutine.

ecf2eci(gast, recf, vecf)

// ecf-to-eci transformation

// input

// gast = greenwich apparent sidereal time (radians)
// (0 <= gast <= 2 pi)
// recf = position vector (kilometers)
// vecf = velocity vector (kilometers/second)

// output

// reci = position vector (kilometers)
// veci = velocity vector (kilometers/second)

The software and documentation for this demonstration program can be downloaded at

Reference URL's