ClassesClassesClassesClasses | | | | Operators

partition_dynamicpartition_dynamicPartitionDynamicpartition_dynamicPartitionDynamicPartitionDynamic (Operator)

Name

partition_dynamicpartition_dynamicPartitionDynamicpartition_dynamicPartitionDynamicPartitionDynamic — Partition a region horizontally at positions of small vertical extent.

Signature

partition_dynamic(Region : Partitioned : Distance, Percent : )

Herror partition_dynamic(const Hobject Region, Hobject* Partitioned, double Distance, double Percent)

Herror T_partition_dynamic(const Hobject Region, Hobject* Partitioned, const Htuple Distance, const Htuple Percent)

Herror partition_dynamic(Hobject Region, Hobject* Partitioned, const HTuple& Distance, const HTuple& Percent)

HRegionArray HRegion::PartitionDynamic(const HTuple& Distance, const HTuple& Percent) const

HRegionArray HRegionArray::PartitionDynamic(const HTuple& Distance, const HTuple& Percent) const

void PartitionDynamic(const HObject& Region, HObject* Partitioned, const HTuple& Distance, const HTuple& Percent)

HRegion HRegion::PartitionDynamic(double Distance, double Percent) const

void HOperatorSetX.PartitionDynamic(
[in] IHUntypedObjectX* Region, [out] IHUntypedObjectX*Partitioned, [in] VARIANT Distance, [in] VARIANT Percent)

IHRegionX* HRegionX.PartitionDynamic(
[in] double Distance, [in] double Percent)

static void HOperatorSet.PartitionDynamic(HObject region, out HObject partitioned, HTuple distance, HTuple percent)

HRegion HRegion.PartitionDynamic(double distance, double percent)

Description

partition_dynamicpartition_dynamicPartitionDynamicpartition_dynamicPartitionDynamicPartitionDynamic partitions the input RegionRegionRegionRegionRegionregion horizontally into regions that have an approximate width of DistanceDistanceDistanceDistanceDistancedistance. The input region is split at positions where it has a relativly small vertical extent.

The positions where the input region is split are determined by the following approach: First, initial split positions are determined such that they are equally distributed over the horizontal extent of the input region, i.e., such that all the resulting parts would have the same width. For this, the number n of resulting parts is determined by dividing the width of the input region by DistanceDistanceDistanceDistanceDistancedistance and rounding the result to the closest integer value. The distance between the initial split positions is now calculated by dividing the width of the input region by n. Note that the distance between these initial split positions is typically not identical to DistanceDistanceDistanceDistanceDistancedistance. Then, the final split positions are determined in the neighborhood of the initial split positions such that the input region is split at positions where it has the least vertical extent within this neighborhood. The maximum deviation of the final split position from the initial split position is DistanceDistanceDistanceDistanceDistancedistance*PercentPercentPercentPercentPercentpercent*0.01.

The resulting regions are returned in PartitionedPartitionedPartitionedPartitionedPartitionedpartitioned. Note that the input region is only partitioned if its width is larger than 1.5 times DistanceDistanceDistanceDistanceDistancedistance.

Parallelization

Parameters

RegionRegionRegionRegionRegionregion (input_object)  region(-array) objectHRegionHRegionHRegionHRegionXHobject

Region to be partitioned.

PartitionedPartitionedPartitionedPartitionedPartitionedpartitioned (output_object)  region-array objectHRegionHRegionHRegionArrayHRegionXHobject *

Partitioned region.

DistanceDistanceDistanceDistanceDistancedistance (input_control)  real HTupleHTupleHTupleVARIANTHtuple (real) (double) (double) (double) (double) (double)

Approximate width of the resulting region parts.

PercentPercentPercentPercentPercentpercent (input_control)  real HTupleHTupleHTupleVARIANTHtuple (real) (double) (double) (double) (double) (double)

Maximum percental shift of the split position.

Default value: 20

Suggested values: 0.0, 10.0, 20.0, 30.0, 40.0, 50.0, 70.0, 90.0, 100.0

Typical range of values: 0 ≤ Percent Percent Percent Percent Percent percent ≤ 100

Result

partition_dynamicpartition_dynamicPartitionDynamicpartition_dynamicPartitionDynamicPartitionDynamic returns 2 (H_MSG_TRUE) if all parameters are correct. The behavior in case of empty input (no regions given) can be set via set_system('no_object_result',<Result>)set_system("no_object_result",<Result>)SetSystem("no_object_result",<Result>)set_system("no_object_result",<Result>)SetSystem("no_object_result",<Result>)SetSystem("no_object_result",<Result>), the behavior in case of an empty input region via set_system('empty_region_result',<Result>)set_system("empty_region_result",<Result>)SetSystem("empty_region_result",<Result>)set_system("empty_region_result",<Result>)SetSystem("empty_region_result",<Result>)SetSystem("empty_region_result",<Result>), and the behavior in case of an empty result region via set_system('store_empty_region',<'true'/'false'>)set_system("store_empty_region",<"true"/"false">)SetSystem("store_empty_region",<"true"/"false">)set_system("store_empty_region",<"true"/"false">)SetSystem("store_empty_region",<"true"/"false">)SetSystem("store_empty_region",<"true"/"false">). If necessary, an exception is raised.

Possible Predecessors

thresholdthresholdThresholdthresholdThresholdThreshold, connectionconnectionConnectionconnectionConnectionConnection

Alternatives

partition_rectanglepartition_rectanglePartitionRectanglepartition_rectanglePartitionRectanglePartitionRectangle

See also

intersectionintersectionIntersectionintersectionIntersectionIntersection, smallest_rectangle1smallest_rectangle1SmallestRectangle1smallest_rectangle1SmallestRectangle1SmallestRectangle1, shape_transshape_transShapeTransshape_transShapeTransShapeTrans, clip_regionclip_regionClipRegionclip_regionClipRegionClipRegion

Module

Foundation


ClassesClassesClassesClasses | | | | Operators