public interface BodyShape extends PVCoordinatesProvider
Modifier and Type | Interface and Description |
---|---|
static class |
BodyShape.MarginType
Margin type.
|
Modifier and Type | Field and Description |
---|---|
static double |
EPS_ALTITUDE
Epsilon altitude below which
getIntersectionPoint(Line, Vector3D, Frame, AbsoluteDate) will be
automatically used instead of getIntersectionPoint(Line, Vector3D, Frame, AbsoluteDate, double) . |
Modifier and Type | Method and Description |
---|---|
default Vector3D[] |
closestPointTo(Line line)
This method computes the two points, on the line and on the body, that are the closest to each other.
|
Vector3D[] |
closestPointTo(Line line,
Frame frame,
AbsoluteDate date)
This method computes the two points, on the line and on the body, that are the closest to each other.
|
double |
distanceTo(Line line,
Frame frame,
AbsoluteDate date)
Computes the distance to a line.
|
double |
getApparentRadius(PVCoordinatesProvider pvObserver,
AbsoluteDate date,
PVCoordinatesProvider occultedBody,
AbstractDetector.PropagationDelayType propagationDelayType)
Compute the apparent radius (in meters) of the occulting body from the spacecraft (observer) position.
|
Frame |
getBodyFrame()
Get body frame related to body shape.
|
GeodeticPoint |
getIntersectionPoint(Line line,
Vector3D close,
Frame frame,
AbsoluteDate date)
Get the intersection point of a line with the surface of the body.
|
GeodeticPoint |
getIntersectionPoint(Line line,
Vector3D close,
Frame frame,
AbsoluteDate date,
double altitude)
Get the intersection point of a line with the surface of the body for a given altitude.
|
Vector3D[] |
getIntersectionPoints(Line line,
Frame frame,
AbsoluteDate date)
Compute the intersection points with a line.
|
String |
getName() |
BodyShape |
resize(BodyShape.MarginType marginType,
double marginValue)
Resize the geometric body shape by a margin.
|
Vector3D |
transform(GeodeticPoint point)
Transform a surface-relative point to a cartesian point.
|
GeodeticPoint |
transform(Vector3D point,
Frame frame,
AbsoluteDate date)
Transform a cartesian point to a surface-relative point.
|
GeodeticPoint |
transformFromZenith(Vector3D point,
Vector3D zenith,
Frame frame,
AbsoluteDate date)
Computes a geodetic point from a normal vector by using spherical coordinates.
|
getNativeFrame, getPVCoordinates
static final double EPS_ALTITUDE
getIntersectionPoint(Line, Vector3D, Frame, AbsoluteDate)
will be
automatically used instead of getIntersectionPoint(Line, Vector3D, Frame, AbsoluteDate, double)
.String getName()
Frame getBodyFrame()
Vector3D[] getIntersectionPoints(Line line, Frame frame, AbsoluteDate date) throws PatriusException
line
- the lineframe
- in which line is expresseddate
- date of the line in given framePatriusException
- if line cannot be converted to body frameGeodeticPoint getIntersectionPoint(Line line, Vector3D close, Frame frame, AbsoluteDate date, double altitude) throws PatriusException
A line may have several intersection points with a closed surface (we consider the one point case as a degenerated two points case). The close parameter is used to select which of these points should be returned. The selected point is the one that is closest to the close point.
line
- test line (may intersect the body or not)close
- point used for intersections selection expressed in the body frameframe
- frame in which line is expresseddate
- date of the line in given framealtitude
- altitude of the intersectionPatriusException
- if line cannot be converted to body frameGeodeticPoint getIntersectionPoint(Line line, Vector3D close, Frame frame, AbsoluteDate date) throws PatriusException
A line may have several intersection points with a closed surface (we consider the one point case as a degenerated two points case). The close parameter is used to select which of these points should be returned. The selected point is the one that is closest to the close point.
line
- test line (may intersect the body or not)close
- point used for intersections selection expressed in the body frameframe
- frame in which line is expresseddate
- date of the line in given framePatriusException
- if line cannot be converted to body framedouble distanceTo(Line line, Frame frame, AbsoluteDate date) throws PatriusException
line
- the lineframe
- in which line is expresseddate
- date of the line in given framePatriusException
- if line cannot be converted to body framedouble getApparentRadius(PVCoordinatesProvider pvObserver, AbsoluteDate date, PVCoordinatesProvider occultedBody, AbstractDetector.PropagationDelayType propagationDelayType) throws PatriusException
pvObserver
- the spacecraft (observer) position-velocitydate
- the date at which the signal is received by the observer (reception date)occultedBody
- the body which is occulted to the spacecraft (observer) by the occulting bodypropagationDelayType
- propagation delay typePatriusException
- if the PVCoordinatesProvider
computation failsBodyShape resize(BodyShape.MarginType marginType, double marginValue) throws PatriusException
marginType
- margin type to be usedmarginValue
- margin value to be used (in meters if the margin type is DISTANCE)PatriusException
- if the margin value is invalidGeodeticPoint transform(Vector3D point, Frame frame, AbsoluteDate date) throws PatriusException
point
- cartesian pointframe
- frame in which cartesian point is expresseddate
- date of the computation (used for frames conversions)PatriusException
- if point cannot be converted to body frameVector3D transform(GeodeticPoint point)
point
- surface-relative pointGeodeticPoint transformFromZenith(Vector3D point, Vector3D zenith, Frame frame, AbsoluteDate date) throws PatriusException
If no normal is provided (null) then it transforms the cartesian point to a surface-relative point, using the true shape of the body: in case of a facet shape the normal used is the normal of the closest triangle.
Spherical coordinates are then applied to provided normal or shape's normal so as to compute corresponding longitude and latitude (spherical azimuth and elevation).
The difference of this method with the classic transform method is that either the user defines the normal or the normal is based on model's true shape. The result is that resulting point's longitude and latitude are the same than those of a point with the same normal on a sphere. Therefore, users shall be aware that for instance a vertical facet at North pole leads to horizontal normal, meaning that returned point's latitude will be zero as if the point belonged to the equator.
point
- cartesian pointzenith
- local surface normal used as topocentric zenith. May be null, if so true local zenith is recomputedframe
- frame in which point and zenith are expresseddate
- date of the computation (used for frames conversions)PatriusException
- if point cannot be converted to body frameVector3D[] closestPointTo(Line line, Frame frame, AbsoluteDate date) throws PatriusException
Note: calculations take the line's minimum abscissa into account.
line
- the original line for the shortest distance computationframe
- the line's framedate
- the current dateVector3D
PatriusException
- if line cannot be converted to body framedefault Vector3D[] closestPointTo(Line line) throws PatriusException
Note: calculations take the line's minimum abscissa into account.
In this method we consider that the line's frame is the body frame, and the date is the J200 Epoch.line
- the original line for the shortest distance computationVector3D
PatriusException
- if line cannot be converted to body frameCopyright © 2023 CNES. All rights reserved.