Results 1 to 4 of 4

Math Help - converting between two cordinate systems

  1. #1
    Newbie
    Joined
    Dec 2009
    Posts
    2

    converting between two cordinate systems

    I'm trying to make a conversion between two coordinate systems, pixel x,y and latitude, longitude. Say we have two points, the first being 53,12 which represents latitude 42 longitude -119.5, the second 42,56 representing latitude 39 longitude -119.3. How would I find the pixel distance between the two longitudes and two latitudes?
    It may seem like a silly request giving all the datums and map projection math readily available on wikipedia but this particular map im using does not follow any standard projection. I'm mathematically representing a mesh of several xy points mapping to latitudes and longitudes to properly calibrate plotting cities in a state.
    Follow Math Help Forum on Facebook and Google+

  2. #2
    MHF Contributor

    Joined
    Apr 2005
    Posts
    16,396
    Thanks
    1846
    Since you say "Latitude and Longitude", this apparently is a projection of a globe onto a flat screen. Without knowing the projection, the information you give is not enough. In particular, the relation between "latitude and longitude" and pixels cannot be linear.
    Follow Math Help Forum on Facebook and Google+

  3. #3
    Super Member
    Joined
    Jan 2009
    Posts
    591
    Quote Originally Posted by lolboxen View Post
    I'm trying to make a conversion between two coordinate systems, pixel x,y and latitude, longitude. Say we have two points, the first being 53,12 which represents latitude 42 longitude -119.5, the second 42,56 representing latitude 39 longitude -119.3. How would I find the pixel distance between the two longitudes and two latitudes?
    It may seem like a silly request giving all the datums and map projection math readily available on wikipedia but this particular map im using does not follow any standard projection. I'm mathematically representing a mesh of several xy points mapping to latitudes and longitudes to properly calibrate plotting cities in a state.
    In your example you have 3 degrees difference in latitude. That's about 200 miles at the earth's surface. For the mapping it depends a lot on the method used to generate the map you have.

    Search the internet for some of these terms:
    Transverse Mercator Projection
    Lambert Conformal Conic projection
    Polyconic Projection
    Unprojected maps

    Most likely the geographic data relies on the state plane coordinate system.
    IF the information you are attempting to provide or use is NOT critical, then you can "map" the pixels to the lat/long data.

    Latitude is North/South & Longiture is East/West

    Pixel X: is Left to Right & Pixel Y: is Top to Bottom

    Determine the difference in latitudes and equate that to the difference in vertical pixels
    .
    \dfrac{ (Py1 - Py2)}{(Latitude1-Latitude2)}=\text{VerticalRatio}
    .
    \dfrac{ (12 - 56)}{(42-39)}= -14.7 pixels per degree (be careful of the sign/direction)





    Determine the difference in longitudes and equate that to the difference in horizontal pixels

    \dfrac{ (Px1 - Px2)}{(Longitude1-Longitude2)}=\text{HorizontalRatio}

    \dfrac{ (53 - 42)}{(-119.5) - (-119.3))}= -55 pixels per degree of longitude.

    IF your map is distorted (and it appears to be) then you'll need to transform the coordinate grids in addition to scaling.

    IF your product requires more accuracy, then convert the geodetic coordinates (Lat/Long) to state plane coordinates. Then match the state plane coordinate to the pixels. The conversion from one to the other is simple as indicated above.

    Convert Latitude/Longitude to State Plane to pixel coordinates
    &
    then compute pixel values to state plane to lat/long.

    .
    Follow Math Help Forum on Facebook and Google+

  4. #4
    Newbie
    Joined
    Dec 2009
    Posts
    2
    Quote Originally Posted by aidan View Post
    In your example you have 3 degrees difference in latitude. That's about 200 miles at the earth's surface. For the mapping it depends a lot on the method used to generate the map you have.

    Search the internet for some of these terms:
    Transverse Mercator Projection
    Lambert Conformal Conic projection
    Polyconic Projection
    Unprojected maps

    Most likely the geographic data relies on the state plane coordinate system.
    IF the information you are attempting to provide or use is NOT critical, then you can "map" the pixels to the lat/long data.

    Latitude is North/South & Longiture is East/West

    Pixel X: is Left to Right & Pixel Y: is Top to Bottom

    Determine the difference in latitudes and equate that to the difference in vertical pixels
    .
    \dfrac{ (Py1 - Py2)}{(Latitude1-Latitude2)}=\text{VerticalRatio}
    .
    \dfrac{ (12 - 56)}{(42-39)}= -14.7 pixels per degree (be careful of the sign/direction)





    Determine the difference in longitudes and equate that to the difference in horizontal pixels

    \dfrac{ (Px1 - Px2)}{(Longitude1-Longitude2)}=\text{HorizontalRatio}

    \dfrac{ (53 - 42)}{(-119.5) - (-119.3))}= -55 pixels per degree of longitude.

    IF your map is distorted (and it appears to be) then you'll need to transform the coordinate grids in addition to scaling.

    IF your product requires more accuracy, then convert the geodetic coordinates (Lat/Long) to state plane coordinates. Then match the state plane coordinate to the pixels. The conversion from one to the other is simple as indicated above.

    Convert Latitude/Longitude to State Plane to pixel coordinates
    &
    then compute pixel values to state plane to lat/long.

    .

    This answer was perfect. The information is not critical, basically its a map to show locations of a client we have. Upon further research I found that Lambert Conformal Conic is almost identical to the map were using. Luckily a wikipedia article has all the necessary equations for that projection. Thanks!
    Follow Math Help Forum on Facebook and Google+

Similar Math Help Forum Discussions

  1. Replies: 1
    Last Post: September 18th 2011, 11:45 AM
  2. Converting Coordinate Systems
    Posted in the Advanced Applied Math Forum
    Replies: 1
    Last Post: April 4th 2011, 05:37 AM
  3. Cordinate geometry !
    Posted in the Geometry Forum
    Replies: 0
    Last Post: December 7th 2009, 08:41 PM
  4. Cordinate geometry
    Posted in the Pre-Calculus Forum
    Replies: 4
    Last Post: March 9th 2008, 04:06 AM
  5. [SOLVED] [SOLVED] converting 2D coordinate systems
    Posted in the Advanced Applied Math Forum
    Replies: 1
    Last Post: January 31st 2006, 05:07 PM

Search Tags


/mathhelpforum @mathhelpforum