Finding The Hypotenuse Of From Two Pairs Of X,Y Coordinates

Feb 4, 2010

I have a map with several waypoints and would like to find the distance between any of these two waypoints. Sounds simple, but I have having an issue with the later parts of the excel file. Let me explain further.

There are over 100 waypoints on this map we have. Each waypoint has an, seemingly arbitrary, X-coordinate and Y-Coordinate. However, if you divide the coordinates by [X], they turn into miles. It should go without saying that finding the distance between two waypoints is rather simple mathematically, but I having an issue figuring out how to pull two random waypoints and having the distance automatically calculated.

So far, I just have column A with the waypoint name and with column B and C having the X and Y coordinates respectively. Is there anyway I can create some sort of call function that when two waypoint values are entered it would automatically calculate the distances?

Is there any way to find pairs of numbers from lotto data ,starting from the highest to the lowest for the full 24 pairs? It does not matter if excel formula or Vb code.T

I have created a sheet that shows distance between coordinates. Also working on something to put them in order of the closest point. I used a fixed point to find the nearest coordinate, but since i'm using a fixed point it doesnt go the order I want it to. I have attached the excel file I am working on.

how to get a single cell (C2) and (D2) to make the numbering format go from (## ## ##) to (######).

The Excel spread sheet is a coordinate converter, designed to take Degree's minuets seconds and convert it to Decimal Degrees, the formula is set up and work Great, but every time I copy and paste the coordinate to the excel spread sheet, i have to manuelly erase the spaces between the numbers so the formula can work properly. How can i get the cell to automatically delete the space between the numbers to save me time.(I.e 29 35 42.34325 -to-> 293542.34325)

I'm trying to create a spreadsheet that will convert coordinates from DDMMSS.00 to DDMM.000. I found another thread that discusses this same issue, but I was unable to make it work for me. I'm attaching a sample spreadsheet that basically shows what I'm trying to do.

I have an image which i have reduced to a mathematical representation of light intensities. We can consider each cell in my spreadsheet as a pixel, the value within the cell corresponding to how much light that pixel it took in during an exposure. There is a trend along the pixels that i would like to isolate as exactly as possible: a diagonal line, not quite straight from the bottom left corner to the top right.

What I would like to do, if possible, is to treat each cell in my spreadsheet as a point on a coordinate plane, and to use some type of formula or macro to give me a line of best fit using the positions of the highest valued cells as the data points in my extrapolation.

The tool I'm looking for would take data organized like this:

And give me an equation of the form y=1x + b (describing where to find the maximum values among the cells), although my actually data will need to be fit to a higher order polynomial.

Once I can do this, I will also need a way to take perpendicular sums automatically along the line of best fit at distance of two pixels in both directions and a width of one pixel. You can imagine drawing a rectangular box perpendicular to the line of maximum values and adding the proportions of each cell enclosed by that box. This means that for the example above, i would get 209 for all five points of interest: the maximum value plus the two values of one in the upper left perpendicular direction, the two values of one in the lower right perpendicular direction, half the values of the two cells neighboring the exactly perpendicular cells and a quarter of the outermost cells touched by our imaginary pixel box.

The following image may be useful in clarifying what I'm looking for. The red bar represents the imaginary box containing perpendicular pixel sums, where the green beam is the line of best fit derived from my maximum values.

Attachment 337419

Also, here is a snippet of my actual data to experiment with in solving these strange and exotic problems

I am trying to extract (and separate into 3 columns) the numbers only, positive or negative portion of (XYZ) Coordinates copied from AutoCAD and pasted into column A X = 96179.9699 Y = 61973.9793 Z = 1368.0025 In column B,C and D, I have tried to use Find Mid and other means

i use a Trimble Total Station Survey equipment, This is used for suveying and measuring distances between points on jobs. These points can be exported onto the pc as a text file and imported onto excel, the file has a northing and easting to locate the point these are comma separated.

I would like to know if excell is capable of working out a distance betwen two of these such points by using the two pairs of northing and easting coordinates. The maximum distance between two points is no more than 50 meters. If for example when imported onto excel point 1's coordinates are locted in cells A1 and B1 and points 2's coordinates are locted in cells A2 and B2.

I have a userform, on it is a very large command button with a picture of a map loaded on the button. The button is 500 width(X) by 500 height (Y), so the center of the button would be at the location 250 (X) by 250 (Y). The button is coded for mousemove to get the X,Y cooridates and when you _Click the button a textbox gives the distance to the point(mousemove) from the center of the button. All that is good, but now I'd like to find the degree of the point referenced to a compass, ie, if the point is at 250 (X) and (Y) is less than 250 then the point would be due north at 0/360 degrees and if the point (Y) is greater than 250, it would be south of the center of the button. I hope this make sense. It's been a long time since trig. I've been searching but can't seem to find the correct formula to figure this out.

Here's the other problem, I'm doing this in powerpoint so I'm not sure if cos or tan functions are loaded in this program. I am posting this in the xl forum because I figure that's where most of the people who could figure this out are. If this is in the incorrect forum I can try to move it,

Is it possible to create a chart using spherical coordinates (radius, theta, phi) in Excel? I want to create something similar to this. I would even be willing to write add-in code to create the graph from scratch, but I don't know if that's possible. Is it possible to create a new chart type without using the other chart types as a base?

I have 2 columns of longitude and latitude coordinates. I want to count coordinates within certain ranges. A bit like using the Frequency function but for 2 sets of values and 2 bins arrays. This would mean I could create a table with latitute bins as the row headers and longitude bins as the column headings. Would anyone know how to do this?

513 BLUE RIDGE Kansas City, MO (39.104810141000485, -94.47983043799968)

I need to isolate the coordinates in separate cells. IE "39.10481014000485" in cell J2 & "-94.47983043999968" in cell K2. The problem is that some of the cells don't have 14 numbers behind the decimal, and my formula will sometimes grab either the comma ( "," ) or the end parenthesis ( ")" ). Is there a formula I can use to isolate the two coordinate plots?

The good thing is every cell is formatted exactly like this. I had been using a formula that looks like this.

=MID(F2,FIND("(",F2)+1,18)

I think it's close. I just cant figure out how to tell the formula to stop at the first comma, and to stop at the end parenthesis for the second set of coordinates.

I am running a fairly complex simulation at work and have quite a few different functions in it. For the simulation to work properly, i need to have the Solver add-in and the Analysis ToolPak installed. Everytime that i try and use the simulation on a different computer (or if anyone else tries to run it) the add-ins must be enabled again. Is there a way to set up a macro to enable them when either i open the simulation (first preference) or when a button is pressed (2nd preference).

I want to use a User Defined name look up its corresponding X/Y Coordinates , reference a list organized by categories, then go through each name in the list finding each's X/Y Coord Calculate distance.

I'm not sure if it's possible to do this, but I have three lists of data. One is a complete list (for example, the numbers 1-25). The next list is a subset of the complete list (e.g., 1,3,5,7,9). Attached to these (the subset list) is another list (let's say letters, so A goes with 1, B goes with 3, etc). I want to physically move the paired entries from Lists 2 & 3 so that List 2 matches up with List

I want to store a list of strings in an array with their position so that I can sort them alphabetically and then be able to put them back in their original order again e.g.

John 1 Charlie 2 Paul 3 Andy 4 etc,

So when they are alphabetized (is that a word?) they become

Andy 4 Charlie 2 John 1 Paul 3

My plan was to store them in an array, but I can't think how to do it. In python, I would just make a list of tuples, what is the best way to do this in VBA?

I need to complete what would seem a fairly simple incrementing task but I'm not getting the results that I'm looking for. I don't know much about macros so would prefer not having to use one but I'm willing to try if it's not too complicated.

I'm using Excel 2010 on a PC. For several projects, I need to increment cells that contain text and numbers. The column contains data in a cell (A1), followed by a blank cell (A2), then cell A3 contains new data followed by a blank in A4, etc. What I need to do is 1) copy the exact data in A1 to A2 and then 2) increment the number used in A1/A2 by 1 in A3, copy that into A4, and the pattern repeats down the column.

Here is an example of what I have in column A: Test_01 [blank cell] Test_02 [blank cell] Test_03 [blank cell] etc.

This is what I want as a result. Test_01 Test_01 Test_02 Test_02 Test_03 Test_03 etc.

Do I need to save the data in the column as text, general, or numbers? Is there some function that would make incrementing the data possible as I've outlined above?

I would like to know if its possible to extract just the even/odd pairs from a number.

Exp. I have the number 123 in cell A1, and would like to extract the even/odd pair, which in this case would be 13, the cell A2. I would like to be able to do this without the use of "Isodd" or "iseven" functions.

I am looking for a code which will check and display the Maximum Occurrences of pairs of 2 Characters.

In the attached file I tried to write some code but it seems to be wrong.

For your convinience, I entered the reuslts in a table (hopefully not mistaken). The code should display a MsgBox saying that "The pair 'ab' was found 6 times in A1.

The string, in A1, can be any string in any length.

I am trying to analyse a set of variables in my dataset.

The variables I have are numbers which are organised into a single column.

I want to count the number of times different variable pairings occur within my data.

An example dataset of mine is: 1,2,4,2,1,3,5,3,2,1

As the dataset contains 5 variables (1,2,3,4,5) the potential combinations are: 1,1; 1,2; 1,3; 2,1; etc.. with 25 in total.

I want Excel to move through this column starting with the first two cells and step down 1 cell each time and then tell me the number of times each of the combination occurs.

If the could be longer I would have included "when multiple cells can contain the same value"

I have a very large dataset that I would like to apply the following searches to, but I will include a smaller sample that gets at the point.

For example; in the following sheet: Cat Dog Lizard Red 1 2 3 Yellow 4 5 6 Green 7 8 1

If I search for "2", I would like to get back "Red" and "Dog". I was able (by looking at other posts) come up with a series of formula that allow me to obtain the sheet coordinates and convert them into column and row headers (using SUMPRODUCT Row/Column); however, when multiple cells contain the same value, the output becomes the sum of that coordinate and is no longer a reference to a specific header, so a search for "1" would not give me "Red" and "Cat". Ideally, if I searched for "1" I would get back "Red" & "Cat" as well as "Green" & "Lizard", but I would be satisfied with a formula that even just gave me back one of the two header pairs.

How to set a formula to calculate distances (by using a function I provided) among all the observations (each one with a latitude and longitude value expressed in decimals) in an excel sheet. Here it is the previous thread.

I slightly modified the solution MarvinP suggested to me by using my own function to calculate distances among coordinates.

Attached you can find the excel with this. You will see that on the right side of the sheet, in yellow background, there is a matrix whose non-blank cells each one reporting a case of close coordinates (e.g.: 4-5 means that observations 4 and 5 are less than 15 Km apart one from another). Cells of the left-side matrix contains the function used to calculate distances among each observation with any other. Matrices are 116X116.

However, I am now jammed because I don't find an easy way to pool the observations found to be close each other (I have used a distance threshold of 15 Km - you can see it in the formula inside each cell of the "yellow" matrix").

The ideal way to establish new coordinates values for observations close one another would be by using coordinates which are at an intermediate position, however, this is not my priority, it would be OK also using one arbitrary value for all of them, i.e. picking up one pair of coordinates of one of the close observations and attribute this to the other. I have seen that, by excluding nonsensical similarities (e.g. 1-1, 2-2, etc.), there are groups of close observations of size 2 (e.g. 4-5) up to 10 (nine observations very close to a given one).

I'm using Excel to create a flowchart from a configuration sheet. I'm not manually entering the coordinates. Instead, I draw the start step in a set location. The next step(s) that's connected to the first step is placed directly below the start step. if there's more than one step connected to the start step, it's placed at the same y-coordinate but shifted along the x-axis.

The problem I'm running into here is this: say I have three steps connected to the start step and three further steps connected to the first of the three connected to the start step, how can I keep track of this and shift the other two steps connected to the start step along the x-axis so they're not positioned above the four steps below the first step (and as such, in the same location as other steps)? I'm not sure if my description is particularly clear or not so I've attached a drawing that will hopefully clear things up.

Is there any way of giving Excel shapes a "weight" so that other shapes won't line up on top of them?

Does anyone have a macro they have created or know of that can solve the X and Y coordinates on an ellipse? Would you be willing to share here or send it to me in a personal email?

I have a square which is defined with x,y coordinates (roughly 2000 points), and for each point I have a value. And I have to divide this square in to 9 equal sub grids, and find the max value in each sub grid. I have all the coordinates for the sub grids. But I can’t get the max value of the specified cells.

I am thinking something like this:

if 0<x>10 and 0<y<10 then it is sub grid 1 and I want to find the max value there and if 0<x>10 and 10<y<20 then it is sub grid 2 and so one…..

I'm attempting to write a piece of code that builds a formula dependent on the location of the cell it is being created in. The relevant line of code currently reads as follows:

Which when activated in cell A3, will enter the formula =$A$3 & $A$2

However, I would like to know if there is a way of automatically building a formula like this, only without the absolute references. Reason being, this formula is used in a large table, which is sorted in date order automatically when the sheet is activated. Since the code generated will point at the row it was generated on, when the table is sorted, this formula will calculate the incorrect result.