Let us consider a point (longitude, latitude) on Earth (location).

How to construct a square grid around this point (taking this point as the centre of the square or intercept of the two diagonals) with size of the square as 0.1 degree times 0.1 degree and direction of the one side of square is theta degree?

For example, let the sample point to be (88.38045, 21.04247) and theta = 70 degree. Here is a rough plot for clarification.

enter image description here

Note: This direction is computed from the 84 E meridian.

  • 1
    In fact Lat Long is a spherical coordinate system. So By the Theta you relate to a deflection angle to one plane what about other plane.... – SIslam Jan 30 '15 at 13:56
  • @msi_g Thanks for attention. you are right, its a deep observations, i have not think about that. Here what I want is that: after plotting the (lat,lon) point in 2d, draw square around it in that direction. – Janak Jan 30 '15 at 14:03
  • Ok.if it is on 2d(e.g.UTM45 for Bay of Bengal-offshore of West Bengal) then what will be the X axis and what will be Y, because there are several X(meridians) and Y(parallels) then wherefron you will measure theta? – SIslam Jan 30 '15 at 14:15
  • @msi_g I am working with data, only in the latitude range (21-25) and longitude (84-88). Data are satellite observations in this region. I can get direction of the square from the passing direction of the satellite. This theta is measured from the meridian of 84 degree east (the minimum lat). – Janak Jan 30 '15 at 14:32

If the square can be in meters instead of degrees, you can create a custom CRS in oblique mercator projection:

+proj=omerc +lat_0= 21.04247 +lonc=88.38045 +alpha=-70 +k=1 +x_0=0 +y_0=0 +gamma=0 +ellps=WGS84 +towgs84=0,0,0,0,0,0,0 +units=m +no_defs

And create a vector grid with that CRS:

enter image description here

  • 1
    Thanks for the answer. Yes, grid could be in metres. Could you please explain a little bit about how to "create a custom CRS in oblique mercator projection:". And how to run the above code and on which software we can run this code? – Janak Jan 31 '15 at 6:55
  • I think this is a code for GeoServer. I am not familiar to it (want to learn). Could you please suggest a code for how to create a vector grid with that CRS. – Janak Jan 31 '15 at 7:21
  • I have used QGIS to create the custom CRS and the vector grid. Both can be made within the GUI. Once you save the result to a shapefile, you can use it anywhere in the GIS world. – AndreJ Jan 31 '15 at 7:33
  • Ok. I shall try to use QGIS to create the vector grid and CRS. Thanks a lot. – Janak Jan 31 '15 at 7:56

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.