IfcSurfaceWeightsPositive

Natural language names
Surface Weights Positive
Semantic definitions at the function
Function Definition

NOTE  Definition according to ISO/CD 10303-42:1992
This function checks the weights associated with the control points of a rational b-spline surface and returns TRUE if they are all positive.
NOTE  Function adapted from surface_weights_positive defined in ISO 10303-42.
HISTORY  New function in IFC4

Formal representations
EXPRESS Specification

FUNCTION IfcSurfaceWeightsPositive
( B: IfcRationalBSplineSurfaceWithKnots)
: BOOLEAN;

  LOCAL
    Result : BOOLEAN := TRUE;
    Weights : ARRAY [ 0 : B\IfcBSplineSurface.UUpper ] OF ARRAY [ 0 : B\IfcBSplineSurface.VUpper ] OF REAL := B.Weights;
  END_LOCAL;

  REPEAT i := 0 TO B\IfcBSplineSurface.UUpper;
    REPEAT j := 0 TO B\IfcBSplineSurface.VUpper;
      IF (Weights[i][j] <= 0.0) THEN
        Result := FALSE;
        RETURN(Result);
      END_IF;
    END_REPEAT;
  END_REPEAT;
  RETURN(Result);
END_FUNCTION;

References  References: IfcRationalBSplineSurfaceWithKnots

Link to this page  Link to this page