|
static SimplePoly | convexHull (const std::vector< Position > &plist, double bottom, double top) |
|
static SimplePoly | convexHull (const SimplePoly &p) |
|
static SimplePoly | convexHull (const std::vector< SimplePoly > &p) |
|
static SimplePoly | convexHull (const SimplePoly &p, double buffer) |
|
static Position | pushOut (SimplePoly &poly, const Position &p, double buffer) |
|
static Position | pushOut (SimplePoly &poly, int i, double buffer) |
|
static SimplePoly | simplify2 (SimplePoly &p, double buffer) |
|
static SimplePoly | simplify (SimplePoly &p, double buffer) |
|
static SimplePoly | simplify (SimplePoly &p) |
|
static SimplePoly | simplifyToSize (SimplePoly &p, int num) |
|
static SimplePoly | stretchOverTime (const SimplePoly &sp, const Velocity &v, double timeBefore, double timeAfter) |
|
static PolyPath | stretchOverTime (const PolyPath &pbase, double timeBefore, double timeAfter) |
|
static SimplePoly | bufferedConvexHull (SimplePoly &p, double hbuff, double vbuff) |
|
static PolyPath | bufferedConvexHull (const PolyPath &pbase, double hbuff, double vbuff) |
|
static double | intersectsPolygon2D (const Plan &p, PolyPath &pp, double B, double T, double incr) |
|
static Plan | reducePlanAgainstPolys (const Plan &plan, double gs, std::vector< PolyPath > &paths, double incr, bool leadInsPresent, const std::vector< PolyPath > &containment) |
|
static Plan | reducePlanAgainstPolys (const Plan &pln, double gs, std::vector< PolyPath > &paths, double incr, bool leadInsPresent) |
|
static std::pair< double, std::string > | isPlanInConflictWx (const Plan &plan, std::vector< PolyPath > &paths, double start, double end, double incr) |
|
static std::pair< double, std::string > | isPlanInConflictWx (const Plan &plan, std::vector< PolyPath > &paths, double incr) |
|
static std::pair< double, std::string > | isPlanInConflictWx (const Plan &plan, std::vector< PolyPath > &paths, double incr, double fromTime) |
|
static bool | isPlanContained (const Plan &plan, const std::vector< PolyPath > &paths, double B, double T, double incr) |
|
static double | calculateWxExitTime (const Plan &plan, std::vector< PolyPath > &paths, double incr, double entryTime) |
|
double larcfm::PolyUtil::intersectsPolygon2D |
( |
const Plan & |
p, |
|
|
PolyPath & |
pp, |
|
|
double |
B, |
|
|
double |
T, |
|
|
double |
incr |
|
) |
| |
|
static |
This is a SLOW, APPROXIMATE test for 2D intersection between a moving polygon and a moving point. For more accurate (and verified) tests for this property, see polygon functions in the ACCoRD framework, specifically classes that implement the DetectionPolygon interface and CDIIPolygon.
- Parameters
-
p | plan describing point-mass trajectory |
pp | path describing polygon movement |
B | start time to check (absolute) |
T | end time to check (absolute) |
incr | time increment for search (> 0) |
- Returns
- time of loss of separation if aircraft will intersect with the polygon between times B and T and polygon name that plan is in conflict with
Note: the return time will be at an interior point, and the name of the polygon
Stretch a polygon so that it covers (at least) what the original would as it moves over a given time range. The uses a convex hull, so will be an over-approximation. There may be inaccuracies for very long periods of time if using geodesic coordinates.
Example: Given a polygon W and an aircraft A with a timeAfter of 100 seconds, a conflict detection for A against the stretched polygon W' is approximately equivalent to the disjunction of conflict detections (any positive is a positive) of the set A' against the original W, where A' is the set A plus all of "echos" timeshifted up to 100 seconds into the past, modulo distortion from geodetic projections and convex hull expansions. Effectively this is saying that if the conflict detection of A vs. W' is clear, then A will be clear of W and any aircraft that precisely follow A will also be clear of W for up to 100 seconds. (If it were not clear for 100 seconds, then A would have impacted the extended W', which "arrives" 100 seconds earlier than W would.)
Similarly for timeBefore.
If A is clear of W', then it is also clear of the original W, which is a subset of W'.
Note this technique does not necessarily work for morphing polygons.
- Parameters
-
sp | base polygon |
v | average velocity of polygon |
timeBefore | time before stated position to cover (in sec) |
timeAfter | time after stated position to cover (in sec) |
- Returns
- enlarged polygon