In a similar way as in the first tutorial [direct location](./direct-location.html), we call Rugged direct location method. This time it is called in a loop so as to generate a full grid on disk.
...
...
@@ -124,8 +122,9 @@ In a similar way as in the first tutorial [direct location](./direct-location.ht
int lineStep = (maxLine - minLine) / nbLineStep;
int pxStep = (maxPx - minPx) / nbPxStep;
List<GeodeticPoint> pointList = new ArrayList<GeodeticPoint>();
for (int i = 0; i < nbLineStep; i++) {
for (int i = 0; i < nbLineStep; i++) {
List<GeodeticPoint> pointList = new ArrayList<GeodeticPoint>(nbPxStep);
int currentLine = minLine + i * lineStep;
for (int j = 0; j < nbPxStep; j++) {
int currentPx = minPx + j * pxStep;
...
...
@@ -133,17 +132,14 @@ In a similar way as in the first tutorial [direct location](./direct-location.ht
On the third line, we find the time interval of the acquisition: acquisitionStartDate, acquisitionStopDate,
tStep (step at which the pre-computed frames transforms cache will be filled), timeTolerance (margin
allowed for extrapolation, in seconds). This is an important information as Rugged
allowed for extrapolation during inverse location, in seconds. A few lines must be taken into account like: timeTolerance = 5/lineSensor.getRate(0)). This is an important information as Rugged
will pre-compute a lot of stuff at initialization in order to optimize further calls to the direct and
inverse location functions.
On the fourth line, the arguments are the list of time-stamped positions and velocities as well as options
for interpolation: number of points to use and type of filter for derivatives. We find the same arguments
on the last line for the attitude quaternions.
for interpolation: number of points to use and type of filter for derivatives. The interpolation polynomials for nbPVPoints without any derivatives (case of CartesianDerivativesFilter.USE_P: only positions are used, without velocities) have a degree nbPVPoints - 1. In case of computation with velocities included (case of CartesianDerivativesFilter.USE_PV), the interpolation polynomials have a degree 2*nbPVPoints - 1. If the positions/velocities data are of good quality and spaced by a few seconds, one may choose only a few points but interpolate with both positions and velocities; in other cases, one may choose more points but interpolate only with positions.
We find the same arguments on the last line for the attitude quaternions.
The sensor models are added after initialization. We can add as many as we want.