STK ObjectsSend comments on this topic.
IAgVePropagatorGreatArc Interface

Description

Great arc propagator interface.

Public Methods

Public Method ImportWaypointsFromFileImports waypoints from the filename specified. The filename must be an absolute path.
Public Method IsAltitudeRefTypeSupportedGets a value indicating whether the specified type can be used.
Public Method PropagatePropagates the vehicle's path using the specified time interval.
Public Method SetAltitudeRefTypeSpecifies Waypoint Altitude Reference.
Public Method SetPointsSmoothRateAndPropagateSets waypoints from the array and propagates the route. The array is two-dimensional where each sub-array contains waypoint's Latitude, Longitude, Altitude, Velocity and Turn Radius.
Public Method SetPointsSpecifyTimeAndPropagateSets waypoints from the array and propagates the route. The array is two-dimensional where each sub-array contains waypoint's Time, Latitude, Longitude, Altitude and Turn Radius. The array must be in non-decreasing order with respect to time. Time must be in UTCG format.
Public Method SetPointsSpecifyVelocityAndPropagateSets waypoints from the array and propagates the route. The array is two-dimensional where each sub-array contains waypoint's Latitude, Longitude, Altitude, Velocity, Acceleration and Turn Radius.

Public Properties

Public Property AltitudeRefGet the altitude reference.
Public Property AltitudeRefSupportedTypesReturns an array of valid choices.
Public Property AltitudeRefTypeReference altitude for waypoints.
Public Property ArcGranularityThe frequency of interpolated points. Uses Angle Dimension.
Public Property DefaultAltitudeThe default altitude used when the first waypoint is added. Uses Distance Dimension.
Public Property DefaultRateThe default rate used when the first waypoint is added. Uses Rate Dimension.
Public Property DefaultTurnRadiusThe default turn radius used when the first waypoint is added. Uses Distance Dimension.
Public Property EphemerisIntervalThe propagator's ephemeris interval.
Public Property MethodMethod for computing waypoints.
Public Property WaypointsGet the waypoints.

Interfaces

Implemented Interface
IAgVePropagator

CoClasses that Implement IAgVePropagatorGreatArc

Example

