How to find Lon. and Lat. of a field by having a few sample GPS points?

조회 수: 1 (최근 30일)
Mo Ba
Mo Ba 2017년 3월 21일
편집: Mo Ba 2017년 4월 27일
I'm working on a field and for some reasons I need to find the exact Longitude and Latitude for different points on the field. Please have a look at the attached picture. Let's say I have such a field and I have divided it into 1000 different cells. Because the field is huge, it's not possible for me to capture Long. and Lat using GPS for all cells. I was thinking it might be possible to capture GPS data at some points (e.g. at cells number 1, 5, 10, 15, 20, ...) and then find others by interpolation or something like that. Do you have any idea how to do this? How can I find exact Long. and Lat for all cells by having some GPS sample points? Do you think using a simple MATLAB interpolation is a good option? Thanks in advance for your suggestions and ideas.

답변 (1개)

Gavriel Aminov
Gavriel Aminov 2017년 3월 23일
편집: Gavriel Aminov 2017년 3월 23일
If the cells of the field are distributed uniformly, and if the height of each cell is weak function of 2D position, then the answer seems simple:
  1. Rearange the numeration of the cells to MxN=100x10 (use IND2SUB and SUB2IND)
  2. Measure the Lon&Lat of the bounding cells: (1,1),(100,1),(1,10),(100,10)
  3. Make regular interp2 over Lon values and Lat values separately like this:
  • lon2=interp2(x1,y1,lon1,x2,y2);
  • lat2=interp2(x1,y1,lat1,x2,y2);
where
x1=[1,1,10,10] (pay attention that x-position is parallel to j-index!)
y1=[1,100,1,100]
x2=1:10;
y2=1:100;
After the above works, it is also possible to make the results more precise by taking additional measurements at some randomly distributed cells WITHIN the field and executing scattered 2D-interpolation with GRIDDATA at the same manner as with INTERP2.
You can use 'linear' or 'spline' options in both cases, as the extrapolation is not required.
  댓글 수: 3
Gavriel Aminov
Gavriel Aminov 2017년 3월 26일
Please publish the text in order to enable copying the lon-lat data from your script and I'll try debug it.
Mo Ba
Mo Ba 2017년 4월 21일
편집: Mo Ba 2017년 4월 27일
Sorry @Gavriel Aminov for late response. I was waiting for notification if a new comment is added here. below is the commands I used:
x1=[1,1,35,35];
y1=[1,35,1,35];
x2=1:3;
y2=1:35;
lat1=[52.333734,52.334008,52.334013,52.333736];
lon1=[-106.284690,-106.284694,-106.282375,-106.282386];
lat2=interp2(x1,y1,lat1,x2,y2);
lon2=interp2(x1,y1,lon1,x2,y2)
Thank you again for your help.

댓글을 달려면 로그인하십시오.

카테고리

Help CenterFile Exchange에서 Smoothing에 대해 자세히 알아보기

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!

Translated by