Previous Next Table of Contents

2. DEA geometry definition

The DEA geometry is defined by a set of points and vectors, all of them in the MPS coordinates-

2.1 The "DEA-local" coordinates

The DEA face is a plane (a two-dimensional surface), so a point on the face of DEA has two "DEA-local" coordinates- localX and localY. The depth of a point inside the DEA is given by the third "DEA-local" coordinate- localZ.

2.2 Conversion to/from MPS coordinates

The conversion between the MPS coordinates and the "DEA-local" coordinates is given by the formulas:

vector3_t mps,local;     --- 3D points
vector3_t xv,yv,normalv; --- 3D vectors

mps.x = origin.x + xv.x * local.x + yv.x * local.y + normalv.x * local.z;
mps.y = origin.y + xv.y * local.x + yv.y * local.y + normalv.y * local.z;
mps.z = origin.z + xv.z * local.x + yv.z * local.y + normalv.z * local.z;
The inverse conversion is given by:
local.x = DotProduct(mps-origin,xv);
local.y = DotProduct(mps-origin,yv);
local.z = DotProduct(mps-origin,normalv);

2.3 Boundaries and edges

The boundaries of the DEA segments are defined by constraining the "DEA-local" coordinates to the inside of a square box:

xMin <= local.x <= xMax
yMin <= local.y <= yMax
   0 <= local.z <= depth

2.4 Is a given point inside the DEA?

To find out if a point specified in the MPS coordinates is inside or outside of a DEA segment, one has to convert the coordinates of this point to the "DEA-local" coordinates and check if the "DEA-local" coordinates (local.x and local.y) lay inside the boundaries (xMin, xMax, yMin and yMax) of that particular segment.


Previous Next Table of Contents