Questions tagged [geography]

Geography is the science that deals with the study of the Earth and its lands, features, inhabitants, and phenomena.

The use of traditional spatial techniques used in cartography and topography and their application to computers is called geomatics, which encompasses a large area of fields involved with analysis, such as , Geographic information systems (), Remote sensing, and Global positioning systems ().

The above excerpt is quoted from Wikipedia.

There is a Stack Exchange site devoted to Geographic Information Systems.

449 questions
412
votes
30 answers

Calculate distance between 2 GPS coordinates

How do I calculate distance between two GPS coordinates (using latitude and longitude)?
nicudotro
  • 6,631
  • 6
  • 23
  • 17
203
votes
7 answers

Getting distance between two points based on latitude/longitude

I tried implementing this formula: http://andrew.hedges.name/experiments/haversine/ The aplet does good for the two points I am testing: Yet my code is not working. from math import sin, cos, sqrt, atan2 R = 6373.0 lat1 = 52.2296756 lon1 =…
gwaramadze
  • 3,603
  • 3
  • 26
  • 39
39
votes
2 answers

SQL Server 2008 GEOGRAPHY STDistance() value

I am using geography.STDistance() to return the distance between two single point locations. I'm curious as to which measurement is used for the return value? Is it in KM's, miles or perhaps some other? I'm getting results back upwards of 250k but…
Chris
  • 1,157
  • 4
  • 13
  • 25
38
votes
11 answers

What services can I used to find a user's location based on their IP address?

If you need to locate a user based on their IP address, what services are available (free and not free services are fine)? P.S. I understand that some users use proxies etc., that means the result is not 100% accurate. That's ok.
Michael Pryor
  • 23,537
  • 18
  • 68
  • 90
36
votes
4 answers

Geographical boundaries of states/provinces -> Google Maps Polygon

I'm building a web application that is going to dynamically highlight certain U.S. states and Canadian provinces on a Google Map, based on buttons and click events. Plan A) Polygons My primary idea for this was to draw Polygons. For this I need…
motto
  • 1,217
  • 3
  • 16
  • 30
26
votes
5 answers

Java, convert lat/lon to UTM

Does anyone know of a way, in Java, to convert an earth surface position from lat, lon to UTM (say in WGS84)? I'm currently looking at Geotools but unfortunately the solution is not obvious.
Steve Kuo
  • 58,491
  • 75
  • 189
  • 247
25
votes
1 answer

Positive/Negative Latitude and Longitude values vs. Cardinal Directions

As I've been taught, lat and long are of following types: Latitude North Longitude West Latitude South Longitude East During software development, if I receive two numeric values for lat and log, how can I translate those values into the cardinal…
Deepak
  • 895
  • 4
  • 11
  • 22
24
votes
6 answers

Calculating area enclosed by arbitrary polygon on Earth's surface

Say I have an arbitrary set of latitude and longitude pairs representing points on some simple, closed curve. In Cartesian space I could easily calculate the area enclosed by such a curve using Green's Theorem. What is the analogous approach to…
Paul A. Hoadley
  • 1,447
  • 1
  • 12
  • 17
23
votes
12 answers

How to find distance from the latitude and longitude of two locations?

I have a set of latitudes and longitudes of locations. How to find distance from one location in the set to another? Is there a formula ?
ArK
  • 18,824
  • 63
  • 101
  • 135
22
votes
5 answers

NHibernate.Spatial and Sql 2008 Geography type - How to configure

I am trying to use Nhibernate with the Sql 2008 Geography type and am having difficulty. I am using Fluent Nhibernate to configure which I am fairly new to so that may be the problem as well. First, the class I am trying to persist looks something…
Luke Foust
  • 2,184
  • 5
  • 28
  • 36
20
votes
7 answers

world map without rivers with matplotlib / Basemap?

Would there be a way to plot the borders of the continents with Basemap (or without Basemap, if there is some other way), without those annoying rivers coming along? Especially that piece of Kongo River, not even reaching the ocean, is…
Sampo Smolander
  • 1,350
  • 2
  • 11
  • 27
19
votes
3 answers

Why don't all the provinces of Pakistan get colored green?

I want to include all the provinces of Pakistan using google geochart. But only 3 are picked up. My code is setting the names of provinces in the script and then the provinces should get picked up by the library. var data =…
Niklas R.
  • 22,209
  • 67
  • 202
  • 380
16
votes
14 answers

Calculating Distance Between 2 Cities

How do you calculate the distance between 2 cities?
Krishna Kumar
  • 4,744
  • 13
  • 43
  • 46
16
votes
1 answer

How to read / write geography data using C#, Entity Framework and SQL Server 2008?

I have a form from which the user will be able to enter the latitude and longitude of a certain point on the map. The data will be input as string values. I did some research and found out from various sources that the Entity Framework doesn't…
Filip Filipović
  • 334
  • 3
  • 7
  • 19
14
votes
5 answers

Geospatial coordinates and distance in kilometers

This is a followup to this question. I seem to be stuck on this. Basically, I need to be able to convert back and forth to referring to coordinates either in the standard degree system OR by measuring a distance north from the south pole along the…
DanM
  • 6,727
  • 11
  • 48
  • 83
1
2 3
29 30