Set an aircraft to use Great Arc propagator
[C#]
// Set ship route to great arc
aircraft.SetRouteType(AgEVePropagatorType.ePropagatorGreatArc);

// Retrieve propagator interface
IAgVePropagatorGreatArc propagator = aircraft.Route as IAgVePropagatorGreatArc;
Configure an aircraft route using the Great Arc propagator
[C#]
// Set ship route to great arc
aircraft.SetRouteType(AgEVePropagatorType.ePropagatorGreatArc);

// Retrieve propagator interface
IAgVePropagatorGreatArc propagator = aircraft.Route as IAgVePropagatorGreatArc;
propagator.ArcGranularity = 51.333;

// Set Ref type to WayPtAltRefTerrain and retreive IAgVeWayPtAltitudeRefTerrain interface
propagator.SetAltitudeRefType(AgEVeAltitudeRef.eWayPtAltRefTerrain);
IAgVeWayPtAltitudeRefTerrain altRef = propagator.AltitudeRef as IAgVeWayPtAltitudeRefTerrain;
altRef.Granularity = 51.33;
altRef.InterpMethod = AgEVeWayPtInterpMethod.eWayPtEllipsoidHeight;

propagator.Method = AgEVeWayPtCompMethod.eDetermineTimeAccFromVel;

// Add waypoints
IAgVeWaypointsElement point1 = propagator.Waypoints.Add();
point1.Latitude = 39.7674;
point1.Longitude = -79.7292;
point1.Altitude = 3.0;
point1.Speed = 0.0772;

IAgVeWaypointsElement point2 = propagator.Waypoints.Add();
point2.Latitude = 38.3721;
point2.Longitude = -120.1160;
point2.Altitude = 3.0;
point2.Speed = 0.0772;

// Propagate
propagator.Propagate();
Set ground vehicle to use Great Arc propagator
[C#]
// Set ground vehicle route to great arc
groundVehicle.SetRouteType(AgEVePropagatorType.ePropagatorGreatArc);

// Retrieve propagator interface if necessary
IAgVePropagatorGreatArc propagator = groundVehicle.Route as IAgVePropagatorGreatArc;
Set ship to use Great Arc propagator
[C#]
// Set ship route to great arc
ship.SetRouteType(AgEVePropagatorType.ePropagatorGreatArc);

// Retrieve propagator interface if necessary
IAgVePropagatorGreatArc propagator = ship.Route as IAgVePropagatorGreatArc;
Configure the Great Arc propagator with a list of waypoints
[C#]
// Array with waypoints to insert
object[,] waypoints = new object[,] 
    {
        { 20.36, 40.040, -76.304, "1 Jan 2012 12:00:00.000" }, 
        { 20.30, 40.337, -75.922, "1 Jan 2012 13:00:00.000" }, 
        { 20.30, 40.028, -75.628, "1 Jan 2012 14:00:00.000" } 
    };

propagator.Method = AgEVeWayPtCompMethod.eDetermineVelFromTime;

// Remove any previous waypoints
propagator.Waypoints.RemoveAll();

// Insert the waypoints
for (int i = 0; i < waypoints.GetLength(0); i++)
{
    IAgVeWaypointsElement waypoint = propagator.Waypoints.Add();
    waypoint.Altitude = (double) waypoints[i, 0];
    waypoint.Latitude = waypoints[i, 1];
    waypoint.Longitude = waypoints[i, 2];
    waypoint.Time = waypoints[i, 3];
}

// Propagate ground vehicle
propagator.Propagate();
Configure the Great Arc propagator with a list of waypoints and velocity
[C#]
// Array with waypoints to insert
// Consists of: altitude, latitude, longitude, speed
double[,] waypoints = new double[,]
    {
        { 20.36, 40.040, -76.304, 10.5 },
        { 20.30, 40.337, -75.922, 12.5 }, 
        { 20.30, 40.028, -75.628, 15.0 } 
    };

propagator.Method = AgEVeWayPtCompMethod.eDetermineTimeAccFromVel;

// Remove any previous waypoints
propagator.Waypoints.RemoveAll();

// Insert the waypoints
for (int i = 0; i < waypoints.GetLength(0); i++)
{
    IAgVeWaypointsElement waypoint = propagator.Waypoints.Add();
    waypoint.Altitude = waypoints[i, 0];
    waypoint.Latitude = waypoints[i, 1];
    waypoint.Longitude = waypoints[i, 2];
    waypoint.Speed = waypoints[i, 3];
}

// Propagate ground vehicle
propagator.Propagate();
Sets the ephemeris start time to an explicit time, and then add waypoints relative to that time.
[C#]
// Set the epoch time to tomorrow.
IAgCrdnEventSmartEpoch startEpoch = propagator.EphemerisInterval.GetStartEpoch();
startEpoch.SetExplicitTime("Tomorrow");
propagator.EphemerisInterval.SetStartEpoch(startEpoch);

// Waypoints time start from explicit start time that we set above.
Array waypointsAndTimes = new object[,]
{
    { 40.329, -76.366, 0, 0.0154, 0 },
    { 40.380, -76.359, 0, 0.0154, 0 },
    { 40.406, -76.329, 0, 0.0154, 0 },
    { 40.417, -76.311, 0, 0.0154, 0 },
};

propagator.SetPointsSmoothRateAndPropagate(ref waypointsAndTimes);

for (int i = 0; i < propagator.Waypoints.Count; ++i)
{
    Console.WriteLine("Waypoint {0}, Lat = {1}, Lon = {2}, Time = {3}",
        i,
        propagator.Waypoints[i].Latitude,
        propagator.Waypoints[i].Longitude,
        propagator.Waypoints[i].Time);
}
Set Waypoints (Derive Velocity from Time) and Propagate
[C#]
propagator.Method = AgEVeWayPtCompMethod.eDetermineVelFromTime;

Array waypoints = Array.CreateInstance(typeof(object), 4, 5);
// Point #1
waypoints.SetValue("17 Jan 2013 17:00:00.000", 0, 0); // Time
waypoints.SetValue(0.0, 0, 1); // Lat
waypoints.SetValue(0.0, 0, 2); // Lon
waypoints.SetValue(35000, 0, 3); // Alt
waypoints.SetValue(0.0, 0, 4); // Turn radius

// Point #2
waypoints.SetValue("17 Jan 2013 17:01:00.000", 1, 0); // Time
waypoints.SetValue(0.1, 1, 1); // Lat
waypoints.SetValue(0.1, 1, 2); // Lon
waypoints.SetValue(35100, 1, 3); // Alt
waypoints.SetValue(0.2, 1, 4); // Turn radius

// Point #3
waypoints.SetValue("17 Jan 2013 17:02:00.000", 2, 0); // Time
waypoints.SetValue(0.2, 2, 1); // Lat
waypoints.SetValue(0.2, 2, 2); // Lon
waypoints.SetValue(35200, 2, 3); // Alt
waypoints.SetValue(0.0, 2, 4); // Turn radius

// Point #4
waypoints.SetValue("17 Jan 2013 17:03:00.000", 3, 0); // Time
waypoints.SetValue(0.0, 3, 1); // Lat
waypoints.SetValue(0.0, 3, 2); // Lon
waypoints.SetValue(35200, 3, 3); // Alt
waypoints.SetValue(0.0, 3, 4); // Turn radius

propagator.SetPointsSpecifyTimeAndPropagate(ref waypoints);

Assert.AreEqual(4, propagator.Waypoints.Count);
Set Waypoints (Derive Time and Acceleration from Velocity) and Propagate
[C#]
propagator.Method = AgEVeWayPtCompMethod.eDetermineTimeAccFromVel;

Array waypoints = Array.CreateInstance(typeof(object), 4, 6);

// Point #1
waypoints.SetValue(0.0, 0, 0); // Lat
waypoints.SetValue(0.0, 0, 1); // Lon
waypoints.SetValue(35000, 0, 2); // Alt
waypoints.SetValue(35, 0, 3); // Vel
waypoints.SetValue(0.0, 0, 4); // Acc
waypoints.SetValue(0.0, 0, 5); // Turn radius

// Point #2
waypoints.SetValue(0.1, 1, 0); // Lat
waypoints.SetValue(0.1, 1, 1); // Lon
waypoints.SetValue(35100, 1, 2); // Alt
waypoints.SetValue(35, 1, 3); // Vel
waypoints.SetValue(0.0, 1, 4); // Acc
waypoints.SetValue(0.2, 1, 5); // Turn radius

// Point #3
waypoints.SetValue(0.2, 2, 0); // Lat
waypoints.SetValue(0.2, 2, 1); // Lon
waypoints.SetValue(35200, 2, 2); // Alt
waypoints.SetValue(35, 2, 3); // Vel
waypoints.SetValue(0.0, 2, 4); // Acc
waypoints.SetValue(0.0, 2, 5); // Turn radius

// Point #4
waypoints.SetValue(0.0, 3, 0); // Lat
waypoints.SetValue(0.0, 3, 1); // Lon
waypoints.SetValue(35200, 3, 2); // Alt
waypoints.SetValue(35, 3, 3); // Vel
waypoints.SetValue(0.0, 3, 4); // Acc
waypoints.SetValue(0.0, 3, 5); // Turn radius

propagator.SetPointsSpecifyVelocityAndPropagate(ref waypoints);

Assert.AreEqual(4, propagator.Waypoints.Count);
Set Waypoints (Derive Time from Velocity and Acceleration) and Propagate
[C#]
propagator.Method = AgEVeWayPtCompMethod.eDetermineTimeFromVelAcc;

Array waypoints = Array.CreateInstance(typeof(object), 4, 5);
// Point #1
waypoints.SetValue(0.0, 0, 0); // Lat
waypoints.SetValue(0.0, 0, 1); // Lon
waypoints.SetValue(35000, 0, 2); // Alt
waypoints.SetValue(35, 0, 3); // Vel
waypoints.SetValue(0.0, 0, 4); // Turn radius
// Point #2
waypoints.SetValue(0.1, 1, 0); // Lat
waypoints.SetValue(0.1, 1, 1); // Lon
waypoints.SetValue(35100, 1, 2); // Alt
waypoints.SetValue(35, 1, 3); // Vel
waypoints.SetValue(0.2, 1, 4); // Turn radius
// Point #3
waypoints.SetValue(0.2, 2, 0); // Lat
waypoints.SetValue(0.2, 2, 1); // Lon
waypoints.SetValue(35200, 2, 2); // Alt
waypoints.SetValue(35, 2, 3); // Vel
waypoints.SetValue(0.0, 2, 4); // Turn radius
// Point #4
waypoints.SetValue(0.0, 3, 0); // Lat
waypoints.SetValue(0.0, 3, 1); // Lon
waypoints.SetValue(35200, 3, 2); // Alt
waypoints.SetValue(35, 3, 3); // Vel
waypoints.SetValue(0.0, 3, 4); // Turn radius

propagator.SetPointsSmoothRateAndPropagate(ref waypoints);

Assert.AreEqual(4, propagator.Waypoints.Count);
Configure the Great Arc propagator with a list of waypoints
[Visual Basic .NET]
' Array with waypoints to insert
Dim waypoints As Object(,) = New Object(,) {{20.36, 40.04, -76.304, "1 Jan 2012 12:00:00.000"}, {20.3, 40.337, -75.922, "1 Jan 2012 13:00:00.000"}, {20.3, 40.028, -75.628, "1 Jan 2012 14:00:00.000"}}

propagator.Method = AgEVeWayPtCompMethod.eDetermineVelFromTime

' Remove any previous waypoints
propagator.Waypoints.RemoveAll()

' Insert the waypoints
Dim i As Integer = 0
While i < waypoints.GetLength(0)
	Dim waypoint As IAgVeWaypointsElement = propagator.Waypoints.Add()
	waypoint.Altitude = DirectCast(waypoints(i, 0), Double)
	waypoint.Latitude = waypoints(i, 1)
	waypoint.Longitude = waypoints(i, 2)
	waypoint.Time = waypoints(i, 3)
	System.Math.Max(System.Threading.Interlocked.Increment(i),i - 1)
End While

' Propagate ground vehicle
propagator.Propagate()
Configure the Great Arc propagator with a list of waypoints and velocity
[Visual Basic .NET]
' Array with waypoints to insert
' Consists of: altitude, latitude, longitude, speed
Dim waypoints As Double(,) = New Double(,) {{20.36, 40.04, -76.304, 10.5}, {20.3, 40.337, -75.922, 12.5}, {20.3, 40.028, -75.628, 15}}

propagator.Method = AgEVeWayPtCompMethod.eDetermineTimeAccFromVel

' Remove any previous waypoints
propagator.Waypoints.RemoveAll()

' Insert the waypoints
Dim i As Integer = 0
While i < waypoints.GetLength(0)
	Dim waypoint As IAgVeWaypointsElement = propagator.Waypoints.Add()
	waypoint.Altitude = waypoints(i, 0)
	waypoint.Latitude = waypoints(i, 1)
	waypoint.Longitude = waypoints(i, 2)
	waypoint.Speed = waypoints(i, 3)
	System.Math.Max(System.Threading.Interlocked.Increment(i),i - 1)
End While

' Propagate ground vehicle
propagator.Propagate()
Sets the ephemeris start time to an explicit time, and then add waypoints relative to that time.
[Visual Basic .NET]
' Set the epoch time to tomorrow.
Dim startEpoch As IAgCrdnEventSmartEpoch = propagator.EphemerisInterval.GetStartEpoch()
startEpoch.SetExplicitTime("Tomorrow")
propagator.EphemerisInterval.SetStartEpoch(startEpoch)

' Waypoints time start from explicit start time that we set above.
Dim waypointsAndTimes As Array = New Object(,) {{40.329, -76.366, 0, 0.0154, 0}, {40.38, -76.359, 0, 0.0154, 0}, {40.406, -76.329, 0, 0.0154, 0}, {40.417, -76.311, 0, 0.0154, 0}}

propagator.SetPointsSmoothRateAndPropagate(waypointsAndTimes)

Dim i As Integer = 0
While i < propagator.Waypoints.Count
	Console.WriteLine("Waypoint {0}, Lat = {1}, Lon = {2}, Time = {3}", i, propagator.Waypoints(i).Latitude, propagator.Waypoints(i).Longitude, propagator.Waypoints(i).Time)
	System.Threading.Interlocked.Increment(i)
End While
Set Waypoints (Derive Velocity from Time) and Propagate
[Visual Basic .NET]
propagator.Method = AgEVeWayPtCompMethod.eDetermineVelFromTime

Dim waypoints As Array = Array.CreateInstance(GetType(Object), 4, 5)
' Point #1
waypoints.SetValue("17 Jan 2013 17:00:00.000", 0, 0)
' Time
waypoints.SetValue(0, 0, 1)
' Lat
waypoints.SetValue(0, 0, 2)
' Lon
waypoints.SetValue(35000, 0, 3)
' Alt
waypoints.SetValue(0, 0, 4)
' Turn radius
' Point #2
waypoints.SetValue("17 Jan 2013 17:01:00.000", 1, 0)
' Time
waypoints.SetValue(0.1, 1, 1)
' Lat
waypoints.SetValue(0.1, 1, 2)
' Lon
waypoints.SetValue(35100, 1, 3)
' Alt
waypoints.SetValue(0.2, 1, 4)
' Turn radius
' Point #3
waypoints.SetValue("17 Jan 2013 17:02:00.000", 2, 0)
' Time
waypoints.SetValue(0.2, 2, 1)
' Lat
waypoints.SetValue(0.2, 2, 2)
' Lon
waypoints.SetValue(35200, 2, 3)
' Alt
waypoints.SetValue(0, 2, 4)
' Turn radius
' Point #4
waypoints.SetValue("17 Jan 2013 17:03:00.000", 3, 0)
' Time
waypoints.SetValue(0, 3, 1)
' Lat
waypoints.SetValue(0, 3, 2)
' Lon
waypoints.SetValue(35200, 3, 3)
' Alt
waypoints.SetValue(0, 3, 4)
' Turn radius
propagator.SetPointsSpecifyTimeAndPropagate(waypoints)

Assert.AreEqual(4, propagator.Waypoints.Count)
Set Waypoints (Derive Time and Acceleration from Velocity) and Propagate
[Visual Basic .NET]
propagator.Method = AgEVeWayPtCompMethod.eDetermineTimeAccFromVel

Dim waypoints As Array = Array.CreateInstance(GetType(Object), 4, 6)

' Point #1
waypoints.SetValue(0, 0, 0)
' Lat
waypoints.SetValue(0, 0, 1)
' Lon
waypoints.SetValue(35000, 0, 2)
' Alt
waypoints.SetValue(35, 0, 3)
' Vel
waypoints.SetValue(0, 0, 4)
' Acc
waypoints.SetValue(0, 0, 5)
' Turn radius
' Point #2
waypoints.SetValue(0.1, 1, 0)
' Lat
waypoints.SetValue(0.1, 1, 1)
' Lon
waypoints.SetValue(35100, 1, 2)
' Alt
waypoints.SetValue(35, 1, 3)
' Vel
waypoints.SetValue(0, 1, 4)
' Acc
waypoints.SetValue(0.2, 1, 5)
' Turn radius
' Point #3
waypoints.SetValue(0.2, 2, 0)
' Lat
waypoints.SetValue(0.2, 2, 1)
' Lon
waypoints.SetValue(35200, 2, 2)
' Alt
waypoints.SetValue(35, 2, 3)
' Vel
waypoints.SetValue(0, 2, 4)
' Acc
waypoints.SetValue(0, 2, 5)
' Turn radius
' Point #4
waypoints.SetValue(0, 3, 0)
' Lat
waypoints.SetValue(0, 3, 1)
' Lon
waypoints.SetValue(35200, 3, 2)
' Alt
waypoints.SetValue(35, 3, 3)
' Vel
waypoints.SetValue(0, 3, 4)
' Acc
waypoints.SetValue(0, 3, 5)
' Turn radius
propagator.SetPointsSpecifyVelocityAndPropagate(waypoints)

Assert.AreEqual(4, propagator.Waypoints.Count)
Set Waypoints (Derive Time from Velocity and Acceleration) and Propagate
[Visual Basic .NET]
propagator.Method = AgEVeWayPtCompMethod.eDetermineTimeFromVelAcc

Dim waypoints As Array = Array.CreateInstance(GetType(Object), 4, 5)
' Point #1
waypoints.SetValue(0, 0, 0)
' Lat
waypoints.SetValue(0, 0, 1)
' Lon
waypoints.SetValue(35000, 0, 2)
' Alt
waypoints.SetValue(35, 0, 3)
' Vel
waypoints.SetValue(0, 0, 4)
' Turn radius
' Point #2
waypoints.SetValue(0.1, 1, 0)
' Lat
waypoints.SetValue(0.1, 1, 1)
' Lon
waypoints.SetValue(35100, 1, 2)
' Alt
waypoints.SetValue(35, 1, 3)
' Vel
waypoints.SetValue(0.2, 1, 4)
' Turn radius
' Point #3
waypoints.SetValue(0.2, 2, 0)
' Lat
waypoints.SetValue(0.2, 2, 1)
' Lon
waypoints.SetValue(35200, 2, 2)
' Alt
waypoints.SetValue(35, 2, 3)
' Vel
waypoints.SetValue(0, 2, 4)
' Turn radius
' Point #4
waypoints.SetValue(0, 3, 0)
' Lat
waypoints.SetValue(0, 3, 1)
' Lon
waypoints.SetValue(35200, 3, 2)
' Alt
waypoints.SetValue(35, 3, 3)
' Vel
waypoints.SetValue(0, 3, 4)
' Turn radius
propagator.SetPointsSmoothRateAndPropagate(waypoints)

Assert.AreEqual(4, propagator.Waypoints.Count)
Set an aircraft to use Great Arc propagator
[Visual Basic .NET]
' Set ship route to great arc
aircraft.SetRouteType(AgEVePropagatorType.ePropagatorGreatArc)

' Retrieve propagator interface
Dim propagator As IAgVePropagatorGreatArc = TryCast(aircraft.Route, IAgVePropagatorGreatArc)
Configure an aircraft route using the Great Arc propagator
[Visual Basic .NET]
' Set ship route to great arc
aircraft.SetRouteType(AgEVePropagatorType.ePropagatorGreatArc)

' Retrieve propagator interface
Dim propagator As IAgVePropagatorGreatArc = TryCast(aircraft.Route, IAgVePropagatorGreatArc)
propagator.ArcGranularity = 51.333

' Set Ref type to WayPtAltRefTerrain and retreive IAgVeWayPtAltitudeRefTerrain interface
propagator.SetAltitudeRefType(AgEVeAltitudeRef.eWayPtAltRefTerrain)
Dim altRef As IAgVeWayPtAltitudeRefTerrain = TryCast(propagator.AltitudeRef, IAgVeWayPtAltitudeRefTerrain)
altRef.Granularity = 51.33
altRef.InterpMethod = AgEVeWayPtInterpMethod.eWayPtEllipsoidHeight

propagator.Method = AgEVeWayPtCompMethod.eDetermineTimeAccFromVel

' Add waypoints
Dim point1 As IAgVeWaypointsElement = propagator.Waypoints.Add()
point1.Latitude = 39.7674
point1.Longitude = -79.7292
point1.Altitude = 3
point1.Speed = 0.0772

Dim point2 As IAgVeWaypointsElement = propagator.Waypoints.Add()
point2.Latitude = 38.3721
point2.Longitude = -120.116
point2.Altitude = 3
point2.Speed = 0.0772

' Propagate
propagator.Propagate()
Set ground vehicle to use Great Arc propagator
[Visual Basic .NET]
' Set ground vehicle route to great arc
groundVehicle.SetRouteType(AgEVePropagatorType.ePropagatorGreatArc)

' Retrieve propagator interface if necessary
Dim propagator As IAgVePropagatorGreatArc = TryCast(groundVehicle.Route, IAgVePropagatorGreatArc)
Set ship to use Great Arc propagator
[Visual Basic .NET]
' Set ship route to great arc
ship.SetRouteType(AgEVePropagatorType.ePropagatorGreatArc)

' Retrieve propagator interface if necessary
Dim propagator As IAgVePropagatorGreatArc = TryCast(ship.Route, IAgVePropagatorGreatArc)
Set the Propagator to GreatArc and set the start time
[MATLAB]
% IAgAircraft aircraft: Aircraft object
% Set the propagator to GreatArc
aircraft.SetRouteType('ePropagatorGreatArc');

% Set the start time to a new start time
aircraft.Route.EphemerisInterval.SetExplicitInterval('25 Dec 2019 00:00:00.00', '25 Dec 2019 00:00:00.00'); % stop time computed based on Propagate call
aircraft.Route.Propagate();

        
© 2024 Analytical Graphics, Inc. All Rights Reserved.