box_connectivity

geometric-functions box_connectivity

syntax

  • box_connectivity(lower_bound(polygon_data_item), upper_bound(polygon_data_item))

definition

box_connectivity(lower_bound(polygon_data_item), upper_bound(polygon_data_item)) results in a new uint32 domain-unit with one entry for each ‘connection’ in the polygon_data_item argument.

A ‘connection’ is defined as two polygons having at least one common interior point.

description

The function results in an F1 and F2 attribute with relations to the domain-unit of the polygon_data_item attribute.

The relations indicate which connections exists, each connection only occurs once (a connection between polygon 0 and 1 only occurs as F1: 0 and F2: 1 and not vice versa).

This could be very useful to speed up partitioned unions, where the result of this operator can serve as the approximate partition.

see example ``` unit SomePolygonSet { attribute geometry (poly); unit BoxedConnectivity := box_connectivity(Lower_Bound(geometry), Upper_Bound(geometry)); unit ConnectParts := connected_parts(BoxedConnectivity/F1, BoxedConnectivity/F2); } unit SplitUnionedSet := bp_split_union_polygon(SomePolygonSet/geometry[rdc_cm], SomePolygonSet/ConnectParts/Part_rel); ``` </details> ## conditions 1. The [composition type](composition.html) type of the *polygon_data_item* [argument](argument.html) needs to be polygon with an ipoint, spoint, fpoint and dpoint [value-type](value-type.html). 2. The order of the points in *polygon_data_item* needs to be clockwise for exterior bounds and counter clockwise for holes in polygons (right-hand-rule). ## since version 15.6.0 ## example ``` unit connection := box_connectivity(lower_bound(district/geometry), upper_bound(district/geometry)); ``` ## see also - configuration example: [border-polygons](border-polygons.html)