Package gaiasky.data.orbit
Class HeliotropicOrbitDataLoader
java.lang.Object
gaiasky.data.orbit.HeliotropicOrbitDataLoader
public class HeliotropicOrbitDataLoader
extends java.lang.Object
-
Constructor Summary
Constructors Constructor Description HeliotropicOrbitDataLoader()
-
Method Summary
Modifier and Type Method Description protected Vector3d
correctSunLongitude(Vector3d pos, java.time.Instant t)
Transforms the given vector to a heliotropic system using the given time.protected Vector3d
correctSunLongitude(Vector3d pos, java.time.Instant t, float origin)
Transforms the given vector to a heliotropic system using the given time.PointCloudData
load(java.io.InputStream data)
Loads the data in the input stream and transforms it into Cartesian ecliptic coordinates.static void
main(java.lang.String[] args)
protected double
parsed(java.lang.String str)
protected float
parsef(java.lang.String str)
protected int
parsei(java.lang.String str)
void
writeDistVsTimeData(java.lang.String filePath, PointCloudData data)
Writes a file under the given path with the distance dataMethods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
-
Constructor Details
-
HeliotropicOrbitDataLoader
public HeliotropicOrbitDataLoader()
-
-
Method Details
-
main
public static void main(java.lang.String[] args) -
load
Loads the data in the input stream and transforms it into Cartesian ecliptic coordinates. The reference system of the data goes as follows:- Origin of frame : Earth
- X and Y axis in the EQUATORIAL PLANE with X pointing in the direction of vernal equinox.
- Z perpendicular to the the EQUATORIAL PLANE in the north direction
- The Y direction is defined to have (X,Y,Z) as a "three axis" positively oriented.
- - XZ lies in the ECLIPTIC PLANE, with Z pointing to the vernal equinox.
- - Y perpendicular to the ECLIPTIC PLANE pointing north.
- Parameters:
data
- The input stream with the data to load- Throws:
java.lang.Exception
-
parsef
protected float parsef(java.lang.String str) -
parsed
protected double parsed(java.lang.String str) -
parsei
protected int parsei(java.lang.String str) -
correctSunLongitude
Transforms the given vector to a heliotropic system using the given time.- Parameters:
pos
- Position vectort
- Time- Returns:
- Vector3 with the position in the heliotropic reference frame
-
correctSunLongitude
Transforms the given vector to a heliotropic system using the given time.- Parameters:
pos
- Position vectort
- Timeorigin
- The origin angle- Returns:
- Vector3 with the position in the heliotropic reference frame
-
writeDistVsTimeData
public void writeDistVsTimeData(java.lang.String filePath, PointCloudData data) throws java.lang.ExceptionWrites a file under the given path with the distance data- Throws:
java.lang.Exception
-