Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Clarification on the Relationship Between Georeferencing and X-Y Axis Position of Objects in the Map #2190

Open
Msabata opened this issue Nov 17, 2023 · 15 comments

Comments

@Msabata
Copy link

Msabata commented Nov 17, 2023

I would like to seek clarification on the connection between georeferencing and the positioning of the x and y axes of objects in the map.

Thank you for response.

@pkturner
Copy link
Contributor

If your question is about the x and y axes:

The origin, where the axes intersect, x=0, y=0, is determined by the map coordinates of the reference point.

The orientation of the axes has the y axis north-south and the x axis west-east, with positive y values to the north and positive x values to the east.

Because Mapper is for orienteering maps, the map orientation and its coordinate axes are magnetic.

The map developer sets the declination in the Georeferencing dialog, which orients the map in relation to geographic directions, i.e. meridians of longitude and parallels of latitude. Georeferencing also determines a projected grid, by specifying a CRS (Coordinate Reference System) which may or may not agree with geographic directions.

Mapper is able to display whichever of the 3 grids the user chooses: map, projected, or geographic.

@pkturner
Copy link
Contributor

If the question is about the positioning of objects:

Each map object has an x,y position. An object's geographic and projected coordinates are calculated as needed. The calculation is determined by the map's georeferencing parameters:

  • the reference point's projected & map coordinates
  • the CRS (Coordinate Reference System)
  • the declination
  • the map scale
  • the auxiliary scale factor

The calculation of projected coordinates from map coordinates uses:

  • the reference point's projected & map coordinates
  • the grivation (i.e. declination adjusted for the projected grid of the CRS)
  • the map scale
  • the combined scale factor (i.e. auxiliary scale factor adjusted for the CRS)

The calculation of map coordinates from projected coordinates is the inverse, and uses the same parameters.

The relationship between geographic and projected coordinates is a property of the CRS (Coordinate Reference System). Mapper relies on the PROJ library to make the correspondence. The difference between geographic north and projected north is the "convergence". The difference between geographic scale and the projection's scale is the "grid scale factor". Convergence and grid scale factor depend on the location of the reference point.

grivation = declination - convergence
combined_scale_factor = auxiliary_scale_factor * grid_scale_factor

@Msabata
Copy link
Author

Msabata commented Nov 18, 2023

One more following question on coords: 101 1035 32;92 -486 32;1537 -495 32;1546 1027 32;101 1035 50;
In editor is represented by:
Snímek obrazovky 2023-11-18 110118

how can I find out if the point will be represented with minus or plus in coordinates to reality?

And size calculation from coordinates to real size?

Thank you for response.

@pkturner
Copy link
Contributor

how can I find out if the point will be represented with minus or plus in coordinates to reality?

The object coordinates in the omap/xmap file are not an exact match for the displayed coordinates (in your example, 0,07 -1,09). The coordinates in the file are measured in thousandths of a mm, in other words in micrometers.

In addition, the y coordinates in the file have their minus/plus switched. (This makes them better able to be drawn on the computer's screen, because the y coordinate at the top of the screen is 0.)

So the object corner represented in the file as 101 1035, has x and y coordinates on the map of 0,101 -1,035 (mm).

@pkturner
Copy link
Contributor

pkturner commented Nov 18, 2023

And size calculation from coordinates to real size?

  • Start with distance on the map, in mm.
  • Divide by 1000 --➔ distance on the map, in m
  • Multiply by the map scale denominator --➔ real distance (in m)
  • Multiply by the auxiliary scale factor --➔ real distance on the ellipsoid (in m)
  • Multiply by the grid scale factor --➔ real distance in coordinates of the projected grid (in m)

The grid scale factor and the auxiliary scale factor are small enough that there's usually no need to manage them. Many maps either have an auxiliary scale factor of 1.0, or have a combined scale factor of 1.0.

@eolmapper
Copy link

Does this mean that the map is represented with an orthographic projection that matches the map grid?

@pkturner
Copy link
Contributor

The map could represent the terrain using an orthographic projection. However, the user sets the projection when choosing a CRS in a georeferencing dialog. The normal recommendation is that the CRS match the CRS of a base map.

Note that if the CRS/projection is orthographic, the relationship between map and geographic coordinates can be more direct, because the projection can be chosen so that the grivation and grid scale factor have no effect. In other words, the grivation would be 0° and the grid scale factor would be 1.0.

@eolmapper
Copy link

The map drawing does not move when changing CRS (no stretching or deformation) so the drawing grid does not move, but it is the new projection grid that adjusts to it. When creating a new georeferenced map there is a grid scale factor taken into account in the combined scale factor, this means that mapper creates a custom orthographic projection centered at the reference point. Right?

@pkturner
Copy link
Contributor

The map drawing does not move when changing CRS (no stretching or deformation) so the drawing grid does not move, but it is the new projection grid that adjusts to it.

That is the effect of changing the CRS using the Georeferencing dialog. If the map drawing is already correctly georeferenced, then that method of changing the CRS is not suitable.

When creating a new georeferenced map there is a grid scale factor taken into account in the combined scale factor,

Mapper uses the grid scale factor as you say. Similarly it uses the convergence to orient the projected coordinates relative to the map's magnetic north y axis. The scaling and orientation are used to align the map coordinates with the projected coordinates which are given meaning by the CRS. For this purpose, a map's grid scale factor is a number close to 1.0, and its convergence is a number close to 0, plus or minus a few degrees.

this means that mapper creates a custom orthographic projection centered at the reference point. Right?

The grid scale factor and convergence, being properties of the projection between ellipsoid and a 2-D plane, are not perfectly constant across the map. To deal with this, Mapper determines their values at the reference point, and uses those specific numbers to relate the map coordinates with the projected coordinates. Yes, Mapper centers on the reference point.

But no, the grid scale factor and convergence do not depend on an orthographic projection.

@eolmapper
Copy link

thanks for the answer.

@eolmapper
Copy link

eolmapper commented Nov 21, 2024

That is the effect of changing the CRS using the Georeferencing dialog. If the map drawing is already correctly georeferenced,
then that method of changing the CRS is not suitable.

So what would be the right way?

@pkturner
Copy link
Contributor

If a map is already correctly georeferenced, and you want to change the CRS to a different projection,

  1. Create an empty map, setting its georeferencing to the new CRS.
  2. Add the georeferenced map to the new map as a template.
  3. Select the template in the template setup window, and perform Edit > Import and remove.

Step 2 uses the PROJ library to position the map objects, by transforming from projected coordinates in the old CRS to projected coordinates in the new.

I tried an example just now. This careful method made a difference of only 0.5 m in the positioning of an object 3.5 km from the reference point. So it's often a small effect. What I said earlier was too strong. Simply changing the CRS in the georeferencing dialog may be suitable.

@eolmapper
Copy link

Thanks a lot for this clarification.

@krticka
Copy link
Contributor

krticka commented Nov 24, 2024

@pkturner I think there is a lot of valuable information provided here and it would be beneficial to expand the help for the program. It's not information that a beginner would probably appreciate, but it could be included somewhere so that even experienced mappers can find answers to their questions.
https://www.openorienteering.org/mapper-manual/pages/georeferencing.html

@krticka
Copy link
Contributor

krticka commented Nov 24, 2024

grivation = declination - convergence

It is not always like this, for example in my country grivation = declination + convergence
https://mapy.orientacnisporty.cz/en/convergence

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

4 participants