OOF2: The Manual
Name
Fix Illegal Elements (FixIllegal) — Remove illegal elements from a Skeleton.
Synopsis
FixIllegal()
Description
FixIllegal is a SkeletonModifier that fixes illegal
Skeleton Elements.
Excluding paranormal alien interventions, illegal elements are
only generated by moving Nodes manually with the Move Nodes toolbox.
Illegal elements are BAD, so they should be
removed immediately.
FixIllegal fixes an Element by moving one or
more of its Nodes to the average position of its neighboring Nodes
In many cases, it is sufficient to fix an Element by applying this
smoothing procedure to the offending Nodes, namely those Nodes located
at corners that subtend interior angles greater than
180 degrees or less than 0 degrees (for quadrilaterals, illegal elements
include those that have non-convex geometries). However, this
smoothing procedure may not work when the corner angle is very close
to zero. In this case, the Nodes at other corners should be moved as well.
Each move is ultimately accepted or rejected solely by
whether or not it reduces the number of illegal Elements in the
vicinity of the Node.
Figure 6.77 shows a Skeleton that gives a pretty
good representation of the underlying Microstructure. Figure 6.78 shows the Skeleton after a Node has
been moved to create two illegal Elements (shown in red). The node
motion is indicated by the arrow in Figure 6.77. Figure 6.79
shows the Skeleton after FixIllegal has been applied. Notice
that although there are no illegal Elements, the Skeleton is no
longer such a good representation of the Microstructure. This is because
FixIllegal is a brutal technique: it pays
no attention to Element homogeneity
or shape
energy.
On one pass through the Skeleton, FixIllegal
attempts to move each Node of the troublesome element once,
choosing the Nodes in a
random order. It may not be successful on the first pass, so it
repeats the process until there are no more illegal Elements. If
it fails to remove all the illegal Elements after a fixed number of
iterations,[28] it will quit
trying and notify the user.






