Coordinate formats allow you to define exactly how the coordinates in a file should be represented. When you perform a batch conversion, you first define how the input coordinates are define. This is necessary since CoordTrans needs to be able to understand the coordinates in the file. Once understood, CoordTrans can write the coordinates to a destination file using another coordinate format. Thus, you can choose to represent your coordinates in any way you like!

Managing the Coordinate Formats

CoordTrans maintains a database of coordinate formats that you can edit as you wish. By selecting
Tools->Coordinate Formats in the batch converter dialog, you reach a coordinate format manager. Here
you can create, edit, remove, import and export coordinate formats.

Figure 1 - managing the coordinate formats |

Creating a new coordinate format

There are two ways to create a new format - you can create a coordinate format from scratch or you can
base your new coordinate format on an existing format. To create a coordinate format from scratch, you
simple click new and fill out the fields. To base your format on an existing format, you need to *clone*
the existing formats. To do this, simply select the existing format, right click it an select clone. Now you
have an identical copy of the coordinate format which you can alter without editing the existing format!

Defining a Coordinate Format

A Coordinate Format can be defined in two ways; either using a simple coordinate format expression or a regular expression. The simple expression will generate a regular expression, so it is possible to start with a simple expression and refine it by altering the regular expression.

The fastest way to define a coordinate format is to use a simple expression, which is composed of the letters D, M and S. Uppercase characters represent the integer part and lowercase characters represent the decimal part. Thus, D represents the integer part of degrees (i.e. 90 if degrees is 90.56) and d represents the decimal part (i.e. 56 if degrees is 90.56).

Input and Output

Coordinate formats can be used both to interpret a coordinate read from a text file, and to format a coordinate so it can be written to the text file. However, different rules apply to input and output coordinate formats. The distinctions are:

Examples

18° 48' 40.764" |

The coordinate in this example is a very common coordinate format generally referred to as a DMS-format. It means that the coordinate is
defined through a combination of degrees, minutes and seconds. This can easily be understood by CoordTrans by defining an appropriate
coordinate format. We note above that we have 18 degrees, 48 seconds and 40.764 seconds. Degrees are represented by D, minutes M, seconds
S and s respectivelly. So the coordinate format can be defined as
D° MM' SS.s"This means "one or more characters for degrees", "two characters for minutes", "two characters for seconds" and "one or more characters in decimal seconds". However, 18° 48' 40" is also a valid coordinate, so we need to make the decimal part of seconds. This done by encapsulating the decimal part with "(" and ")". The format then becomes: D° MM' SS(.s)" |

© 2002-2019 Franson Technology AB, All rights reserved (franson.com)