Skip to content
Snippets Groups Projects
Commit 88cb1c06 authored by Guylaine Prat's avatar Guylaine Prat
Browse files

Update links

parent 4732648f
No related branches found
No related tags found
No related merge requests found
<!--- Copyright 2013-2017 CS Systèmes d'Information <!--- Copyright 2013-2018 CS Systèmes d'Information
Licensed under the Apache License, Version 2.0 (the "License"); Licensed under the Apache License, Version 2.0 (the "License");
you may not use this file except in compliance with the License. you may not use this file except in compliance with the License.
You may obtain a copy of the License at You may obtain a copy of the License at
...@@ -14,12 +14,14 @@ ...@@ -14,12 +14,14 @@
# Inverse Location # Inverse Location
The aim of this tutorial is to compute the inverse location of a point on Earth in order to give the sensor pixel, with the associated line, seeing this point. The aim of this tutorial is to compute the inverse location of a point on Earth
in order to give the sensor pixel, with the associated line, seeing this point.
We will also explain how to find the date at which sensor sees a ground point, which is a kind of inverse location only focusing on date. We will also explain how to find the date at which sensor sees a ground point,
which is a kind of inverse location only focusing on date.
## Inverse location of a point on Earth ## Inverse location of a point on Earth
The initialization of Rugged is similar as in the [Direct location](direct-location.html) tutorial up to rugged initialization.. The initialization of Rugged is similar as in the [Direct location](direct-location.md) tutorial up to rugged initialization..
### Point defined by its latitude, longitude and altitude ### Point defined by its latitude, longitude and altitude
Once Rugged initialized, one can compute the line number and the pixel number of a point defined by its Geodetic coordinates: Once Rugged initialized, one can compute the line number and the pixel number of a point defined by its Geodetic coordinates:
...@@ -28,12 +30,17 @@ Once Rugged initialized, one can compute the line number and the pixel number of ...@@ -28,12 +30,17 @@ Once Rugged initialized, one can compute the line number and the pixel number of
import org.orekit.rugged.linesensor.SensorPixel; import org.orekit.rugged.linesensor.SensorPixel;
GeodeticPoint gp = new GeodeticPoint(latitude, longitude, altitude); GeodeticPoint gp = new GeodeticPoint(latitude, longitude, altitude);
SensorPixel sensorPixel = rugged.inverseLocation(sensorName, gp, minLine, maxLine); SensorPixel sensorPixel = rugged.inverseLocation(sensorName, gp, minLine, maxLine);
where minLine (maxLine, respectively) is the minimum line number for the search interval (maximum line number, respectively). where minLine (maxLine, respectively) is the minimum line number for the search interval (maximum line number, respectively).
The inverse location will give the sensor pixel number and the associated line number seeing the point on ground. *In case the point cannot be seen between the prescribed line numbers, the return result is null. No exception will be thrown in this particular case*. The inverse location will give the sensor pixel number and the associated line number
seeing the point on ground.
**In case the point cannot be seen between the prescribed line numbers, the return result is null.
No exception will be thrown in this particular case**.
### Point defined by its latitude and longitude (no altitude) ### Point defined by its latitude and longitude (no altitude)
Similarly, one can compute the line number and the pixel number of a point defined solely by its latitude en longitude. The altitude will be determined automatically with the DEM. Similarly, one can compute the line number and the pixel number of a point defined solely
by its latitude en longitude. The altitude will be determined automatically with the DEM.
SensorPixel sensorPixel = rugged.inverseLocation(sensorName, latitude, longitude, minLine, maxLine); SensorPixel sensorPixel = rugged.inverseLocation(sensorName, latitude, longitude, minLine, maxLine);
...@@ -51,7 +58,8 @@ Similarly, for a point defined solely by its latitude en longitude (altitude det ...@@ -51,7 +58,8 @@ Similarly, for a point defined solely by its latitude en longitude (altitude det
AbsoluteDate dateLine = rugged.dateLocation(sensorName, latitude, longitude, minLine, maxLine); AbsoluteDate dateLine = rugged.dateLocation(sensorName, latitude, longitude, minLine, maxLine);
## Determine the min/max lines interval ## Determine the min/max lines interval
Rugged provides a way to determine a **very** rough estimation of the line using only the position-velocities of the satellite. It assumes the position-velocities are regular enough and without holes. Rugged provides a way to determine a **very** rough estimation of the line using only
the position-velocities of the satellite. It assumes the position-velocities are regular enough and without holes.
OneAxisEllipsoid oneAxisEllipsoid = ruggedBuilder.getEllipsoid(); OneAxisEllipsoid oneAxisEllipsoid = ruggedBuilder.getEllipsoid();
Frame pvFrame = ruggedBuilder.getInertialFrame(); Frame pvFrame = ruggedBuilder.getInertialFrame();
...@@ -63,7 +71,8 @@ One can compute the approximated line with the rough visibility estimator: ...@@ -63,7 +71,8 @@ One can compute the approximated line with the rough visibility estimator:
double roughLine = lineSensor.getLine(roughLineDate); double roughLine = lineSensor.getLine(roughLineDate);
The result will never be null, but may be really far from reality if ground point is away from trajectory. The result will never be null, but may be really far from reality if ground point is away from trajectory.
With this rough line, taken some margin around (for instance 100), one can initialize the min/max lines as search boundaries for inverse location, taken into account sensor min and max lines: With this rough line, taken some margin around (for instance 100), one can initialize
the min/max lines as search boundaries for inverse location, taken into account sensor min and max lines:
int minLineRough = (int) FastMath.max(FastMath.floor(roughLine - margin), sensorMinLine); int minLineRough = (int) FastMath.max(FastMath.floor(roughLine - margin), sensorMinLine);
int maxLineRough = (int) FastMath.min(FastMath.floor(roughLine + margin), sensorMaxLine); int maxLineRough = (int) FastMath.min(FastMath.floor(roughLine + margin), sensorMaxLine);
...@@ -73,4 +82,4 @@ then one can compute the inverse location: ...@@ -73,4 +82,4 @@ then one can compute the inverse location:
SensorPixel sensorPixel = rugged.inverseLocation(sensorName, gp, minLineRough, maxLineRough); SensorPixel sensorPixel = rugged.inverseLocation(sensorName, gp, minLineRough, maxLineRough);
## Source code ## Source code
The source code is available in InverseLocation.java (package fr.cs.examples under src/tutorials) The source code is available in [InverseLocation.java](src/tutorials/java/fr/cs/examples/InverseLocation.java) (package fr.cs.examples under src/tutorials)
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment