Cal11 calculator

Calculate Direction Between Two Points in Degrees

Reviewed by Calculator Editorial Team

This calculator determines the bearing or direction between two geographic points using their latitude and longitude coordinates in degrees. The result is expressed as a compass bearing in degrees from north, which can be used for navigation, surveying, or mapping purposes.

How to Use This Calculator

To calculate the direction between two points:

  1. Enter the latitude and longitude of the starting point in decimal degrees.
  2. Enter the latitude and longitude of the destination point in decimal degrees.
  3. Click the "Calculate" button to compute the bearing.
  4. The result will display the compass bearing in degrees from north.

The calculator uses the spherical law of cosines to account for the Earth's curvature, providing an accurate bearing between the two points.

Formula Explained

The direction between two points is calculated using the following formula:

θ = atan2(sin(Δλ) * cos(φ₂), cos(φ₁) * sin(φ₂) - sin(φ₁) * cos(φ₂) * cos(Δλ))

Where:

  • θ is the bearing in radians from north
  • φ₁ is the latitude of the starting point in radians
  • φ₂ is the latitude of the destination point in radians
  • Δλ is the difference in longitude between the two points in radians

The result is converted to degrees and normalized to a compass bearing (0° to 360°).

This formula accounts for the Earth's curvature and provides an accurate bearing between the two points.

Worked Example

Let's calculate the direction from New York City (40.7128° N, 74.0060° W) to Los Angeles (34.0522° N, 118.2437° W).

  1. Convert coordinates to radians:
    • φ₁ = 40.7128° × π/180 ≈ 0.7107 radians
    • φ₂ = 34.0522° × π/180 ≈ 0.5946 radians
    • Δλ = (118.2437° - (-74.0060°)) × π/180 ≈ 3.1266 radians
  2. Apply the formula:
    • θ = atan2(sin(3.1266) * cos(0.5946), cos(0.7107) * sin(0.5946) - sin(0.7107) * cos(0.5946) * cos(3.1266))
    • θ ≈ 2.3562 radians
  3. Convert to degrees and normalize:
    • θ ≈ 2.3562 × 180/π ≈ 135.0°

The bearing from New York City to Los Angeles is approximately 135° from north, which corresponds to southeast.

Frequently Asked Questions

What is a compass bearing in degrees?

A compass bearing in degrees is a measurement of direction from north, where 0° points directly north, 90° points east, 180° points south, and 270° points west. The bearing is always measured clockwise from north.

How accurate is this calculator?

This calculator uses the spherical law of cosines to account for the Earth's curvature, providing an accurate bearing between two points. The result is precise for most practical applications.

Can I use this calculator for aviation or maritime navigation?

Yes, this calculator can be used for aviation and maritime navigation. The compass bearing it provides is suitable for plotting courses and determining directions between points.

What if the two points are very close together?

If the two points are very close together, the bearing will still be accurate. The calculator accounts for the Earth's curvature, so it works for both large and small distances.