Safe Haskell | Safe-Inferred |
---|---|
Language | Haskell2010 |
Synopsis
- data StateVectors a = StateVectors {}
- type Position a = V3 (Distance a)
- type Velocity a = V3 (Speed a)
- stateVectorsAtTrueAnomaly :: (Conjugate a, RealFloat a) => Orbit a -> Angle a -> StateVectors a
- positionAtTrueAnomaly :: (Conjugate a, RealFloat a) => Orbit a -> Angle a -> Position a
- positionInPlaneAtTrueAnomaly :: (Ord a, Floating a) => Orbit a -> Angle a -> Position a
- velocityAtTrueAnomaly :: (Conjugate a, RealFloat a) => Orbit a -> Angle a -> Velocity a
- velocityInPlaneAtTrueAnomaly :: (Ord a, Floating a) => Orbit a -> Angle a -> Velocity a
- elementsFromStateVectors :: (Ord a, Floating a, Conjugate a, RealFloat a, Show a) => Quantity ((:*) ((:^) Meter (Succ (Succ (Succ 'Zero)))) ((:^) Second (Pred (Pred 'Zero)))) a -> StateVectors a -> (Orbit a, Angle a)
- eccentricityVector :: Floating a => Quantity ((:*) ((:^) Meter (Succ (Succ (Succ 'Zero)))) ((:^) Second (Pred (Pred 'Zero)))) a -> StateVectors a -> V3 (Unitless a)
- trueAnomalyAtPosition :: (Conjugate a, RealFloat a) => Orbit a -> Position a -> Angle a
- orbitalPlaneQuaternion :: RealFloat a => Orbit a -> Quaternion a
- rotateToPlane :: (Conjugate a, RealFloat a) => Orbit a -> V3 (Qu u l a) -> V3 (Qu u l a)
- rotateFromPlane :: (Conjugate a, RealFloat a) => Orbit a -> V3 (Qu u l a) -> V3 (Qu u l a)
- flightPathAngleAtTrueAnomaly :: (Real a, Floating a) => Orbit a -> Angle a -> Angle a
- specificAngularMomentumVector :: Num a => StateVectors a -> V3 (Quantity ((:/) ((:^) Meter (Succ (Succ 'Zero))) Second) a)
Types
data StateVectors a Source #
Instances
Show a => Show (StateVectors a) Source # | |
Defined in Physics.Orbit.StateVectors showsPrec :: Int -> StateVectors a -> ShowS # show :: StateVectors a -> String # showList :: [StateVectors a] -> ShowS # | |
Eq a => Eq (StateVectors a) Source # | |
Defined in Physics.Orbit.StateVectors (==) :: StateVectors a -> StateVectors a -> Bool # (/=) :: StateVectors a -> StateVectors a -> Bool # |
Conversion to state vectors
stateVectorsAtTrueAnomaly :: (Conjugate a, RealFloat a) => Orbit a -> Angle a -> StateVectors a Source #
positionAtTrueAnomaly :: (Conjugate a, RealFloat a) => Orbit a -> Angle a -> Position a Source #
Get the position in space of a body after rotating it according to the inclination and periapsis specifier.
positionInPlaneAtTrueAnomaly :: (Ord a, Floating a) => Orbit a -> Angle a -> Position a Source #
Get the position of a body relative to the orbital plane
velocityAtTrueAnomaly :: (Conjugate a, RealFloat a) => Orbit a -> Angle a -> Velocity a Source #
Get the velocity in space of a body after rotating it according to the inclination and periapsis specifier.
velocityInPlaneAtTrueAnomaly :: (Ord a, Floating a) => Orbit a -> Angle a -> Velocity a Source #
The in-plane velocity of a body
Conversion from state vectors
elementsFromStateVectors :: (Ord a, Floating a, Conjugate a, RealFloat a, Show a) => Quantity ((:*) ((:^) Meter (Succ (Succ (Succ 'Zero)))) ((:^) Second (Pred (Pred 'Zero)))) a -> StateVectors a -> (Orbit a, Angle a) Source #
eccentricityVector :: Floating a => Quantity ((:*) ((:^) Meter (Succ (Succ (Succ 'Zero)))) ((:^) Second (Pred (Pred 'Zero)))) a -> StateVectors a -> V3 (Unitless a) Source #
Calculate the eccentricity vector, e, given state vectors
trueAnomalyAtPosition :: (Conjugate a, RealFloat a) => Orbit a -> Position a -> Angle a Source #
Calculate the true anomaly, ν, of a body at position, r, given its orbital elements.
Rotations to and from orbital plane
orbitalPlaneQuaternion :: RealFloat a => Orbit a -> Quaternion a Source #
A quaternion representing the rotation of the orbital plane
rotateToPlane :: (Conjugate a, RealFloat a) => Orbit a -> V3 (Qu u l a) -> V3 (Qu u l a) Source #
Rotate a position such that is is relative to the orbital plane according to the inclination specifier and periapsis specifier.
The orbital plane is perpendicular to the z axis
rotateFromPlane :: (Conjugate a, RealFloat a) => Orbit a -> V3 (Qu u l a) -> V3 (Qu u l a) Source #
Rotate a position relative to the orbital plane according to the inclination specifier and periapsis specifier.
The orbital plane is perpendicular to the z axis