Chapter 134. The OpenGIS Geometry Model

Table of Contents

Geometry properties
Point Examples
Point Properties
Curve Properties
LineString Examples
LineString Properties
Surface Properties
Polygon Examples
Polygon Assertions
MultiPoint Examples
MultiPoint Properties
MultiCurve Properties
MultiLineString Examples
MultiSurface Assertions
MultiPolygon Examples
MultiPolygon Assertions
MultiPolygon Properties
The Geometry Class Hierarchy
Class Geometry
Class Point
Class Curve
Class LineString
Class Surface
Class Polygon
Class GeometryCollection
Class MultiPoint
Class MultiCurve
Class MultiLineString
Class MultiSurface
Class MultiPolygon

The set of geometry types proposed by OGC's SQL with Geometry Types environment is based on the OpenGIS Geometry Model. In this model, each geometric object has the following general properties:

Geometry properties

A geometry value has the following properties:

  • Its type. Each geometry belongs to one of the instantiable classes in the hierarchy.

  • Its SRID, or Spatial Reference Identifier. This value identifies the geometry's associated Spatial Reference System that describes the coordinate space in which the geometry object is defined.

  • Its coordinates in its Spatial Reference System, represented as double-precision (8-byte) numbers. All non-empty geometries include at least one pair of (X,Y) coordinates. Empty geometries contain no coordinates.

    Coordinates are related to the SRID. For example, in different coordinate systems, the distance between two objects may differ even when objects have the same coordinates, because the distance on the planar coordinate system and the distance on the geocentric system (coordinates on the Earth's surface) are different things.

  • Its interior, boundary, and exterior.

    All geometries occupy some position in space. The exterior of a geometry is all space not occupied by the geometry. The interior is the space occupied by the geometry. The boundary is the interface between geometry's interior and exterior.

  • Its MBR (Minimum Bounding Rectangle), or Envelope. This is the bounding geometry, formed by the minimum and maximum (X,Y) coordinates:

      ((MINX MINY, MAXX MINY, MAXX MAXY, MINX MAXY, MINX MINY))
      
  • The quality of being simple or non-simple. Geometry values of some types (LineString, MultiPoint, MultiLineString) are either simple or non-simple. Each type determines its own assertions for being simple or non-simple.

  • The quality of being closed or not closed. Geometry values of some types (LineString, MultiString) are either closed or not closed. Each type determines its own assertions for being closed or not closed.

  • The quality of being empty or not empty A geometry is empty if it does not have any points. Exterior, interior and boundary of an empty geometry are not defined (that is, they are represented by a NULL value). An empty geometry is defined to be always simple and has an area of 0.

  • Its dimension. A geometry can have a dimension of -1, 0, 1, or 2:

    • -1 stands for empty geometries.

    • 0 stands for geometries with no length and no area.

    • 1 stands for geometries with non-zero length and zero area.

    • 2 stands for geometries with non-zero area.

    Point objects have a dimension of zero. LineString objects have a dimension of 1. Polygon objects have a dimension of 2. The dimensions of MultiPoint, MultiLineString, and MultiPolygon objects are the same as the dimensions of the elements they consist of.