## How to transform cartesian coordinates into polar coordinate, relate to a segment, also called Azimuth.

Etymology (by Wikipedia)The word

azimuthis in all European languages today. It originates from medieval Arabic al-sumūt, pronounced as-sumūt in Arabic, meaning “the directions” (plural of Arabic al-samt = “the direction”).

Consider the figure

In this post we talk about Azimuth and Distance between two points.

We know the cartesian coordinate of two points: A, B.

If we want to know polar coordinates of point B, relating point A, we assume that A is a new center of a Polar Coordinate System.

In this way we can transport te axes origin from O to A.

Looking the cartesian system A, x’, y’ we call** azimuth of point B on point A the angle (AB)**:

And we determinate the *distance* AB between A and B:

The proof of these is very easy: just consider the right triangle ABB’, we obtain the relations with Basic right-triangles solvings.

At the same way we can determine *Az*. (BA) and the distance BA, looking the cartesian system B, x”, y”

It is possible call (BA) *the reverse angle of (AB)*, because:

From the same triangle ABB’ (or ABA’) we can determinate inverse relations. These relations are most used in topography for transform survey data (they are commonly in polar coordinate system, angles and distances) into cartesian coordinates.

We have:

(1)

and

(2)

## NOTE for inverse operations

If we use (1) and (2) directly, from AB and (AB) we obtain the exact values of cartesian coordinates, such as the Frist or the Fourth quadrant. But if we use inverse relations for determine AB or (AB), we have to consider the quadrant.

The inverse operations for determine (AB) from cartesian coordinate give more than one results, and mathematically is an indeterminate problem.

### Samples

Consider A and B both into the frist cartesian quadrant:

and if we want to determine (AB) from cartesian coordinates:

In according to what saw in “Inverse trigonometric funcions” post, the inverse relation give more than one results:

in our case:

**It is important to delete the N.A. solutions after frist angle calculation for determine the correct Azimuth (AB)!**

## Implementations

### A) Determine the values of cartesian coordinates of these points, data from topography survey

Point |
Azimuth |
distance d |

A |
300°56′ 53″ | 217,35 mt |

B |
33° 25′ 22″ | 296,48 mt |

C |
208° 17′ 14″ | 180,07 mt |

D |
132° 31′ 36″ | 353,74 |

For each points we can obtain the cartesian coordinates:

and

We write the results in other two new columns of the table

Point |
Azimuth |
distance [mt]d |
[mt]x |
[mt]y |

A |
300°56′ 53″ | 217,35 | -186,40 | 111,78 |

B |
33° 25′ 22″ | 296,48 | 163,30 | 247,44 |

C |
208° 17′ 14″ | 180,07 | -85,33 | -158,57 |

D |
132° 31′ 36″ | 353,74 | 260,70 | -239,11 |

### B) Convert cartesian coordinates into polar of a new rotated and translated system

The coordinate of original system are:

point |
x |
y |

A | +201,26 | +241,18 |

B | +157,62 | -160,34 |

C | -274,57 | -77,83 |

D | -89,65 | +290,09 |

O’ | -47,37 | +171,14 |

#### solution:

Using these relations:

The new coordinates are:

point | x’ | y’ |

A | + 236,22 | -104,50 |

B | -53,32 | -386,08 |

C | -333,76 | -47,03 |

D | +43,24 | +118,61 |

### C) Determine the intersection point between two lines

We can determine the cartesian coordinate of an intersection point, we have the coordinates of extremes of the lines.

Point | x | y |

A | 43.12 | 154.33 |

B | 320.12 | 63.88 |

C | 119.22 | 44.8 |

D | 290.15 | 245.12 |

#### Solution

Determine the values of azimuth (AB) and (CD) as slopes of their lines

Using analytic notation for line equation we have for a line trough a generic point Q:

There are infinite lines that passing trough P, we consider the lines that starting from A and from C. We know their slopes .