-
Ciclar: Creating polygons with topology
Access this help text as a web page: Ciclar
Presentation and options
This program works on a family of topologically structured files
containing arcs (ARC) and nodes (NOD) to produce a family of topologically
structured files containing polygons (POL). ARC and NOD files can be
generated through the LinArc program. In addition, it is able to
apply the process straightly to POL files to obtain new polygons that correspond to the originals
grouped by some criterion; also it converts POL files without topological structure from VEC files,
and also it allows to transform POL files into VEC files (a non-topological format) and viceversa.
The main objective of the program is to build all the possible
topological polygons present in the arcs file; this process is called
'cycling'. In the cycling process each polygon is described as a
sequence of arcs that delimits a closed area (exterior border); if the
polygon presents interior holes, these are also described by the
corresponding arcs (interior border).
Arcs involved in the cycling of one polygon are not written in the POL
file, but they are read from the ARC file; this implies a saving of disk
space and ensures a higher geometric consistency for all the database. In
addition, this strategy allows having several polygon databases being cycled
upon the same ARC file, as we will explain later. However, the program does support the /EMANCIPA, parameter useful when a cycled polygon layer has not to depend on arcs.
In the modes in which the program generates a POL file, this is followed by a P.dbf (main attributes table)
and a P.rel file (containing metadata, and that may contain the eventual relationships with other alphanumerical
tables which are additional to the main one, as well as the symbolization by default). In older versions of the
program (1.x) a DVP file that contained a very basic metadata was generated; that has been totally overcome
nowadays.
After the cycling process, the only attributes the polygons have are the geometric-topological ones (area,
perimeter, number of arcs and number of elemental polygons composing the polygon, etc)
and the graphic identifier that, in a unique way, references each polygon. The attributes of thematic nature
(vegetation present in the polygon, owner, etc) can be added transferring attributes from point labels placed
in each polygon or introducing them directly from MiraMon attribute edition mode. When choosing the attribute
transference through labels, when labels are in VEC format it will be done through the AtriPol
program, but when they are in PNT format it will be done through the AtriTop program.
Although some options tolerate the arcs file to contain final nodes (endnodes) and line nodes (pseudonodes), their presence can be due to errors. An arc that has endnodes is not cyclable. In order to control the nodes, it is possible to visualize them with MiraMon or use the InfoTop utility to know their topological relationships.
When the program makes operations based on polygon files to generate other polygons, this is called recycling.
Option 1:
Cycles all arcs present in the file.
Option 2:
Is based on a logical (L) field of the database. If it says 'TRUE', the arc is cyclable, and if it says 'FALSE' the arc is ignored during the cycling process. If the database contains only one logical field, this one will be used, and if there are several, it will be asked which field should be used. This is useful to exclude certain arcs from the process of polygon cycling.
Option 3:
Performs a recycling from a polygon file, already totally cycled and in which thematic attributes have been included f.ex. AtriTop. The idea is to build new, more general, polygons from the arcs that have different attribute on both sides. In a file of municipalities, in case its database has a field that informs about which county each municipality belongs to, Ciclar 3 can generate the polygon file corresponding to these countries, in which only the arcs defining the country borders are used (those that have a different county -attribute- on each side of the arc).
The selection criterion is taken from a database field or from all field that are not geometrical-topologic. Only those arcs having a different field value on both sides in the old polygon file are considered as cyclable.
Option 4:
Generates some groups of polygons from a polygon file, already totally cycled, from a thematic preexistent attribute. A group of polygons file is a file that agglutinates in a single entity (a single polygon) all polygons having a common property (equal attribute). For example, in a map of countries, it would be desirable that all locations and islands that belong to the same country form a unique entity. This means that when consulting by location a polygon of a country, such as Canada, a highlighting of all of its islands is also obtained. This query gives us area and perimeter as a result of sum of elemental polygon contributions. The selection criterion is taken from a database field or from all field that are not geometrical-topologic.
Option 5:
Performs a recycling from a polygon file already totally cycled. It groups in a single polygon, more general, those polygons that are connected by a node and share the same thematic attributes. In a raster file presenting linear elements with width similar to the pixel size crossing the raster in diagonal (roads or rivers). If this layer is vectorized to get polygons, these lines will usually become sequences of square polygons of one pixel in size and interconnected by their nodes. This mode groups all these polygons in a single one that better represents the graphic entities.
The selection criterion is taken from a database field or from all fields that are not geometrical-topologic (multiple registration is considered if any). Only those arcs having a different field value on both sides in the original polygon file are considered as cyclable.
Option 6:
Performs a cycling from an arc file o generates a non-topological groups of polygons file (overlapping of polygons is allowed). First, a projection of the arc base field is performed, which is used to generate polygons. By each different attribute of this field a selection of arcs that have this attribute is done and they are totally cycled. Each one of these independent cycling processes is included inside the final polygon group file; in this operation it can appear the aforementioned superpositions. The superposition order of the different features can be controlled from an order file. Also, there is the chance of generating a single group for each attribute (with all polygons of the same attribute forming a single object).
Option 7:
Converts polygons from a VEC file to a POL file which will have no guaranteed topology (overlapping of polygons is allowed). The VEC attribute is imported as well. When two or more polygons both have the same attribute and appear consecutively inside the VEC file, these polygons became a group in the POL file.
Option 8:
Converts polygons from a POL file to a VEC file. Each group of polygons are splitted in their elemental polygons. It is possible to select one database field to keep it as VEC objects attributes.
Option 9:
Ungroup a polygon file. Each group of polygons are splitted in their elemental polygons.
After this first selection through the 'Option' parameter, the 'e' parameter lets apply a selection that removes the arcs with endnodes (arcs that do not connect to any other arc neither with themselves).
In addition, the selection allows ignoring those arcs having the same polygon on both sides (dumb-bells or halters).
As we stated above, the application of the 'e' parameter allows cycling arc files containing non cyclable arcs (arcs with endnodes and dumb-bells or halters). These arcs can be included in the file in a voluntary way, but they can also come from errors in the digitizing process. Therefore, the 'e' parameter has to be used in an accurate and conscious way.
The program creates the PERIMETRE and AREA fields in the database, indicating the perimeter and the
area respectively of each polygon. In the case of PERIMETRE this also includes interior perimeters. The values of the PERIMETRE and AREA fields are calculated based on the coordinates in the (map) projection and, therefore, do not give the perimeters and areas on the Earth but as they appear on the map, calculated as they would normally be by a computer assisted drawing (CAD) program. In projections such as UTM these calculations are accurate enough for most purposes. For example, within a UTM zone the perimeter on the map may differ from the perimeter on the terrestrial ellipsoid by a factor between 0.9996 and 1.0009811009).
When the cartographic projection is known (list of known projections can be consulted in the help for the CanviPrj program), the program creates as well as the PERIMETRE and AREA fields, the PERIMETREE and AREAE fields, that indicate the real perimeter and area of each polygon as calculated over the terrestrial ellipsoid using accurate geodesic criteria. These new fields are especially relevant for cartographic projections in which the calculations made on the maps give clearly different values from the real values over the Earth's surface (for example, the Mercator projection) or in map projections where the difference may be small but significant errors may be accumulated when dealing with large polygons.
According to the map projection used the program makes PERIMETRE or PERIMETREE and AREA or AREAE visible and hides the other fields, depending on which is the most commonly used measure of perimeter and area in that projection. These display criteria may be changed in the REL file with the Universal Geospatial Metadata Manager GeM+.
Dialog box of the application
Syntax
Syntax:
- Ciclar 1 InputARCfile OutputPOLFile [/IGNORAR] [/EMANCIPA]
- Ciclar 2 InputARCfile OutputPOLFile [/IGNORAR] [/TAULA_ARC] [/CAMP_ARC] [/COND#_CAMP] [/COND#_OP] [/COND#_VALOR] [/COND#_NEXE] [/COND#_PRIOR] [/EMANCIPA]
- Ciclar 3 InputPOLfile OutputPOLFile [/TAULA] [/CAMP] [/CAMP_AREA] [/CAMP_AREA_TPERCENT] [/EMANCIPA]
- Ciclar 4 InputPOLfile OutputPOLFile [/TAULA] [/CAMP] [/CAMP_AREA] [/CAMP_AREA_TPERCENT] [/EMANCIPA]
- Ciclar 5 InputPOLfile OutputPOLFile [/TAULA] [/CAMP] [/CAMP_AREA] [/CAMP_AREA_TPERCENT] [/IGNORAR] [/EMANCIPA]
- Ciclar 6 InputARCfile OutputPOLFile [/TAULA_ARC] [/CAMP_ARC] [/TAULA_ORD] [/CAMP_ORD] [/IGNORAR] [/UN_POL_PER_ATRIBUT] [/FITXER_ORDRE_GRUP] [/EMANCIPA]
- Ciclar 7 VecOriginFile OutputPOLFile
- Ciclar 8 InputPOLfile OutputVecFile [Precision] [/TAULA] [/CAMP] [/SI_EN_BLANC] [/ATRIBUT_CONSTANT] [/ALCADA] [/AJUST_ENV]
- Ciclar 9 InputPOLfile OutputPOLFile
Options:
- 1:
Total cycling.
- 2:
Process selectively as a function of the logical field in the database indicated by /TAULA_ARC=n and /CAMP_ARC=m or by a selection.
- 3:
Polygon recycling by arcs having the same attributes in both sides. It can be done considering all non geometrical-topological fields or a database field in the InputPOLfile (any field of any database table).
- 4:
Generation of polygon groups from a pre-existing thematic attribute. It can be done based on a field in the FixerPolOrigen database (any field in any non-geometric-topological database table).
- 5:
Polygon recycling of polygons sharing a node and having the same attributes both sides. It can be done considering all non geometrical-topologic fields or a database field in the InputPOLfile (any field of any database table). Generates groups of polygons.
- 6:
Obtain groups of non-topological polygons as a function of a database field in the InputARCfile indicated by /TAULA_ARC=n and /CAMP_ARC=m. The value of this field is converted into a polygon attribute in the database. Since groups of polygons of this type can often produce overlap it is possible to indicate a numerical field for determining the order in which the arcs of the polygons are drawn using another database field indicated by /FITXER_ORDRE_GRUP. By default the projection order of the indicated field is used (numerical order for N fields and alphabetical order for C fields). This has the effect that the polygons formed by arcs with lower order attributes fall underneath the others.
- 7:
Convert polygons from a VEC file to a POL file (groups of non-topological polygons).
- 8:
Convert polygons from a POL file to a VEC file.
- 9:
Ungroup a polygon file.
Parameters:
- InputARCfile
(Input structured arc file -
Input parameter): Structured ARC file.
- OutputPOLFile
(Output polygon file -
Output parameter): The program generates a POL file.
- InputPOLfile
(Input structured polygon -
Input parameter): Structured POL file.
- VecOriginFile
(Non-structured vector input file -
Input parameter): Non-structured arcs file.
- OutputVecFile
(Output VEC File -
Output parameter): Polygon VEC file.
- Precision
(Precision -
Input parameter): Precision.
Modifiers:
/COND#_CAMP=
(Field of condition #)
Field name of # condition of selection. It may be made up to 100 simple queries and 100 field names (COND#_CAMP) starting at index 1. (Input parameter) /COND#_OP=
(Operation of condition #)
Operation of # condition of selection. It may be made up to 100 simple queries and 100 operations (COND#_OP) starting at index 1. (Input parameter) /COND#_VALOR=
(Value of condition #)
Value of # condition of selection. It may be made up to 100 simple queries and 100 values (COND#_VALOR) starting at index 1. (Input parameter) /COND#_NEXE=
(Nexus linking of condition #)
Nexus use to linking for the successive selections. In this case to linking between condition # and condition #+1. It may be made up to 100 simple queries and 99 nexus (COND#_NEXE) starting at index 1. (Input parameter) /COND#_PRIOR=
(Priority of nexus linking of condition #)
Priority of nexus use to linking for the successive selections. In this case to linking between condition # and condition #+1. It may be made up to 100 simple queries and 99 priorities (COND#_PRIOR) starting at index 1. This is an optional parameter. If it is not indicated the priority is just the order. (Input parameter) /CAMP_AREA= (Field name that will contain the Field area) It is the field name that contains or will contain the partial area of each record of the resulting polygons when they present multiple record. This field will contain the area covered by each record before the polygon fusion. In case that the field do not exists, the program will create it. (Input parameter) /CAMP_AREA_TPERCENT= (Field name that will contain the Field Percentage Cover) Added to partial area, in case of indicating this parameter a generation of a field with cover percentage for each record in the possible multiple records of the main table of attributes is requesting. (Input parameter) /TAULA_ARC /CAMP_ARC= (Index of the field that is the logical field) Logical Field selection of the table in arc format. Is indicated with /TAULA_ARC=n and /CAMP_ARC=m or with a selection. (Input parameter) /TAULA_ORD /CAMP_ORD= (Index of the field that contain Field order) Defines the order in which the polygons are cycled in case of overlaps. (Input parameter) /IGNORAR= (Discards cyclable arcs) - ENDNODES: Before processing the processable arcs are selected, discarding the arcs without end nodes.
- /HALTERS: Like ENDNODES, but also discarding those arcs with the same polygon on both sides If these are not indicated the program does not tolerate the presence of end nodes nor halters in the arcs database.
(Input parameter) /UN_POL_PER_ATRIBUT
(Creation of one polygon)
Generates one macropolygon for all of those polygons which shares the attribute. (Input parameter) /FITXER_ORDRE_GRUP=
(INI file that indicates the superposition order)
Since groups of polygons of this type can often produce overlap t is possible to indicate the order in which the polygons are drawn using the parameter /FITXER_ORDRE_GRUP. By default, the order of the stated field projection is used (numerical order for N fields and alphabetical order for C fields). This has the effect that the polygons formed by arcs whose attributes were digitized first fall underneath those that were digitized later. (Input parameter) /EMANCIPA (Emancipate the result) Indicates the need to achieve an emancipated result by cycling the arcs. (Input parameter) /TAULA= (Selects a database table in the POL vector format) Set database table of the selection criterion (options 3, 4 and 5) or set database field to be exported in a VEC format (option 8). To learn more about the values of these parameters, the considerations of the general syntax document should be followed. (Input parameter) /CAMP= (Selects a database field in the POL vector format) Set database field of the selection criterion (options 3, 4 and 5) or set database field to be exported in a VEC format (option 8). To learn more about the values of these parameters, the considerations of the general syntax document should be followed. (Input parameter) /SI_EN_BLANC=
(What to do in case of blank attribute)
Sets the VEC exportation behavior when the attribute does not exist in the database (blank field). Can be "CONSTANT" to write a constant value, "ID_GRAFIC" to write graphic identifier or "IGNORAR" to ignore vectors without attribute (default value). (Input parameter) /ATRIBUT_CONSTANT=
(Constant value of the attribute for blank records)
Sets a constant that is going to be write as object attribute when exporting to VEC format. If it is used in combination with /TAULA=, /CAMP= and /SI_EN_BLANC=CONSTANT is the attribute that is going to be used when there is no data (blank field). If you don't indicate /TAULA=, /CAMP= or /ATRIBUT_CONSTANT= the VEC format exportation is done using graphic identifier as attribute. (Input parameter) /ALCADA=
(Sets the heights)
Sets which of the possible heights are used in the VEC. To learn more about the values of this parameter follow the considerations in general syntax (Input parameter) /AJUST_ENV
(Adjusting envelope)
Adjusting envelope (Input parameter)
INI field format is indicated at the parametre /FITXER_ORDRE_GRUP
[ORDRE_GRUP]
Atributte1=
Atributte2=
Atributte3=
...
(The index attribute must be correlative. The key values
is the attribute value of the polygons)
This program support REL v.4 format and ARC v. 1.1 format with or without 3D
coordinates.