Home |
Search |
Today's Posts |
#1
Posted to microsoft.public.excel.programming
|
|||
|
|||
10 X 10 grid and finding distances from multiple points...
here is what i need help with... this is a small example of what i need to do... 10 X 10 grid (x-y axis 0-10) on the grid are 4 points (for example (2,3)(3,4)(5,5)(7,5)) i need to determine the distance of each point to each grid mark..for example each point on the grid (0,0)(0,1)....(10,10) i need to find the distance that point is to the all 4 points that are user defined. i am trying to write a routine in VBA that will do this it has been awhile since i tinkered with VBA so any help would be greatly appreciated -- brya6347 ------------------------------------------------------------------------ brya6347's Profile: http://www.excelforum.com/member.php...o&userid=20024 View this thread: http://www.excelforum.com/showthread...hreadid=346089 |
#2
Posted to microsoft.public.excel.programming
|
|||
|
|||
10 X 10 grid and finding distances from multiple points...
This isnt a VBA solution, but maybe this will work for you...
Sounds like you need to apply the old pythagorean formula (a²+b²=c²) make a table of every grid point (0,0)-(10,10) 0 0 0 1 0 2 ..... 10 9 10 10 (121 rows of data) then for each of your user defined points... caluculate the x-diff and the y-diff, then plug them into the formula and solve for c. =SQRT(x-diff²+y-diff²) Hope that helps. "brya6347" wrote: here is what i need help with... this is a small example of what i need to do... 10 X 10 grid (x-y axis 0-10) on the grid are 4 points (for example (2,3)(3,4)(5,5)(7,5)) i need to determine the distance of each point to each grid mark..for example each point on the grid (0,0)(0,1)....(10,10) i need to find the distance that point is to the all 4 points that are user defined. i am trying to write a routine in VBA that will do this it has been awhile since i tinkered with VBA so any help would be greatly appreciated -- brya6347 ------------------------------------------------------------------------ brya6347's Profile: http://www.excelforum.com/member.php...o&userid=20024 View this thread: http://www.excelforum.com/showthread...hreadid=346089 |
Reply |
Thread Tools | Search this Thread |
Display Modes | |
|
|
Similar Threads | ||||
Thread | Forum | |||
"multiple distances versus lowest time for a specific distance" | New Users to Excel | |||
multiple distances versus lowest time for a specific distance | New Users to Excel | |||
finding 1st populated cell on a vector with varying starting points | Excel Discussion (Misc queries) | |||
Zip codes and Distances | Excel Discussion (Misc queries) | |||
Finding height between high points | Excel Worksheet Functions |